Skip to content

Commit

Permalink
Print exit code when project parsing fails (#137)
Browse files Browse the repository at this point in the history
Sometimes the project file parsing fails but both console and error
output are empty. So exit code is the only easy way to get some
helpful information.

Change-Id: I6f6bcaf983ffb503f0a47936b877912ef6c8adf6
  • Loading branch information
dfev77 authored Sep 25, 2024
1 parent ada81d9 commit feff256
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/groovy/com/ullink/Msbuild.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ class Msbuild extends ConventionTask {
exec.ignoreExitValue = true
}
if (parser.exitValue != 0) {
throw new GradleException("Failed to parse project, output: ${parseOutputStream}, error: ${errorOutputStream}")
throw new GradleException("Failed to parse project, exit code: ${parser.exitValue}, output: '${parseOutputStream},' error: '${errorOutputStream}'")
}

def processOutput = parseOutputStream.toString()
Expand Down

0 comments on commit feff256

Please sign in to comment.