diff --git a/.github/release-drafter-config.yml b/.github/release-drafter-config.yml index ed9bb18..962c140 100644 --- a/.github/release-drafter-config.yml +++ b/.github/release-drafter-config.yml @@ -3,6 +3,7 @@ no-changes-template: '- No changes' template: | ## What’s Changed $CHANGES - + ## Contributors + $CONTRIBUTORS diff --git a/.github/workflows/release-drafter.yml b/.github/workflows/release-drafter.yml index 3618de9..fe7abd6 100644 --- a/.github/workflows/release-drafter.yml +++ b/.github/workflows/release-drafter.yml @@ -2,27 +2,25 @@ name: Publish release on: push: - branches: - - master + tags: + - '*' + +permissions: + contents: read jobs: update_release_draft: name: Publish release with notes + permissions: + contents: write runs-on: ubuntu-latest - if: "contains(github.event.head_commit.message, 'Prebid Cache prepare release ')" steps: - - name: Extract tag from commit message - run: | - target_tag=${COMMIT_MSG#"Prebid Cache prepare release "} - echo "TARGET_TAG=$target_tag" >> $GITHUB_ENV - env: - COMMIT_MSG: ${{ github.event.head_commit.message }} - name: Create and publish release - uses: release-drafter/release-drafter@v5 + uses: release-drafter/release-drafter@v7 with: config-name: release-drafter-config.yml publish: true - name: "v${{ env.TARGET_TAG }}" - tag: ${{ env.TARGET_TAG }} + name: 'v${{ github.ref_name }}' + tag: ${{ github.ref_name }} env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}