File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4848 runs-on : ubuntu-latest
4949 permissions :
5050 contents : write
51+ outputs :
52+ next-tag : ${{ steps.bump-release.outputs.next-tag }}
5153 steps :
5254 -
5355 name : Checkout code
@@ -126,6 +128,7 @@ jobs:
126128 contents : write
127129 steps :
128130 -
129- uses : ./release.yml@master
131+ uses : ./.github/workflows/ release.yml
130132 with :
133+ tag : ${{ needs.tag-release.outputs.next-tag}}
131134 secrets : inherit
Original file line number Diff line number Diff line change 1212 push :
1313 tags :
1414 - v[0-9]+*
15+ workflow_call :
16+ inputs :
17+ tag :
18+ type : string
19+ required : true
1520
1621jobs :
1722 gh-release :
3035 id : get-message
3136 # tag message is not retrieved unless with fetch the ref explictly
3237 run : |
38+ set -x
39+ REF='${{ github_ref_name }}'
40+ INPUT_TAG='${{ inputs.tag }}'
41+ if [[ -n "${INPUT_TAG}" ]] ; then
42+ # release workflow triggered from another workflow, not a push event
43+ REF="${INPUT_TAG}"
44+ fi
45+
3346 git fetch --depth=1 origin +refs/tags/*:refs/tags/*
34- MESSAGE=$(git tag -l '${{ github.ref_name }}' --format='%(contents:subject)
47+ MESSAGE=$(git tag -l "${REF}" --format='%(contents:subject)
3548
3649 %(contents:body)
3750 ')
4255 echo 'EOF'
4356 } >> "${GITHUB_OUTPUT}"
4457
45- echo "Message in git tag ${{ github.ref_name } }"
58+ echo "Message in git tag ${REF }"
4659 echo "$MESSAGE"
4760 -
4861 name : Generate release notes
You can’t perform that action at this time.
0 commit comments