diff --git a/source/dub/commandline.d b/source/dub/commandline.d index e96db83..9217dbd 100644 --- a/source/dub/commandline.d +++ b/source/dub/commandline.d @@ -134,6 +134,7 @@ else if (options.verbose) loglevel = LogLevel.diagnostic; else if (options.vquiet) loglevel = LogLevel.none; else if (options.quiet) loglevel = LogLevel.warn; + else if (options.verror) loglevel = LogLevel.error; setLogLevel(loglevel); } catch (Throwable e) { logError("Error processing arguments: %s", e.msg); @@ -254,7 +255,7 @@ /** Contains and parses options common to all commands. */ struct CommonOptions { - bool verbose, vverbose, quiet, vquiet; + bool verbose, vverbose, quiet, vquiet, verror; bool help, annotate, bare; string[] registry_urls; string root_path; @@ -279,6 +280,7 @@ args.getopt("v|verbose", &verbose, ["Print diagnostic output"]); args.getopt("vverbose", &vverbose, ["Print debug output"]); args.getopt("q|quiet", &quiet, ["Only print warnings and errors"]); + args.getopt("verror", &verror, ["Only print errors"]); args.getopt("vquiet", &vquiet, ["Print no messages"]); args.getopt("cache", &placementLocation, ["Puts any fetched packages in the specified location [local|system|user]."]); }