Pillow/winbuild/fixproj.py

9 lines
276 B
Python
Raw Normal View History

2015-06-16 23:29:41 +03:00
import sys
2014-03-19 07:59:42 +04:00
with open(sys.argv[1], 'r') as fd:
content = '\n'.join(line.strip() for line in fd if line.strip())
if len(sys.argv) == 3:
content = content.replace('Win32', sys.argv[2]).replace('x64', sys.argv[2])
with open(sys.argv[1], 'w') as fd:
fd.write(content)