##// END OF EJS Templates
dirstate: remove a update_file's special case for tracked file with p2 data...
marmoute -
r48920:d4e715d2 default
parent child Browse files
Show More
@@ -226,16 +226,7 b' class dirstatemap(object):'
226 elif (p1_tracked or p2_tracked) and not wc_tracked:
226 elif (p1_tracked or p2_tracked) and not wc_tracked:
227 pass
227 pass
228 elif clean_p2 and wc_tracked:
228 elif clean_p2 and wc_tracked:
229 if p1_tracked or self.get(filename) is not None:
229 pass
230 # XXX the `self.get` call is catching some case in
231 # `test-merge-remove.t` where the file is tracked in p1, the
232 # p1_tracked argument is False.
233 #
234 # In addition, this seems to be a case where the file is marked
235 # as merged without actually being the result of a merge
236 # action. So thing are not ideal here.
237 merged = True
238 clean_p2 = False
239 elif not p1_tracked and p2_tracked and wc_tracked:
230 elif not p1_tracked and p2_tracked and wc_tracked:
240 clean_p2 = True
231 clean_p2 = True
241 elif possibly_dirty:
232 elif possibly_dirty:
@@ -796,12 +796,15 b' def recordupdates(repo, actions, branchm'
796 for f, args, msg in actions.get(ACTION_GET, []):
796 for f, args, msg in actions.get(ACTION_GET, []):
797 if branchmerge:
797 if branchmerge:
798 # tracked in p1 can be True also but update_file should not care
798 # tracked in p1 can be True also but update_file should not care
799 old_entry = repo.dirstate.get_entry(f)
800 p1_tracked = old_entry.any_tracked and not old_entry.added
799 repo.dirstate.update_file(
801 repo.dirstate.update_file(
800 f,
802 f,
801 p1_tracked=False,
803 p1_tracked=p1_tracked,
802 p2_tracked=True,
804 p2_tracked=True,
803 wc_tracked=True,
805 wc_tracked=True,
804 clean_p2=True,
806 clean_p2=not p1_tracked,
807 merged=p1_tracked,
805 )
808 )
806 else:
809 else:
807 parentfiledata = getfiledata[f] if getfiledata else None
810 parentfiledata = getfiledata[f] if getfiledata else None
General Comments 0
You need to be logged in to leave comments. Login now