Debian Codegraph @

test cases/common/179 escape and unicode/file.py

raw
1 #!/usr/bin/env python3
2
3 import sys
4 import os
5
6 with open(sys.argv[1]) as fh:
7 content = fh.read().replace("{NAME}", sys.argv[2])
8
9 with open(os.path.join(sys.argv[3]), 'w', errors='replace') as fh:
10 fh.write(content)