Last active
August 29, 2015 14:26
-
-
Save marcinwol/a0f7bf5608ce7b2279b4 to your computer and use it in GitHub Desktop.
Start gimp from IrfanView in Ubuntu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
# | |
# add this, for example, /home/marcin/bin/startgimp.py | |
# to IfranViews Miscellaneus Properties/Settings | |
# | |
import os | |
import sys | |
gimp_cmd = '/usr/bin/gimp-2.8 ' | |
if len(sys.argv) == 2: | |
img_file = sys.argv[1] | |
img_file = img_file.replace('\\', '/') | |
img_file = img_file.replace('Z:', '') | |
gimp_cmd += '"'+img_file+'"' | |
#with open('/home/marcin/Desktop/test.txt', 'w') as f: | |
# f.write(img_file) | |
#print(gimp_cmd ) | |
os.system(gimp_cmd ) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment