diff options
-rw-r--r-- | test/DVIPS/DVIPS.py | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/test/DVIPS/DVIPS.py b/test/DVIPS/DVIPS.py index 256258f..1774695 100644 --- a/test/DVIPS/DVIPS.py +++ b/test/DVIPS/DVIPS.py @@ -38,10 +38,10 @@ import sys import getopt cmd_opts, arg = getopt.getopt(sys.argv[1:], 'i:r:', []) base_name = os.path.splitext(arg[0])[0] -infile = open(arg[0], 'rb') -out_file = open(base_name+'.dvi', 'wb') +infile = open(arg[0], 'r') +out_file = open(base_name+'.dvi', 'w') for l in infile.readlines(): - if l[:4] != b'#tex': + if l[:4] != '#tex': out_file.write(l) sys.exit(0) """) @@ -52,8 +52,8 @@ import sys import getopt cmd_opts, arg = getopt.getopt(sys.argv[1:], 'i:r:', []) base_name = os.path.splitext(arg[0])[0] -infile = open(arg[0], 'rb') -out_file = open(base_name+'.dvi', 'wb') +infile = open(arg[0], 'r') +out_file = open(base_name+'.dvi', 'w') for l in infile.readlines(): if l[:6] != b'#latex': out_file.write(l) @@ -63,10 +63,10 @@ sys.exit(0) test.write('mydvips.py', r""" import os import sys -infile = open(sys.argv[3], 'rb') -out_file = open(sys.argv[2], 'wb') +infile = open(sys.argv[3], 'r') +out_file = open(sys.argv[2], 'w') for l in infile.readlines(): - if l[:6] != b'#dvips': + if l[:6] != '#dvips': out_file.write(l) sys.exit(0) """) |