Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
tree: 363f5b9246
Fetching contributors…

Cannot retrieve contributors at this time

executable file 28 lines (21 sloc) 0.491 kb
#!/usr/bin/env python
import sys
infile = sys.argv[1]
outfile = sys.argv[2]
params = sys.argv[3:]
fi = open(infile, 'r')
fo = open(outfile, 'w')
while fi:
line = fi.readline()
if not line:
break
for param in params:
terms = param.split(':')
# horribel hack
if terms[0].startswith('{') and terms[0].endswith('}'):
terms[0] = '$' + terms[0]
if line.find(terms[0]) >= 0:
line = line.replace(terms[0], terms[1])
fo.write(line)
fi.close()
fo.close()
Jump to Line
Something went wrong with that request. Please try again.