A CLI tool to detect version labels in temp.md
Project description
Bump versions automagically
Bump versions based on changelog entries.
Setup
This package only works together with scriv and works best if used with hatch.
In the scriv configuration the following is assumed:
[tool.scriv]
format = "md"
categories = [
"Major: Feature",
"Minor: Feature",
"Minor: Fix",
"Patch: Fix",
"Major: Business impact",
"Minor: Business impact"
]
You can adjust the categories as you like the BUMB: part is what is checked for, and the bumps must be Major, Minor, Patch
For a nice integration in hatch use these two additional env definition blocks:
[tool.hatch.envs.changelog]
dependencies = [
"scriv",
"changelog-version"
]
[tool.hatch.envs.changelog.scripts]
init = "mkdir changelog.d"
new = "scriv create --edit --add"
collate = "scriv print > temp.md && hatch version $(changelog-version-bump) && scriv collect"
-
Initial setup needed once is the
initpart (feel free to not bother with a seperate command). -
In each branch you'll need to run
scriv createorhatch run changelog:newto create and edit the changelog fragment for scriv. -
The actual magic is the
collatecomand that should run inci/cdwhen you create tags / releases.
Pre-commit hook
This was originally created by TypicalArray.
Some places (like Azure DevOps) do not render .md files automatically. So in order to clean them up, this repo also contains a pre-commit hook which automatically removes all commented out lines, removes superfluous empty lines and enforces that all lines have to start with a # or a -, which helps with formatting. It can be used as follows:
repos:
- repo: https://github.com/banking-circle-advanced-analytics/changelog-version-bump
rev: <insert-latest-release>
hooks:
- id: remove-comments
FAQ
Can you change the options and headings? No. It would be easy to add configurability via the toml and a tool.changelog-version-bump section but for now I see no need, the defaults should suffice.
Could this not just be some bash? Yes. This code was actually bash, but for distribution and later configuration, see above, python scripts are easier.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file changelog_version_bump-0.4.4.tar.gz.
File metadata
- Download URL: changelog_version_bump-0.4.4.tar.gz
- Upload date:
- Size: 15.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c9ca032615dfc2b404f4e7af4a269bc8dcd21b423398ba95d2b06de85d62e157
|
|
| MD5 |
7c3f561b9e61eac6806758237e249bec
|
|
| BLAKE2b-256 |
ebb860c0b345118ac5fe1b686d01049bb1b98ebf54987f49948bbf3f7bd93933
|
Provenance
The following attestation bundles were made for changelog_version_bump-0.4.4.tar.gz:
Publisher:
python-publish.yml on banking-circle-advanced-analytics/changelog-version-bump
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
changelog_version_bump-0.4.4.tar.gz -
Subject digest:
c9ca032615dfc2b404f4e7af4a269bc8dcd21b423398ba95d2b06de85d62e157 - Sigstore transparency entry: 670519272
- Sigstore integration time:
-
Permalink:
banking-circle-advanced-analytics/changelog-version-bump@436340ecd518b34c9e823e010b0a2772a9d045a0 -
Branch / Tag:
refs/tags/0.4.4 - Owner: https://github.com/banking-circle-advanced-analytics
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@436340ecd518b34c9e823e010b0a2772a9d045a0 -
Trigger Event:
release
-
Statement type:
File details
Details for the file changelog_version_bump-0.4.4-py3-none-any.whl.
File metadata
- Download URL: changelog_version_bump-0.4.4-py3-none-any.whl
- Upload date:
- Size: 17.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
65a0cec728c142f00eb85402c22d72c4adf6a87714b831ff2edc7920bfd11ba3
|
|
| MD5 |
8631ceab1fe6a80b99fd0a6778d957f9
|
|
| BLAKE2b-256 |
a70162013ce23bf37b6476e7f32f7226197bfbee9ce975a306049758137273d2
|
Provenance
The following attestation bundles were made for changelog_version_bump-0.4.4-py3-none-any.whl:
Publisher:
python-publish.yml on banking-circle-advanced-analytics/changelog-version-bump
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
changelog_version_bump-0.4.4-py3-none-any.whl -
Subject digest:
65a0cec728c142f00eb85402c22d72c4adf6a87714b831ff2edc7920bfd11ba3 - Sigstore transparency entry: 670519309
- Sigstore integration time:
-
Permalink:
banking-circle-advanced-analytics/changelog-version-bump@436340ecd518b34c9e823e010b0a2772a9d045a0 -
Branch / Tag:
refs/tags/0.4.4 - Owner: https://github.com/banking-circle-advanced-analytics
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
python-publish.yml@436340ecd518b34c9e823e010b0a2772a9d045a0 -
Trigger Event:
release
-
Statement type: