2551 from .HgLogDialog import HgLogDialog |
2551 from .HgLogDialog import HgLogDialog |
2552 self.log = HgLogDialog(self, mode="incoming", bundle=file) |
2552 self.log = HgLogDialog(self, mode="incoming", bundle=file) |
2553 self.log.show() |
2553 self.log.show() |
2554 self.log.start(name) |
2554 self.log.start(name) |
2555 |
2555 |
2556 def hgIdentifyBundle(self, name): |
|
2557 """ |
|
2558 Public method used to identify a changegroup file. |
|
2559 |
|
2560 @param name directory name on which to base the changegroup (string) |
|
2561 """ |
|
2562 dname, fname = self.splitPath(name) |
|
2563 |
|
2564 # find the root of the repo |
|
2565 repodir = dname |
|
2566 while not os.path.isdir(os.path.join(repodir, self.adminDir)): |
|
2567 repodir = os.path.dirname(repodir) |
|
2568 if os.path.splitdrive(repodir)[1] == os.sep: |
|
2569 return |
|
2570 |
|
2571 file = E5FileDialog.getOpenFileName( |
|
2572 None, |
|
2573 self.tr("Preview changegroup"), |
|
2574 self.__lastChangeGroupPath or repodir, |
|
2575 self.tr("Mercurial Changegroup Files (*.hg);;All Files (*)")) |
|
2576 if file: |
|
2577 self.__lastChangeGroupPath = os.path.dirname(file) |
|
2578 |
|
2579 args = self.initCommand("identify") |
|
2580 args.append(file) |
|
2581 |
|
2582 dia = HgDialog(self.tr('Identifying changegroup file'), self) |
|
2583 res = dia.startProcess(args, repodir, False) |
|
2584 if res: |
|
2585 dia.exec_() |
|
2586 |
|
2587 def hgUnbundle(self, name): |
2556 def hgUnbundle(self, name): |
2588 """ |
2557 """ |
2589 Public method to apply changegroup files. |
2558 Public method to apply changegroup files. |
2590 |
2559 |
2591 @param name directory name (string) |
2560 @param name directory name (string) |