@@ -4,9 +4,6 @@ run-name: Release new version
44on :
55 workflow_dispatch :
66
7- env :
8- DOTNET_VERSION : " 8.0.410"
9-
107jobs :
118 release :
129 runs-on : ubuntu-latest
2825 ref : docs-changelog
2926 path : docs/_changelog
3027
31- - name : Setup .NET Core
32- uses : actions/setup-dotnet@v5
33- with :
34- dotnet-version : ${{ env.DOTNET_VERSION }}
35-
3628 - name : Read current version
3729 id : version
3830 run : echo "VERSION=$(grep -v '^$' build/versions.txt | tail -n 1)" >> $GITHUB_OUTPUT
6860 run : ./build.cmd version-increment
6961
7062 - name : Commit changes
71- uses : EndBug/add-and-commit@290ea2c423ad77ca9c62ae0f5b224379612c0321 # v10.0.0
63+ uses : EndBug/add-and-commit@cc9c08ba6c8df3b93a8f2db63e89b98368ae2ae8 # v11.1.1
7264 with :
7365 message : " Set next BenchmarkDotNet version: ${{ steps.version.outputs.VERSION }} and update released analyzer rules"
7466 author_name : GitHub Actions
@@ -90,20 +82,22 @@ jobs:
9082 tags : true
9183
9284 - name : Release
93- uses : softprops/action-gh-release@b4309332981a82ec1c5618f44dd2e27cc8bfbfda # v3.0.0
85+ uses : softprops/action-gh-release@efb35369e0ad2afab669f228072c1b0d510eae64 # v3.0.3
9486 with :
95- name : BenchmarkDotNet v${{ steps.version.outputs.VERSION }}
87+ name : v${{ steps.version.outputs.VERSION }}
9688 tag_name : v${{ steps.version.outputs.VERSION }}
9789 body : |
9890 Full changelog: https://benchmarkdotnet.org/changelog/v${{ steps.version.outputs.VERSION }}.html
9991 discussion_category_name : Announcements
10092
10193 - name : Close old milestone
102- uses : Akkjon/close-milestone@2dd67f0346a3cb6159a33c7467ae5fbd17e5affc # v2.2.0
94+ run : |
95+ number=$(gh api "repos/${{ github.repository }}/milestones?state=open&per_page=100" --jq '.[] | select(.title == "v${{ steps.version.outputs.VERSION }}") | .number')
96+ if [ -n "$number" ]; then
97+ gh api -X PATCH "repos/${{ github.repository }}/milestones/$number" -f state=closed
98+ fi
10399 env :
104- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
105- with :
106- milestone_name : v${{ steps.version.outputs.VERSION }}
100+ GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
107101
108102 - name : Create new milestone
109103 uses : WyriHaximus/github-action-create-milestone@bcd9e15439836d6098d353a5bcf82de46591a35d # v1.1.2
@@ -113,7 +107,7 @@ jobs:
113107 title : v${{ steps.next_version.outputs.NEXT_VERSION }}
114108
115109 - name : Publish to NuGet
116- run : dotnet nuget push ./artifacts/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate
110+ run : ./.dotnet/ dotnet nuget push ./artifacts/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate
117111
118112 # --- Documentation ---
119113
@@ -128,7 +122,7 @@ jobs:
128122 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
129123
130124 - name : Push changelog
131- uses : JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8 .0
125+ uses : JamesIves/github-pages-deploy-action@fa24774553152dd7873cd16ebd8d959b010c5445 # v4.9 .0
132126 with :
133127 branch : docs-changelog
134128 folder : docs/_changelog
@@ -140,7 +134,7 @@ jobs:
140134 run : ./build.cmd docs-build
141135
142136 - name : Deploy documentation
143- uses : JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8 .0
137+ uses : JamesIves/github-pages-deploy-action@fa24774553152dd7873cd16ebd8d959b010c5445 # v4.9 .0
144138 with :
145139 branch : gh-pages
146140 folder : docs/_site
0 commit comments