diff options
author | Julien HENRY <julien.henry@sonarsource.com> | 2013-01-16 10:46:30 +0100 |
---|---|---|
committer | Julien HENRY <julien.henry@sonarsource.com> | 2013-01-16 10:46:30 +0100 |
commit | 240e7abe2af7caa5900865b4df59b3e9f6a9ec3e (patch) | |
tree | 249208593d8690db7a8c86ca439c1795391a90ee /src/main/java | |
parent | 23afb6181f677e423e2c7852f6578a3a25ee1493 (diff) | |
download | sonar-scanner-cli-240e7abe2af7caa5900865b4df59b3e9f6a9ec3e.tar.gz sonar-scanner-cli-240e7abe2af7caa5900865b4df59b3e9f6a9ec3e.zip |
SONARPLUGINS-2604 -X implies -e
* Enabling debug mode with -X should also display stack traces
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/org/sonar/runner/Main.java | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main/java/org/sonar/runner/Main.java b/src/main/java/org/sonar/runner/Main.java index 4d73b35..59c302c 100644 --- a/src/main/java/org/sonar/runner/Main.java +++ b/src/main/java/org/sonar/runner/Main.java @@ -81,6 +81,9 @@ public final class Main { } private int execute(Properties argsProperties) { + if (displayStackTrace) { + Logs.info("Error stacktraces are turned on."); + } Stats stats = new Stats().start(); try { loadProperties(argsProperties); @@ -256,10 +259,10 @@ public final class Main { } else if ("-e".equals(arg) || "--errors".equals(arg)) { displayStackTrace = true; - Logs.info("Error stacktraces are turned on."); } else if ("-X".equals(arg) || "--debug".equals(arg)) { props.setProperty(Runner.PROPERTY_VERBOSE, "true"); + displayStackTrace = true; debugMode = true; } else if ("-D".equals(arg) || "--define".equals(arg)) { |