Skip to content

Commit

Permalink
Release: Add '--version'
Browse files Browse the repository at this point in the history
  • Loading branch information
3j14 committed Nov 9, 2024
1 parent d054406 commit 69dd4ef
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
# Changelog

## 0.3.0

Add the `--version` command line argument.

## 0.2.1

## Fixes
### Fixes

Fix crash when specifying a config file using the `-c` command line
argument.
Expand Down
5 changes: 5 additions & 0 deletions bumgr/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@

logger = logging.getLogger("bumgr.main")

__version__ = "0.3.0"


def _cli_get_all(
config: dict,
Expand Down Expand Up @@ -59,6 +61,9 @@ def cli():
prog="bumgr",
description="Manage backups with restic on macOS and Linux",
)
parser.add_argument(
"--version", action="version", version=f"%(prog)s {__version__}"
)
parser.add_argument(
"-c",
"--config",
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "bumgr"
version = "0.2.1"
version = "0.3.0"
authors = [
{name = "Jonas Drotleff", email = "[email protected]"},
]
Expand Down

0 comments on commit 69dd4ef

Please sign in to comment.