fix: Create Group protocol not editable anymore [WPB-7109] (#2790) #73
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: 'Generate Changelog' | |
on: | |
workflow_dispatch: | |
inputs: | |
current-release-tag: | |
type: string | |
description: 'The tag of the current release starting with v' | |
required: false | |
default: '' | |
push: | |
tags: | |
- 'v*' | |
jobs: | |
Changelog: | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Checkout Git repository with history for all branches and tags' | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
submodules: recursive # Needed in order to fetch Kalium sources for building | |
- name: 'Set current Git tag from input' | |
env: | |
INPUT_RELEASE_TAG: ${{github.event.inputs.current-release-tag}} | |
if: "${{ github.event.inputs.current-release-tag != '' }}" | |
run: echo "CURRENT_TAG=$INPUT_RELEASE_TAG" >> "$GITHUB_ENV" | |
- name: 'Set current Git tag from commit' | |
if: "${{ github.event.inputs.current-release-tag == '' }}" | |
run: echo "CURRENT_TAG=$(git tag --points-at ${{github.sha}} | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+(\+|$)' | tail -n 1)" >> "$GITHUB_ENV" | |
- name: 'Set previous Git tag from commit' | |
run: echo "PREVIOUS_TAG=$(git tag | grep -E '^v[0-9]+\.[0-9]+\.[0-9]+(\+|$)' | tail -n 2 | head -n 1)" >> "$GITHUB_ENV" | |
- name: 'Print environment variables' | |
run: | | |
echo -e "PREVIOUS_TAG = $PREVIOUS_TAG" | |
echo -e "CURRENT_TAG = $CURRENT_TAG" | |
echo -e "Node.js version = $(node --version)" | |
- name: 'Generate changelog' | |
run: | | |
echo "{}" > ./package.json | |
npx [email protected] -t "$PREVIOUS_TAG...$CURRENT_TAG" | |
- name: 'Attach changelog to tag' | |
uses: softprops/action-gh-release@v1 | |
env: | |
GITHUB_TOKEN: ${{github.token}} | |
with: | |
tag_name: ${{env.CURRENT_TAG}} | |
name: ${{env.CURRENT_TAG}} | |
body_path: ./CHANGELOG.md | |
draft: false | |
prerelease: false |