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