Question

I'm using the svncommit task from the MSBuild Community Tasks Project. Unfortunately I've got a fairly large bunch of files to commit & it fails with this error:

The command-line for the "SvnCommit" task is too long. Command-lines longer than 32000 characters are likely to fail. Try reducing the length of the command-line by breaking down the call to "SvnCommit" into multiple calls with fewer parameters per call.

I tried just pointing the Targets parameter at the parent folder, but it seems to want the files. Is there any way I can tell it to just commit all the pending files within a folder?

Was it helpful?

Solution

Actually that bug mentioned was resgen.exe specific. In this case it's simply because the task you're using is passing parameters literally to the .exe, rather than using a response file. Windows won't accept more than 32KB of parameters for a process. That's why the shipping MSBuild tasks always use response files.

(In the case of the bug mentioned, they were using the 3.5 resgen which didn't support them, and were attempting to work around this by invoking it repeatedly with a subset of the files. Unfortunately the math was wrong.)

You'll need to either ask for the task to be fixed to use response files, or shorten the paths of the files you're using, perhaps by moving them closer to the root of the disk, or by using "subst".

Dan (MSbuild dev)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top