# Command line too long in batch file for Gimp

I have run into an issue using GIMP's batch processing.

I have a lot of files spred over a directory tree which need to be processed by a script-fu. I tried to generate a batch file which calls my script for each of theses, but windows complains about the command line being to long.

Here is what my batch file looks like:

@echo off
gimp -d -i -b --verbose "(myscriptName \"path\\to\\file.png\") -b "(myscriptName \"other\\path\to\\file2.png\") [...]


continuing like this for about 360 files more.

Is there way to have gimp process my files without having to call gimp individually for each and all of them?

-
read what he explained above, so you will see that he has more than 20 + (49 x 362) = 17,758 characters. – kokbira Apr 26 '11 at 14:35

If you are using a Windows batch file, use the FOR command.