https://github.com/zcubbs/gh-release-action
https://github.com/zcubbs/gh-release-action
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/zcubbs/gh-release-action
- Owner: zcubbs
- License: mit
- Created: 2023-11-26T11:13:06.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-26T13:47:49.000Z (over 2 years ago)
- Last Synced: 2025-07-20T08:56:54.583Z (12 months ago)
- Language: TypeScript
- Size: 387 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Github Release Action
This GitHub Action automates the process of calculating a new semantic version tag based on the latest tag found in the repository. It increments the patch version while keeping the major and minor versions as specified.
## Inputs
### `major`
**Required** The major version number. This should be incremented when there are incompatible API changes.
### `minor`
**Required** The minor version number. This should be incremented when functionality is added in a backward-compatible manner.
### `github-token`
**Required** A GitHub token to authenticate API requests. Typically, this will be the GitHub Actions provided `${{ secrets.GITHUB_TOKEN }}`.
## Outputs
### `new-version`
The new version tag created by the action.
## Example Usage
```yaml
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Calculate Version and Create Release
id: versioning
uses: zcubbs/gh-release-action@v1
with:
major: '1'
minor: '0'
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Use the new version
run: echo "The new version is ${{ steps.versioning.outputs.new-version }}"
```
## Development
```bash
npm run build
```
## License
This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details