Change meaning of -v flag from --version to --verbose

This commit is contained in:
AsamK 2022-06-11 18:23:33 +02:00
parent 08dc65350f
commit 1ea4309a2a
3 changed files with 5 additions and 5 deletions

View file

@ -31,10 +31,10 @@ In daemon mode messages are continuously received.
*-h*, *--help*:: *-h*, *--help*::
Show help message and quit. Show help message and quit.
*-v*, *--version*:: *--version*::
Print the version and quit. Print the version and quit.
*--verbose*:: *-v*, *--verbose*::
Raise log level and include lib signal logs. Raise log level and include lib signal logs.
*--log-file* LOG_FILE:: *--log-file* LOG_FILE::

View file

@ -64,8 +64,8 @@ public class App {
.description("Commandline interface for Signal.") .description("Commandline interface for Signal.")
.version(BaseConfig.PROJECT_NAME + " " + BaseConfig.PROJECT_VERSION); .version(BaseConfig.PROJECT_NAME + " " + BaseConfig.PROJECT_VERSION);
parser.addArgument("-v", "--version").help("Show package version.").action(Arguments.version()); parser.addArgument("--version").help("Show package version.").action(Arguments.version());
parser.addArgument("--verbose") parser.addArgument("-v", "--verbose")
.help("Raise log level and include lib signal logs. Specify multiple times for even more logs.") .help("Raise log level and include lib signal logs. Specify multiple times for even more logs.")
.action(Arguments.count()); .action(Arguments.count());
parser.addArgument("--log-file") parser.addArgument("--log-file")

View file

@ -80,7 +80,7 @@ public class Main {
.includeArgumentNamesAsKeysInResult(true) .includeArgumentNamesAsKeysInResult(true)
.build() .build()
.defaultHelp(false); .defaultHelp(false);
parser.addArgument("--verbose").action(Arguments.count()); parser.addArgument("-v", "--verbose").action(Arguments.count());
parser.addArgument("--log-file").type(File.class); parser.addArgument("--log-file").type(File.class);
try { try {