mirror of
https://github.com/facebook/sapling.git
synced 2025-01-06 04:43:19 +03:00
manifest: process deletes before adds in workingctx.buildmanifest
Summary: The Rust manifest does not allow for directories to be added if files with the same name exist. Reviewed By: quark-zju Differential Revision: D17143550 fbshipit-source-id: fe2533b6f0c049d7b22f2fbb49f3e04959aea39c
This commit is contained in:
parent
edfeb9f529
commit
429292dfe3
@ -1993,6 +1993,9 @@ class workingctx(committablectx):
|
||||
man = parents[0].manifest().copy()
|
||||
|
||||
ff = self._flagfunc
|
||||
for f in status.deleted + status.removed:
|
||||
if f in man:
|
||||
del man[f]
|
||||
for i, l in ((addednodeid, status.added), (modifiednodeid, status.modified)):
|
||||
for f in l:
|
||||
man[f] = i
|
||||
@ -2001,10 +2004,6 @@ class workingctx(committablectx):
|
||||
except OSError:
|
||||
pass
|
||||
|
||||
for f in status.deleted + status.removed:
|
||||
if f in man:
|
||||
del man[f]
|
||||
|
||||
return man
|
||||
|
||||
def _buildstatus(self, other, s, match, listignored, listclean, listunknown):
|
||||
|
Loading…
Reference in New Issue
Block a user