Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Python Plugin from .bat
#4
(02-01-2022, 03:56 PM)Kevin Wrote: Where have you put save2png.py ? because you're expecting the import save2png to be able to find it.

Your GIMP installation directory is somewhat unusual as well.

save2png.py is in the same path as the .bat, because I guessed that's what sys.path=['.']+sys.path is supposed to do. To be honest I am not completely sure, what it does. I also tried to link there with sys.path.append(%~dp0) but to no avail.

It's a portable installation, therefore the strange install dir.


(02-01-2022, 04:04 PM)Ofnuts Wrote: Change your escaped quotes to single quotes. And answer Kevin's questions. But if it just to convert between file formats, ImageMagick is normally a much better option.

I thought that single quotes are not allowed in command lines, but I will try. Thanks for the input!

No, it's not just for conversion, that's just the most simple example I could find to test the call from .bat.
Reply


Messages In This Thread
Python Plugin from .bat - by Eonwe - 02-01-2022, 01:51 PM
RE: Python Plugin from .bat - by Kevin - 02-01-2022, 03:56 PM
RE: Python Plugin from .bat - by Ofnuts - 02-01-2022, 04:04 PM
RE: Python Plugin from .bat - by Eonwe - 02-01-2022, 05:11 PM
RE: Python Plugin from .bat - by Eonwe - 02-03-2022, 02:58 PM

Forum Jump: