fix: Activate auto releasing on main pushes #11
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
permissions: write-all | |
name: 📦 Publish Release | |
jobs: | |
update-changelog: | |
name: 📝 Manage Release Publish | |
runs-on: ubuntu-latest | |
steps: | |
- name: 🚚 Get latest code | |
uses: actions/checkout@v3 | |
- name: 🔖 Get Next Version | |
id: semver | |
uses: ietf-tools/semver-action@v1 | |
with: | |
token: ${{ github.token }} | |
branch: main | |
patchList: fix, bugfix, perf, refactor, test, test, chore | |
- name: 🔖 Set tag to latest commit | |
uses: rickstaa/action-create-tag@v1 | |
with: | |
tag: ${{ steps.semver.outputs.next }} | |
tag_exists_error: false | |
message: '' | |
- name: 📝 Generate Changelog | |
id: changelog | |
uses: requarks/changelog-action@v1 | |
with: | |
excludeTypes: '' | |
includeInvalidCommits: true | |
token: ${{ github.token }} | |
tag: ${{ steps.semver.outputs.next }} | |
writeToFile: false | |
- name: 📦 Create Release | |
uses: ncipollo/release-action@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag: ${{ steps.semver.outputs.next }} | |
name: ${{ steps.semver.outputs.next }} | |
body: ${{ steps.changelog.outputs.changes }} |