2135 def hgUnbundle(self, name): |
2135 def hgUnbundle(self, name): |
2136 """ |
2136 """ |
2137 Public method to apply changegroup files. |
2137 Public method to apply changegroup files. |
2138 |
2138 |
2139 @param name directory name (string) |
2139 @param name directory name (string) |
|
2140 @return flag indicating, that the update contained an add |
|
2141 or delete (boolean) |
2140 """ |
2142 """ |
2141 dname, fname = self.splitPath(name) |
2143 dname, fname = self.splitPath(name) |
2142 |
2144 |
2143 # find the root of the repo |
2145 # find the root of the repo |
2144 repodir = dname |
2146 repodir = dname |
2145 while not os.path.isdir(os.path.join(repodir, self.adminDir)): |
2147 while not os.path.isdir(os.path.join(repodir, self.adminDir)): |
2146 repodir = os.path.dirname(repodir) |
2148 repodir = os.path.dirname(repodir) |
2147 if repodir == os.sep: |
2149 if repodir == os.sep: |
2148 return |
2150 return |
2149 |
2151 |
|
2152 res = False |
2150 files = E5FileDialog.getOpenFileNames( |
2153 files = E5FileDialog.getOpenFileNames( |
2151 None, |
2154 None, |
2152 self.trUtf8("Apply changegroups"), |
2155 self.trUtf8("Apply changegroups"), |
2153 repodir, |
2156 repodir, |
2154 self.trUtf8("Mercurial Changegroup Files (*.hg);;All Files (*)")) |
2157 self.trUtf8("Mercurial Changegroup Files (*.hg);;All Files (*)")) |
2160 |
2163 |
2161 args = [] |
2164 args = [] |
2162 args.append('unbundle') |
2165 args.append('unbundle') |
2163 if update: |
2166 if update: |
2164 args.append("--update") |
2167 args.append("--update") |
|
2168 args.append("--verbose") |
2165 args.extend(files) |
2169 args.extend(files) |
2166 |
2170 |
2167 dia = HgDialog(self.trUtf8('Apply changegroups'), self) |
2171 dia = HgDialog(self.trUtf8('Apply changegroups'), self) |
2168 res = dia.startProcess(args, repodir) |
2172 res = dia.startProcess(args, repodir) |
2169 if res: |
2173 if res: |
2170 dia.exec_() |
2174 dia.exec_() |
|
2175 res = dia.hasAddOrDelete() |
|
2176 self.checkVCSStatus() |
|
2177 return res |
2171 |
2178 |
2172 def hgBisect(self, name, subcommand): |
2179 def hgBisect(self, name, subcommand): |
2173 """ |
2180 """ |
2174 Public method to perform bisect commands. |
2181 Public method to perform bisect commands. |
2175 |
2182 |