mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 07:17:55 +03:00
convert: record deleted files in monotone source
This commit is contained in:
parent
bddf3af283
commit
d098a6938d
@ -26,6 +26,7 @@ class monotone_source(converter_source, commandline):
|
||||
self.add_file_re = re.compile(space + "add_file" + name + "content" + revision)
|
||||
self.patch_re = re.compile(space + "patch" + name + "from" + revision + "to" + revision)
|
||||
self.rename_re = re.compile(space + "rename" + name + "to" + name)
|
||||
self.delete_re = re.compile(space + "delete" + name)
|
||||
self.tag_re = re.compile(space + "tag" + name + "revision" + revision)
|
||||
self.cert_re = re.compile(lines + space + "name" + name + "value" + value)
|
||||
|
||||
@ -137,6 +138,9 @@ class monotone_source(converter_source, commandline):
|
||||
# Delete/rename is handled later when the convert engine
|
||||
# discovers an IOError exception from getfile,
|
||||
# but only if we add the "from" file to the list of changes.
|
||||
m = self.delete_re.match(e)
|
||||
if m:
|
||||
files[m.group(1)] = rev
|
||||
m = self.rename_re.match(e)
|
||||
if m:
|
||||
toname = m.group(2)
|
||||
|
@ -69,7 +69,6 @@ cd repo.mtn-hg
|
||||
hg up -C
|
||||
glog
|
||||
echo % manifest
|
||||
# BUG: c and dir/b should not appear here
|
||||
hg manifest
|
||||
echo % contents
|
||||
cat dir/a
|
||||
|
@ -32,18 +32,16 @@ scanning source...
|
||||
sorting...
|
||||
converting...
|
||||
0 update2
|
||||
5 files updated, 0 files merged, 0 files removed, 0 files unresolved
|
||||
@ 2 "update2" files: bin bin2 e
|
||||
3 files updated, 0 files merged, 0 files removed, 0 files unresolved
|
||||
@ 2 "update2" files: bin bin2 dir/b e
|
||||
|
|
||||
o 1 "update1" files: a bin dir/a dir/b
|
||||
o 1 "update1" files: a bin c dir/a dir/b
|
||||
|
|
||||
o 0 "initialize" files: a bin c dir/b
|
||||
|
||||
% manifest
|
||||
bin2
|
||||
c
|
||||
dir/a
|
||||
dir/b
|
||||
e
|
||||
% contents
|
||||
a
|
||||
|
Loading…
Reference in New Issue
Block a user