Show More
@@ -819,15 +819,20 b' class localrepository(repo.repository):' | |||||
819 | if not crev: |
|
819 | if not crev: | |
820 | self.ui.debug(" %s: searching for copy revision for %s\n" % |
|
820 | self.ui.debug(" %s: searching for copy revision for %s\n" % | |
821 | (fname, cfname)) |
|
821 | (fname, cfname)) | |
822 |
for ancestor in self[ |
|
822 | for ancestor in self[None].ancestors(): | |
823 | if cfname in ancestor: |
|
823 | if cfname in ancestor: | |
824 | crev = ancestor[cfname].filenode() |
|
824 | crev = ancestor[cfname].filenode() | |
825 | break |
|
825 | break | |
826 |
|
826 | |||
827 | self.ui.debug(" %s: copy %s:%s\n" % (fname, cfname, hex(crev))) |
|
827 | if crev: | |
828 | meta["copy"] = cfname |
|
828 | self.ui.debug(" %s: copy %s:%s\n" % (fname, cfname, hex(crev))) | |
829 |
meta["copy |
|
829 | meta["copy"] = cfname | |
830 | fparent1, fparent2 = nullid, newfparent |
|
830 | meta["copyrev"] = hex(crev) | |
|
831 | fparent1, fparent2 = nullid, newfparent | |||
|
832 | else: | |||
|
833 | self.ui.warn(_("warning: can't find ancestor for '%s' " | |||
|
834 | "copied from '%s'!\n") % (fname, cfname)) | |||
|
835 | ||||
831 | elif fparent2 != nullid: |
|
836 | elif fparent2 != nullid: | |
832 | # is one parent an ancestor of the other? |
|
837 | # is one parent an ancestor of the other? | |
833 | fparentancestor = flog.ancestor(fparent1, fparent2) |
|
838 | fparentancestor = flog.ancestor(fparent1, fparent2) |
General Comments 0
You need to be logged in to leave comments.
Login now