A GitHub Action for a new version creation in the changelog file using an Unreleased section.
- Parse input to match Semantic Versioning
- Keep a Changelog Compliant
- Supports GitHub Enterprise
- Supports standard
v
prefix out of the box - Automatically retries API operations
-
Add changes to the Unreleased section in
CHANGELOG.md
file in your feature branch. For example:## [Unreleased] ### Added - Glob pattern support - Unit Tests - Log version ### Fixed - Exception on margins larger than context of changelog - Nil pointer exception in 'release' package ### Changed - Refactor JavaScript wrapper
-
Review the changes and merge Pull Request
-
Manually start a GitHub Actions Workflow providing a desired Semantic Version (including
v
prefix) -
Changelog-Release will update the Changelog file, create Tags and push the changes 😉
- [optionally] Trigger another workflow using the newly arrived Version Tag
- [optionally] Update other files within current workflow before
changelog-version
to commit changed files as well (useful when you need to update a version in one of the project files likepackage.json
)
-
Change the workflow to be triggered manually with the required inputs:
on: workflow_dispatch: inputs: version: type: string description: "Semantic Version (X.X.X)" required: true
-
Add Release step to your workflow:
- name: Update Changelog uses: docker://antonyurchenko/changelog-version:v1 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} VERSION: ${{ github.event.inputs.version }} UPDATE_TAGS: "true"
-
Configure Release step:
Environmental Variable Allowed Values Default Value Description CHANGELOG_FILE
*
CHANGELOG.md
Changelog filename UPDATE_TAGS
true
/false
false
Update major and minor tags ( vX
,vX.X
)
- This action has multiple tags:
latest / v1 / v1.2 / v1.2.3
. You may lock to a certain version instead of using latest.
(Recommended to lock against a major version, for examplev4
) - Docker image is published both to Docker Hub and GitHub Packages. If you don't want to rely on Docker Hub but still want to use the dockerized action, you may switch from
uses: docker://antonyurchenko/changelog-version:latest
touses: docker://ghcr.io/anton-yurchenko/changelog-version:latest
changelog-version
may crash when executed against a not supported changelog file format. Make sure your changelog file is compliant to one of the supported formats.
MIT © 2023-present Anton Yurchenko