Dear Saul, Thanks for your help. I was eventually successful in running my batch GIMP script from the Windows XP command line, by using either of the following commands:
gimp-2.4 -i -b "(batch-CUPify \"D:\\Documents and Settings\\spk30\\Desktop\\alison_sl1_dear_friend_backup\\*\") (gimp-quit 0)" gimp-2.4 -i -b "(batch-CUPify \"*.png\") (gimp-quit 0)" and altering the script to read thus: ; Batch apply the CUPify script (define (batch-CUPify pattern) (let* ( (filelist (cadr (file-glob pattern 1)))) (while (not (null? filelist)) (let* ( (filename (car filelist)) (image (car (gimp-file-load RUN-NONINTERACTIVE filename filename))) (drawable (car (gimp-image-get-active-layer image)))) ; Erode the image (plug-in-erode 1 image drawable 1 1 0.5 7 128 128) ; Photocopy the image (plug-in-photocopy 1 image drawable 35.51 0.583 0.342 0.200) ; Erode the image (plug-in-erode 1 image drawable 1 1 0.5 7 128 128) ; Flush the display (gimp-displays-flush) ; Save the image (gimp-file-save RUN-NONINTERACTIVE image drawable filename filename) (gimp-image-delete image)) (set! filelist (cdr filelist)))) ) (script-fu-register "batch-CUPify" "Batch-CUPify" "Make an image look like it was scanned to PDF by CUP" "Sam Kuper" "Sam Kuper" "2007" "GRAY*" SF-IMAGE "Image" 0 SF-DRAWABLE "Layer to process" 0) ; End script Many thanks for the help, Sam Kuper On 10/11/2007, [EMAIL PROTECTED] < [EMAIL PROTECTED]> wrote: > > I do not believe that single-quoting a command line argument in Windows > works the same as BASH (Linux). Try using double-quotes and escape any > double-quotes which appear in your argument: > > gimp -i -b "(batch-CUPify \"*.png\")" -b "(gimp-quit 0)" > > If you include directories in your path, also escape your backslashes: > > gimp -i -b "(batch-CUPify \"D:\\Documents and > Settings\\spk30\\Desktop\\alison_sl1_dear_friend_backup\\*.png\")" -b > "(gimp-quit 0)" > > You may need to experiment as I do not run Windows and have no way of > testing the commands. > > > > I am using GIMP 2.4.1 on Windows XP, and I am trying to run the script > by > > going to the command prompt, changing to a directory full of .png files > I > > want to process with the script, and entering the command: > > > > gimp-2.4 -i -b '(batch-CUPify "*.png")' '(gimp-quit 0)' > > > > This gives me the following messages: > > > > "GIMP-Error: Opening 'D:\Documents and > > Settings\spk30\Desktop\alison_sl1_dear_fri > > end_backup\*.png)'' failed: Invalid argument > > > > GIMP-Error: Opening 'D:\Documents and > > Settings\spk30\Desktop\alison_sl1_dear_fri > > end_backup\'(gimp-quit' failed: No such file or directory > > > > GIMP-Error: Opening 'D:\Documents and > > Settings\spk30\Desktop\alison_sl1_dear_fri > > end_backup\0)'' failed: No such file or directory > > > > No batch interpreter specified, using the default > > 'plug-in-script-fu-eval'. > > batch command: executed successfully." > > > > > > I would be very grateful for any help you can offer. > > > > Many thanks in advance, > > > > Sam > > _______________________________________________ > > Gimp-user mailing list > > Gimp-user@lists.XCF.Berkeley.EDU > > https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user > >
_______________________________________________ Gimp-user mailing list Gimp-user@lists.XCF.Berkeley.EDU https://lists.XCF.Berkeley.EDU/mailman/listinfo/gimp-user