Skip to content

semantic-release

semantic-release #33

---
name: semantic-release
on:
workflow_run:
workflows: [stack-build]
types: [completed]
branches: [main]
jobs:
build:
name: Semantic release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
persist-credentials: false
- uses: actions/create-github-app-token@v2
id: app-token
with:
app-id: "${{ secrets.SEMANTIC_RELEASE_APP_ID }}"
private-key: "${{ secrets.SEMANTIC_RELEASE_PRIVATE_KEY }}"
- name: Semantic release
id: semantic
uses: cycjimmy/semantic-release-action@v4
env:
GITHUB_TOKEN: "${{ steps.app-token.outputs.token }}"
HACKAGE_KEY: "${{ secrets.HACKAGE_TOKEN }}"
with:
ci: ${{ github.ref == github.event.repository.default_branch }}
extra_plugins: |
conventional-changelog-conventionalcommits
semantic-release-mirror-version
semantic-release-stack-upload
- name: Semantic release output
run: |
echo ref: ${{ github.ref }}
echo dry_run: ${{ github.ref_name != github.event.repository.default_branch }}
echo published: ${{ steps.semantic.outputs.new_release_published }}
echo last_release: ${{ steps.semantic.outputs.last_release_version }}
echo new_version: ${{ steps.semantic.outputs.new_release_version }}
echo git_head: ${{ steps.semantic.outputs.new_release_git_head }}
echo release_notes:
echo "${{ steps.semantic.outputs.new_release_notes }}"
...