bver 0.1.0
A bump-version tool for multi-language projects

Features
- Multi-format version support: Handles Python (PEP 440), Semver (npm/Cargo), and simple
major.minor.patchversions - Automatic version casting: Convert between version formats when needed (e.g.,
1.2.3a1to1.2.3-alpha.1) - Interactive TUI: Review and selectively apply version changes with a terminal UI
- Git integration: Automatic commits, tags, and pushes
- Pre-commit hook support: Run pre-commit hooks before committing version bumps
- Flexible configuration: Configure via
bver.toml,pyproject.toml,package.json, orCargo.toml
Installation
macOS / Linux
|
Windows (PowerShell)
powershell -ExecutionPolicy ByPass -c "irm https://github.com/flaport/bver/releases/latest/download/install.ps1 | iex"
With pip / uv
# or: pip install bver-cli
From source (with Cargo)
Usage
# Show current version
# Show full configuration
# Bump version
# Pre-release versions
# Post-release and dev versions
# Release (strip pre-release suffix)
# Set explicit version
# Force git operations (overwrite tags, force push)
Configuration
Standalone (bver.toml)
= "1.2.3"
# Optional settings
= 3 # Lines of context in diff preview
= "any" # any | simple | python | semver
= "error" # error | cast
[]
= "commit-and-tag" # disabled | commit | commit-and-tag | commit-tag-and-push
= "when-present" # enabled | disabled | when-present
= "{new-version}" # Template for git tag name
= "Bump version from {current-version} to {new-version}"
[[]]
= "src/version.py"
= "python" # pep440
[[]]
= "package.json"
= "semver" # javascript, rust, ...
[[]]
= "test.txt"
= "simple" # strict major.minor.patch format.
Template Variables
The tag-template and commit-template settings support these variables:
{current-version}- the version before bumping{new-version}- the version after bumping
Example: tag-template = "v{new-version}" produces tags like v1.2.3.
Python projects (pyproject.toml)
[]
= "1.2.3"
[]
= "commit-tag-and-push"
[[]]
= "src/mypackage/__init__.py"
= "python"
Node.js projects (package.json)
Rust projects (Cargo.toml)
[]
= "1.2.3"
[]
= "commit-and-tag"
[[]]
= "src/lib.rs"
= "semver"
Version Formats
| Kind | Format | Example |
|---|---|---|
any |
Any string (no validation) | v1.2.3-custom |
simple |
major.minor.patch |
1.2.3 |
python |
PEP 440 | 1.2.3a1.post1.dev1+local |
semver |
Semantic Versioning | 1.2.3-alpha.1+build |
Version Casting
When on-invalid-version = "cast", bver automatically converts versions between formats:
- To simple: Strips pre-release, post, dev, local, and epoch (
1.2.3a1->1.2.3) - To semver: Converts Python pre-releases (
1.2.3a1->1.2.3-alpha.1) - To python: Most formats are already valid PEP 440
TUI Controls
When bumping versions, an interactive TUI shows proposed changes:
| Key | Action |
|---|---|
↑/↓ or j/k |
Navigate changes |
Space |
Toggle selection |
a |
Select all |
n |
Deselect all |
Enter |
Apply selected changes |
q/Esc |
Cancel |
Git Actions
| Setting | Behavior |
|---|---|
disabled |
No git operations |
commit |
Stage all + commit |
commit-and-tag |
Stage all + commit + annotated tag |
commit-tag-and-push |
Stage all + commit + tag + push + push tag |
Use --force to overwrite existing tags and force push.
A note on AI
- I just made AI write what I want my version bumper to be. The code in this project is entirely written by Claude. That being said, human contributions are also welcome 😉.
License
MIT