aboutsummaryrefslogtreecommitdiffstats
path: root/main
diff options
context:
space:
mode:
Diffstat (limited to 'main')
-rw-r--r--main/src/main/java/org/onap/cli/main/OnapCli.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/main/src/main/java/org/onap/cli/main/OnapCli.java b/main/src/main/java/org/onap/cli/main/OnapCli.java
index 8a4ebeb1..36db86c3 100644
--- a/main/src/main/java/org/onap/cli/main/OnapCli.java
+++ b/main/src/main/java/org/onap/cli/main/OnapCli.java
@@ -69,6 +69,13 @@ public class OnapCli {
private void print(Throwable throwable) {
System.out.println(throwable.getMessage());
+ try {
+ if (OnapCommandRegistrar.getRegistrar().isDevMode()) {
+ throwable.printStackTrace();
+ }
+ } catch (OnapCommandException e) {
+ // NOSONAR
+ }
}
private String getShortOption(String opt) {