python2/3

This commit is contained in:
j 2019-02-14 22:10:24 +05:30
parent e8c8356dc9
commit 0b612a1873

View file

@ -1,5 +1,5 @@
#!/usr/bin/env python #!/usr/bin/env python
from __future__ import division, with_statement from __future__ import division, with_statement, print_function
from contextlib import closing from contextlib import closing
import json import json
@ -140,7 +140,7 @@ if __name__ == '__main__':
if len(sys.argv) == 1: if len(sys.argv) == 1:
target = os.path.expanduser("~/Library/Application Support/Open Media Library") target = os.path.expanduser("~/Library/Application Support/Open Media Library")
elif len(sys.argv) != 2: elif len(sys.argv) != 2:
print "usage: %s [target]" % sys.argv[0] print("usage: %s [target]" % sys.argv[0])
sys.exit(1) sys.exit(1)
else: else:
target = sys.argv[1] target = sys.argv[1]