File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -2,9 +2,11 @@ name: Release
22
33on :
44 push :
5+ # This workflow will run only when you push a tag that starts with 'v'
6+ # For example: v1.2.1, v1.3.0, etc.
57 tags :
68 - ' v*.*.*'
7-
9+
810permissions :
911 contents : write
1012 packages : write
1719 - name : Checkout
1820 uses : actions/checkout@v4
1921 with :
20- fetch-depth : 0
22+ fetch-depth : 0 # Fetch all history so GoReleaser can generate a changelog if needed
2123
2224 - name : Set up Go
2325 uses : actions/setup-go@v5
3638 version : ' ~> v2'
3739 args : release --clean
3840 release_notes : ${{ steps.extract_notes.outputs.notes_path }}
39- token : ${{ secrets.GITHUB_TOKEN }} # <-- Explicitly pass token
41+ token : ${{ secrets.GITHUB_TOKEN }}
42+ env :
43+ # This token is provided by GitHub automatically and is required
44+ # to create a release and upload assets.
45+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments