diff options
-rwxr-xr-x | rewrite-git-blob.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/rewrite-git-blob.py b/rewrite-git-blob.py index 9693bc8..18343b9 100755 --- a/rewrite-git-blob.py +++ b/rewrite-git-blob.py @@ -48,6 +48,7 @@ def process_stream(source, output_dir, output): header = os.path.normpath(os.path.abspath(output_dir)) header = "$Header: %s" % output_dir sourcekeyword = "$Source: %s" % output_dir + atticsearch = re.compile(r': /var/cvsroot/.*/Attic/') line = source.readline() while line: chunks = line.split() @@ -59,6 +60,8 @@ def process_stream(source, output_dir, output): data = data.replace(header, "$Header: /var/cvsroot") data = data.replace(sourcekeyword, "$Source: /var/cvsroot") data = data.replace("$Name: not supported by cvs2svn $", "$Name: $") + if atticsearch.search(data): + data = data.replace("Attic/", "") line = 'data %i\n%s' % (len(data), data) output.write(line) line = source.readline() |