Skip to content

Release v0.3.1 (#94) #8

Release v0.3.1 (#94)

Release v0.3.1 (#94) #8

Workflow file for this run

name: release
on:
push:
branches: [ master ]
paths: [ CHANGELOG.md ]
jobs:
changelog-version:
runs-on: ubuntu-latest
outputs:
version: ${{ steps.latest.outputs.output }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Get the latest version
id: latest
uses: miniscruff/changie-action@6dcc2533cac0495148ed4046c438487e4dceaa23 # v2.0.0
with:
version: latest
args: latest
release-tag:
needs: [changelog-version]
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Push release tag
run: |
git tag "${{ needs.changelog-version.outputs.version }}"
git push origin "${{ needs.changelog-version.outputs.version }}"
release-notes:
needs: [ changelog-version, release-tag ]
runs-on: ubuntu-latest
steps:
# Checkout the tag we just released
- uses: actions/checkout@v4
with:
ref: ${{ needs.changelog-version.outputs.version }}
fetch-depth: 0
- name: Generate Release Notes
# sed command removes the version+date header
run: |
cd .changes
sed -e "1{/# /d;}" -e "2{/^$/d;}" ${{ needs.changelog-version.outputs.version }}.md > release-notes.txt
- uses: actions/upload-artifact@5d5d22a31266ced268874388b861e4b58bb5c2f3 # v4.3.1
with:
name: release-notes
path: ./.changes/release-notes.txt
retention-days: 1
terraform-provider-release:
name: 'Terraform Provider Release'
needs: [release-notes]
uses: hashicorp/ghaction-terraform-provider-release/.github/workflows/community.yml@9b5d2ca4b85f3a54d5c4d12e7690ddad1526ff6c # v3.0.1
secrets:
gpg-private-key: '${{ secrets.GPG_PRIVATE_KEY }}'
gpg-private-key-passphrase: '${{ secrets.GPG_PASSPHRASE }}'
with:
release-notes: true
setup-go-version-file: 'go.mod'