fix: upgrade go-getter to v1.7.5 from v1.7.4 [IAC-3065] #132
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: release_workflow | |
on: | |
pull_request: | |
types: | |
- closed | |
jobs: | |
release_workflow: | |
if: ${{ github.event.pull_request.merged && startsWith(github.event.pull_request.head.ref, 'release/') }} | |
environment: release | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
ref: main | |
submodules: true | |
- uses: actions/setup-go@v3 | |
with: | |
go-version: '1.18' | |
- run: make install_tools | |
- name: Extract version from branch name | |
id: version | |
run: | | |
BRANCH_NAME=${{ github.event.pull_request.head.ref }} | |
VERSION=v${BRANCH_NAME#release/} | |
echo "VERSION=$VERSION" >> $GITHUB_OUTPUT | |
- name: Ensure changelog exists | |
run: ls changes/${{ steps.version.outputs.VERSION }}.md | |
- name: Generate extra files | |
run: make release_extra_files | |
- name: Tag version | |
run: | | |
VERSION=${{ steps.version.outputs.VERSION }} | |
git config user.name "$GITHUB_ACTOR" | |
git config user.email "[email protected]" | |
git tag -a -F changes/$VERSION.md $VERSION | |
git push origin $VERSION | |
- name: Run goreleaser | |
run: | | |
goreleaser release \ | |
--release-notes=changes/${{ steps.version.outputs.VERSION }}.md \ | |
--skip-validate | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |