XBuild error
Closed this issue · 8 comments
Using the code below, I receive the following error:
{ [Error: Command failed: /bin/sh: Build: command not found ] killed: false, code: 127, signal: null }
return gulp.src(projects) //variable that points to solution/projects
.pipe(msbuild({
configuration: configuration, //variable that points to either Debug or Release
targets: ["Clean", "Build"],
errorOnFail: true,
stdout: true
}));
I only see this error on my Mac. I do not have this issue on Windows. Any idea what's the issue?
Huh..
Could you run again with the option logCommand: true
.
Looks like the command was generated wrong.
Here is the command:
"xbuild" "/path-to-sln/name.sln" /target:Clean;Build /verbosity:normal /toolsversion:4.0 /nologo /maxcpucount /property:Configuration="Development"
Hm looks like the semicolon of the targets is a problem.
Can you try these:
- Use only one Target for example:
targets: ["Rebuild"]
- Execute the command manually but wrap the targets in double quotes:
xbuild "/path-to-sln/name.sln" /target:"Clean;Build" /verbosity:normal /toolsversion:4.0 /nologo /maxcpucount /property:Configuration="Development"
Work both?
I think both of those "work", however not I am getting the "MSBUILD0004: Too many project files specified". Have you seen that error before?
Okay thanks, i will fix this.
For the error: Never heard of such an error and im also not sure what this means... Looks like a problem in the .sln
file.
The quote problem is solved.
Looks like it broke the Windows msbuild system.
The target "Clean;Build" does exist in project.
Should work again with latest version