From fe09d44d8f38f75ecfb2b1dae783b6cc10b12016 Mon Sep 17 00:00:00 2001 From: Frederik Prijck Date: Wed, 13 Dec 2023 11:45:25 +0100 Subject: [PATCH] Use outputs for capturing release-notes (#341) --- .github/actions/get-release-notes/action.yml | 6 +++++- .github/workflows/release.yml | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/actions/get-release-notes/action.yml b/.github/actions/get-release-notes/action.yml index c89b51a..45de354 100644 --- a/.github/actions/get-release-notes/action.yml +++ b/.github/actions/get-release-notes/action.yml @@ -15,6 +15,10 @@ inputs: token: required: true +outputs: + release-notes: + value: ${{ steps.get_release_notes.outputs.RELEASE_NOTES }} + runs: using: composite @@ -30,7 +34,7 @@ runs: state: 'all', head: `${process.env.REPO_OWNER}:release/${process.env.VERSION}`, }); - core.exportVariable('RELEASE_NOTES', pulls[0].body) + core.setOutput('RELEASE_NOTES', pulls[0].body); env: GITHUB_TOKEN: ${{ inputs.token }} REPO_OWNER: ${{ inputs.repo_owner }} diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9b3db00..db2fec9 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -71,7 +71,7 @@ jobs: with: token: ${{ secrets.GITHUB_TOKEN }} name: ${{ steps.get_version.outputs.version }} - body: ${{ env.RELEASE_NOTES }} + body: ${{ steps.get_release_notes.outputs.release-notes }} tag: ${{ steps.get_version.outputs.version }} commit: ${{ github.sha }} prerelease: ${{ steps.get_prerelease.outputs.prerelease }}