Automatic Changelog Generator for tag #58
Workflow file for this run
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
name: Automatic Changelog Generator for tag | |
on: | |
push: | |
tags: | |
- 'v*' | |
- '!v*-alpha*' | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: Set Environment | |
run: | | |
echo "BUILD_TAG=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV | |
- name: Get previous release tag based on type | |
id: prevrelease | |
uses: ibexa/version-logic-action@master | |
with: | |
currentTag: ${{ env.BUILD_TAG }} | |
- name: Generate changelog | |
id: changelog | |
uses: ibexa/changelog-generator-action@v2 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
jira_token: ${{ secrets.JIRA_TOKEN }} | |
currentTag: ${{ env.BUILD_TAG }} | |
previousTag: ${{ steps.prevrelease.outputs.previousTag }} | |
- name: Print the changelog | |
run: echo "${{ steps.changelog.outputs.changelog }}" | |
- name: Create Release | |
id: create_release | |
uses: zendesk/action-create-release@v1 | |
with: | |
tag_name: ${{ env.BUILD_TAG }} | |
body: | | |
${{ steps.changelog.outputs.changelog }} | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |