structurizr / cli

A command line utility for Structurizr.
https://docs.structurizr.com/cli
Apache License 2.0
492 stars 75 forks source link

Provide a dedicated version command #122

Closed MLNW closed 1 year ago

MLNW commented 1 year ago

Description

I was surprised to find that structurizr --version produces an output with the version and then fails. It took me a moment to realize that there simply is no version command and that's why it fails.

$ structurizr --version
structurizr-cli: 1.30.0
Usage: structurizr push|pull|lock|unlock|export|validate|list|help [options]
$ echo $?
1

I'd say it is a standard to have a dedicated way to query the version of a CLI. Therefore, I think it would be a good idea to add this small feature.

For some context: I'm using this as a very basic check if the CLI is correctly installed in a docker image that is built via a CI pipeline. For now I guess I will use the help command as a workaround. For reference, output from PlantUML:

$ plantuml --version
PlantUML version 1.2023.8 (Sun May 21 08:38:00 UTC 2023)
(GPL source distribution)
Java Runtime: OpenJDK Runtime Environment
JVM: OpenJDK 64-Bit Server VM
Default Encoding: UTF-8
Language: en
Country: US

PLANTUML_LIMIT_SIZE: 4096
Dot version: dot - graphviz version 2.40.1 (20161225.0304)
Installation seems OK. File generation OK

Priority

Low

Resolution

I have no budget, please add this feature for free

More information

No response