aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'rewrite-git-blob.py')
-rwxr-xr-xrewrite-git-blob.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/rewrite-git-blob.py b/rewrite-git-blob.py
index 430e415..7af3146 100755
--- a/rewrite-git-blob.py
+++ b/rewrite-git-blob.py
@@ -47,6 +47,7 @@ mangler.append(functools.partial(
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
line = source.readline()
while line:
chunks = line.split()
@@ -56,6 +57,7 @@ def process_stream(source, output_dir, output):
data = source.read(size)
assert len(data) == size, (line, data)
data = data.replace(header, "$Header: /var/cvsroot")
+ data = data.replace(sourcekeyword, "%Source: /var/cvsroot")
line = 'data %i\n%s' % (len(data), data)
output.write(line)
line = source.readline()