equal
deleted
inserted
replaced
1 # $Hg: hgkwencode.py,v$ |
|
2 |
|
3 import re, sys |
|
4 |
|
5 def kwencode(): |
|
6 '''Truncates keywords in IO stream.''' |
|
7 |
|
8 re_kwtrunc = re.compile(r'([$]Hg: .+?,v) [a-z0-9]{12} [^$]+? \$') |
|
9 sys.stdout.write(re_kwtrunc.sub(r'\1$', sys.stdin.read())) |
|