##// END OF EJS Templates
largefile: adjust the dirstate post update within a `parentchange` context...
marmoute -
r48502:0149d17d default
parent child Browse files
Show More
@@ -1796,23 +1796,24 b' def mergeupdate(orig, repo, node, branch'
1796 raise error.ProgrammingError(
1796 raise error.ProgrammingError(
1797 b'largefiles is not compatible with in-memory merge'
1797 b'largefiles is not compatible with in-memory merge'
1798 )
1798 )
1799 result = orig(repo, node, branchmerge, force, *args, **kwargs)
1799 with lfdirstate.parentchange():
1800 result = orig(repo, node, branchmerge, force, *args, **kwargs)
1800
1801
1801 newstandins = lfutil.getstandinsstate(repo)
1802 newstandins = lfutil.getstandinsstate(repo)
1802 filelist = lfutil.getlfilestoupdate(oldstandins, newstandins)
1803 filelist = lfutil.getlfilestoupdate(oldstandins, newstandins)
1803
1804
1804 # to avoid leaving all largefiles as dirty and thus rehash them, mark
1805 # to avoid leaving all largefiles as dirty and thus rehash them, mark
1805 # all the ones that didn't change as clean
1806 # all the ones that didn't change as clean
1806 for lfile in oldclean.difference(filelist):
1807 for lfile in oldclean.difference(filelist):
1807 lfdirstate.normal(lfile)
1808 lfdirstate.normal(lfile)
1808 lfdirstate.write()
1809 lfdirstate.write()
1809
1810
1810 if branchmerge or force or partial:
1811 if branchmerge or force or partial:
1811 filelist.extend(s.deleted + s.removed)
1812 filelist.extend(s.deleted + s.removed)
1812
1813
1813 lfcommands.updatelfiles(
1814 lfcommands.updatelfiles(
1814 repo.ui, repo, filelist=filelist, normallookup=partial
1815 repo.ui, repo, filelist=filelist, normallookup=partial
1815 )
1816 )
1816
1817
1817 return result
1818 return result
1818
1819
General Comments 0
You need to be logged in to leave comments. Login now