feat: rewrite huge parts

- real config parsing
- actually working parts, with support for string parts
- handle readonly config (preparation for use with Nix)
- cleanup cli (remove colors, fancy stuff etc., keep it minimal)
- switch to tracing for logging
This commit is contained in:
TECHNOFAB 2024-12-27 13:46:25 +01:00
parent 5b895b7939
commit 5e120a6ab8
No known key found for this signature in database
GPG key ID: D06FBA11BA6FF836
8 changed files with 522 additions and 230 deletions

View file

@ -1,22 +1,13 @@
[bumpversion]
current_version = 0.1.4
commit = True
tag = True
parse = (?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(-(?P<stage>[^.]*)\.(?P<devnum>\d+))?
serialize =
{major}.{minor}.{patch}-{stage}.{devnum}
{major}.{minor}.{patch}
current_version = "0.1.4"
commit = true
tag = true
# parse = '(?P<major>\d+)\.(?P<minor>\d+)\.(?P<patch>\d+)(-(?P<stage>[^.]*)\.(?P<devnum>\d+))?'
# serialize = "{major}.{minor}.{patch}-{stage}.{devnum}"
[bumpversion:part:stage]
optional_value = stable
first_value = stable
values =
alpha
beta
stable
# example part:
[part.stage]
type = "string"
values = ["alpha", "beta", "stable"]
[bumpversion:part:devnum]
[bumpversion:file:Cargo.toml]
search = version = "{current_version}"
replace = version = "{new_version}"
[file."Cargo.toml"]
format = 'version = "{version}"'