python: Material: *.py: Fix syntax for Python 3
This commit is contained in:
parent
34a3039577
commit
de89c2e178
|
@ -101,7 +101,7 @@ if __name__ == '__main__':
|
|||
# checking on the options
|
||||
for o, a in opts:
|
||||
if o in ("-c", "--output-csv"):
|
||||
print "writing file: " + a + "\n"
|
||||
print("writing file: " + a + "\n")
|
||||
OutPath = a
|
||||
|
||||
# runing through the files
|
||||
|
@ -109,5 +109,5 @@ if __name__ == '__main__':
|
|||
|
||||
kv_map = importFCMat(FileName)
|
||||
for k in kv_map.keys():
|
||||
print repr(k) + " : " + repr(kv_map[k])
|
||||
print(repr(k) + " : " + repr(kv_map[k]))
|
||||
sys.exit(0) # no error
|
||||
|
|
|
@ -126,7 +126,7 @@ def write(filename,dictionary):
|
|||
if isinstance(filename,unicode):
|
||||
import sys
|
||||
filename = filename.encode(sys.getfilesystemencoding())
|
||||
print filename
|
||||
print(filename)
|
||||
f = pythonopen(filename,"wb")
|
||||
f.write("; " + header["CardName"].encode("utf8") + "\n")
|
||||
f.write("; " + header["AuthorAndLicense"].encode("utf8") + "\n")
|
||||
|
|
Loading…
Reference in New Issue
Block a user