Ok, seemed I needed to use the console exe. Now code is:
"C:\Program Files (x86)\GIMP-2.0\bin\gimp-console-2.6.exe" -i -b "(save-as-jpg
"\"DSC_2636-Color24Bit.png\"" 0.7 "\"DSC_2636-Color24Bit.jpg\"")" -b
Now to see if i can speed up the loading of GIMP for this as it took a few
seconds longer to run than expected.
>I spent a bunch of time trying to figure out the correct syntax for running a
>scm that converted a file to .jpg.
>The GIMP help was fine for the scm code, but not so good for the command
>prompt of windows.
>Here is what I found to work for a script named save-as-jpg.scm:
>(i am on win 7 64 bit, hence the (x86) in the path...
>"C:\Program Files (x86)\GIMP-2.0\bin\gimp-2.6.exe" -i -b "(save-as-jpg
>"\"DSC_2636-Color24Bit.png\"" 0.7 "\"DSC_2636-Color24Bit.jpg\"")" -b
>that worked. The changes from what the help file says to use are:
>1) use full path of exe, in quotes.
>2) use double quotes around GIMP functions, not single quotes
>3) add double quote escape sequences around parameters that are strings
>I looked far and wide to figure this out, so would guess others would be
>interested in the summary of what i found.
>Only remaining issue so far is how to get the secondary dos window that pops
>up, to close when its done. I thought the "(gimp-quit 0)" did that, but guess
JamesMaeding (via gimpusers.com)
Gimp-user mailing list