1515 required : true
1616
1717env :
18- MILESTONE : ${{ inputs.milestone }}
19- GITHUB_TOKEN : ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
2018 GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
2119 SPRING_MAIN_BANNERMODE : off
2220
@@ -88,26 +86,39 @@ jobs:
8886 - name : Generate Changelog
89879088 with :
91- milestone : ${{ env.MILESTONE }}
92- token : ${{ env.GITHUB_TOKEN }}
89+ milestone : ${{ inputs.milestone }}
90+ token : ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
9391 config-file : changelog.properties
9492
9593 - name : GitHub Release
9694 run : |
97- RELEASE_URL=$(gh release create v${{ env.MILESTONE }} -F changelog.md ${{ (contains(env.MILESTONE , '-M') || contains(env.MILESTONE , '-RC')) && '--prerelease' || '' }})
95+ RELEASE_URL=$(gh release create v${{ inputs.milestone }} -F changelog.md ${{ (contains(inputs.milestone , '-M') || contains(inputs.milestone , '-RC')) && '--prerelease' || '' }})
9896 echo "::notice title=Release Page::$RELEASE_URL"
9997
10098 - name : Close Milestone
10199 run : |
102- MILESTONE_ID=$(gh api repos/$GITHUB_REPOSITORY/milestones --jq '.[] | select(.title == env.MILESTONE ) | .number')
100+ MILESTONE_ID=$(gh api repos/$GITHUB_REPOSITORY/milestones --jq '.[] | select(.title == "${{ inputs.milestone }}" ) | .number')
103101 if [ $MILESTONE_ID ]; then
104102 gh api -X PATCH repos/$GITHUB_REPOSITORY/milestones/$MILESTONE_ID -f state='closed' --silent
105103 fi
106104
105+ - name : Checkout Common Repo
106+ uses : actions/checkout@v4
107+ with :
108+ repository : spring-io/spring-github-workflows
109+ path : spring-github-workflows
110+ show-progress : false
111+
112+ - name : Update Spring IO website for new version
113+ uses : ./spring-github-workflows/.github/actions/spring-website-project-version-update
114+ with :
115+ newVersion : ${{ inputs.milestone }}
116+ token : ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
117+
107118 - name : Announce Release in Chat
108119 if : env.CHAT_WEBHOOK_URL
109120 run : |
110- curl -X POST '${{ env.CHAT_WEBHOOK_URL }}' -H 'Content-Type: application/json' -d '{ text: "${{ github.event.repository.name }}-announcing `${{ env.MILESTONE }}`"}'
121+ curl -X POST '${{ env.CHAT_WEBHOOK_URL }}' -H 'Content-Type: application/json' -d '{ text: "${{ github.event.repository.name }}-announcing `${{ inputs.milestone }}`"}'
111122 env :
112123 CHAT_WEBHOOK_URL : ${{ secrets.SPRING_RELEASE_CHAT_WEBHOOK_URL }}
113124
@@ -120,5 +131,5 @@ jobs:
120131# with:
121132# payload: |
122133# {
123- # "text": "${{ github.event.repository.name }}-announcing `${{ env.MILESTONE }}`"
134+ # "text": "${{ github.event.repository.name }}-announcing `${{ inputs.milestone }}`"
124135# }
0 commit comments