Show More
@@ -61,6 +61,7 b' from mercurial.thirdparty import attr' | |||
|
61 | 61 | from mercurial import ( |
|
62 | 62 | cmdutil, |
|
63 | 63 | context, |
|
64 | copies, | |
|
64 | 65 | encoding, |
|
65 | 66 | error, |
|
66 | 67 | exthelper, |
@@ -859,16 +860,28 b' def addadded(pdiff, basectx, ctx, added,' | |||
|
859 | 860 | # additional copies we can mark them (moves get removed from removed) |
|
860 | 861 | copiedchanges = {} |
|
861 | 862 | movedchanges = {} |
|
863 | ||
|
864 | copy = {} | |
|
865 | if basectx != ctx: | |
|
866 | copy = copies.pathcopies(basectx.p1(), ctx) | |
|
867 | ||
|
862 | 868 | for fname in added: |
|
863 | 869 | fctx = ctx[fname] |
|
864 | 870 | oldfctx = None |
|
865 | 871 | pchange = phabchange(currentPath=fname) |
|
866 | 872 | |
|
867 | 873 | filemode = gitmode[fctx.flags()] |
|
868 | renamed = fctx.renamed() | |
|
874 | ||
|
875 | if copy: | |
|
876 | originalfname = copy.get(fname, fname) | |
|
877 | else: | |
|
878 | originalfname = fname | |
|
879 | if fctx.renamed(): | |
|
880 | originalfname = fctx.renamed()[0] | |
|
881 | ||
|
882 | renamed = fname != originalfname | |
|
869 | 883 | |
|
870 | 884 | if renamed: |
|
871 | originalfname = renamed[0] | |
|
872 | 885 | oldfctx = basectx.p1()[originalfname] |
|
873 | 886 | originalmode = gitmode[oldfctx.flags()] |
|
874 | 887 | pchange.oldPath = originalfname |
General Comments 0
You need to be logged in to leave comments.
Login now