Bump version in any JSON or TOML file with this simple Action
name: Release
on:
push:
tags: ['*']
jobs:
bump:
name: Bump Version
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Bump Cargo version
uses: DervexDev/file-version-bumper@v1
with:
path: ./Cargo.toml
- name: Update Cargo lock
run: cargo update --workspace
Name | Required | Description |
---|---|---|
path | true |
Path to the JSON or TOML file you want to bump |
version | false |
The version to bump to, defaults to the tag name |
format | false |
The format of the file you want to bump, defaults to the file extension |
Name | Description |
---|---|
new_version | New version of the file |
old_version | Previous version of the file |
Important
Lock files won't update automatically!
You will need to add extra step that runs special command e.g.
cargo update --workspace
or npm i --package-lock-only