diff --git a/ROADMAP.md b/ROADMAP.md index ccc0718..939f93e 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -13,7 +13,7 @@ Initial release after the hackathon Optionally: - [x] Add command to echo db version and path -- [ ] Add `otp --version` option to echo the application's version (if not here, +- [x] Add `otp --version` option to echo the application's version (if not here, then a must in one of later versions) ## 0.3.0 diff --git a/onetimepass/otp.py b/onetimepass/otp.py index 11db9c1..fb791fb 100644 --- a/onetimepass/otp.py +++ b/onetimepass/otp.py @@ -112,6 +112,7 @@ def validation_error_to_str(error: pydantic.ValidationError) -> str: @click.group(context_settings={"help_option_names": ["-h", "--help"]}) +@click.version_option() @click.option("color", "-c/-C", "--color/--no-color", default=True, show_default=True) @click.option("quiet", "-q", "--quiet", is_flag=True) @click.option(