feat: print version info on "-V" calls

closes #11222
This commit is contained in:
Matthias
2025-01-24 07:17:36 +01:00
parent 08b18b7ff6
commit 27a9cbf5e4
3 changed files with 13 additions and 5 deletions

View File

@@ -59,8 +59,13 @@ AVAILABLE_CLI_OPTIONS = {
"version": Arg(
"-V",
"--version",
action="version",
version=f"%(prog)s {__version__}",
action="store_true",
),
"version_main": Arg(
# Copy of version - used to have -V available with and without subcommand.
"-V",
"--version",
action="store_true",
),
"config": Arg(
"-c",