Mercurial > hg
comparison mercurial/copies.py @ 24186:61aadba2396e
copies: calculate 'bothnew' from manifestdict.filesnotin()
In the same spirit as the previous change, let's now calculate the
'bothnew' variable using manifestdict.filesnotin().5D
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Fri, 27 Feb 2015 14:03:01 -0800 |
parents | 3a3806fe3ddf |
children | 30219bd46ed7 |
comparison
equal
deleted
inserted
replaced
24185:3a3806fe3ddf | 24186:61aadba2396e |
---|---|
300 renamedelete[of] = [f for f in fl if f in c1 or f in c2] | 300 renamedelete[of] = [f for f in fl if f in c1 or f in c2] |
301 renamedelete2.update(fl) # reverse map for below | 301 renamedelete2.update(fl) # reverse map for below |
302 else: | 302 else: |
303 diverge2.update(fl) # reverse map for below | 303 diverge2.update(fl) # reverse map for below |
304 | 304 |
305 bothnew = sorted([d for d in m1 if d in m2 and d not in ma]) | 305 addedinm1 = m1.filesnotin(ma) |
306 addedinm2 = m2.filesnotin(ma) | |
307 bothnew = sorted(addedinm1 & addedinm2) | |
306 if bothnew: | 308 if bothnew: |
307 repo.ui.debug(" unmatched files new in both:\n %s\n" | 309 repo.ui.debug(" unmatched files new in both:\n %s\n" |
308 % "\n ".join(bothnew)) | 310 % "\n ".join(bothnew)) |
309 bothdiverge, _copy, _fullcopy = {}, {}, {} | 311 bothdiverge, _copy, _fullcopy = {}, {}, {} |
310 for f in bothnew: | 312 for f in bothnew: |