Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/dervexdev/file-version-bumper
Bump version in any JSON or TOML file with this simple Action
https://github.com/dervexdev/file-version-bumper
actions github-actions semver versioning
Last synced: about 1 month ago
JSON representation
Bump version in any JSON or TOML file with this simple Action
- Host: GitHub
- URL: https://github.com/dervexdev/file-version-bumper
- Owner: DervexDev
- License: apache-2.0
- Created: 2024-03-17T22:05:12.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-08-07T00:56:54.000Z (5 months ago)
- Last Synced: 2024-08-07T03:23:39.333Z (5 months ago)
- Topics: actions, github-actions, semver, versioning
- Language: TypeScript
- Homepage:
- Size: 1.46 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
README
# File Version Bumper
Bump version in any JSON or TOML file with this simple Action
[![CI](https://github.com/dervexdev/file-version-bumper/actions/workflows/ci.yml/badge.svg)](https://github.com/dervexdev/file-version-bumper/actions/workflows/ci.yml)
[![Super-Linter](https://github.com/dervexdev/file-version-bumper/actions/workflows/linter.yml/badge.svg)](https://github.com/dervexdev/file-version-bumper/actions/workflows/linter.yml)
[![CodeQL](https://github.com/dervexdev/file-version-bumper/actions/workflows/codeql.yml/badge.svg)](https://github.com/dervexdev/file-version-bumper/actions/workflows/codeql.yml)## Example
```yaml
name: Releaseon:
push:
tags: ['*']jobs:
bump:
name: Bump Version
runs-on: ubuntu-lateststeps:
- 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
```## Inputs
| 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 |## Outputs
| 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`