release:cli
Release a new version of splent_cli to GitHub and PyPI.
Usage
splent release:cli [<version>] [--skip-checks]
When <version> is omitted, the interactive semver wizard runs. It fetches the latest tag from GitHub and offers patch, minor, or major bump options.
--skip-checks bypasses the pre-release gate (lint + tests), for emergencies only.
Examples
Interactive (recommended).
splent release:cli
Fetching current version from GitHub...
Current version: v1.3.0
Bump type:
[1] patch v1.3.1 bug fixes, no new features
[2] minor v1.4.0 new features, backward compatible
[3] major v2.0.0 breaking changes
[4] cancel
Choice: 1
Will release as v1.3.1
Proceed? [y/N]: y
Releasing splent_cli v1.3.1
Release gate (channels)
github ready, diverso-lab/splent_cli accepts push, tag and release as drorganvidez
pypi ready, credentials accepted, splent_cli exists so this is a new version
version 1.3.1 written to pyproject.toml
commit changes committed
pypi building package...
pypi uploading...
pypi upload complete
tag v1.3.1 created
tag v1.3.1 pushed to origin
github release created: https://github.com/...
splent_cli v1.3.1 released.
Explicit version (CI / automation).
splent release:cli v1.3.1
Pipeline
- Validates environment credentials.
- Channel gate, pass one. Proves GitHub and PyPI would accept this exact version before anything is spent on tests.
- Pre-release gate.
rufflint +pytest tests/forsplent_cli. Aborts with no changes if either fails. Skip with--skip-checks. - Channel gate, pass two. The binding one, so the verdict acted on is seconds old.
- Bumps the version in
splent_cli/pyproject.toml, stages and commits. - Cleans build artifacts, builds the package, and uploads to PyPI.
- Pushes
main, creates and pushes the Git tag (v<version>), creates the GitHub Release.
PyPI goes first because a PyPI version can never be replaced or removed, while an unpushed tag costs nothing. If step 7 fails after step 6 succeeded, the run says the channels have diverged and prints the release:resume command that finishes the job without bumping the version.
--no-github, --no-pypi and --allow-unfinished are available here too. See Declaring channels.
All pending changes in the
splent_cli/directory are included in the release commit. This is intentional. The release captures the current state of the codebase.
Requirements
| Variable | Description |
|---|---|
GITHUB_TOKEN |
Required. The channel gate refuses to start without it, because a push, a tag and a release cannot be verified. Also what keeps the semver wizard off the anonymous rate limit. |
TWINE_USERNAME / PYPI_USERNAME |
PyPI authentication (usually __token__). |
TWINE_PASSWORD / PYPI_PASSWORD |
PyPI API token. |
Verify credentials before releasing.
splent check:github
splent check:pypi
See also
release:framework. Same pipeline forsplent_frameworkrelease:resume. Finish an interrupted releasefeature:release. Feature release pipeline (includes contract inference and cache snapshot)product:release. Product release pipeline (includes Docker Hub)