1616env :
1717 package : ${{ startsWith(github.ref_name, 'dart-') && 'dart' || startsWith(github.ref_name, 'flutter-') && 'flutter' || '' }}
1818jobs :
19- # Semantic Release job - runs on branch pushes to create tags and update changelogs
2019 semantic-release :
2120 if : github.event_name == 'push' && github.ref_type == 'branch'
2221 runs-on : ubuntu-latest
2322 timeout-minutes : 10
2423 permissions :
25- contents : write # Required for creating tags and commits
26- issues : write # Required for commenting on issues
27- pull-requests : write # Required for commenting on PRs
24+ contents : write
25+ issues : write
26+ pull-requests : write
2827 steps :
2928 - name : Checkout code
30- uses : actions/checkout@v3
29+ uses : actions/checkout@v4
3130 with :
32- fetch-depth : 0 # Required for semantic-release
33- persist-credentials : true
31+ fetch-depth : 0
32+ persist-credentials : false
3433 - name : Setup Node.js
3534 uses : actions/setup-node@v4
3635 with :
@@ -39,26 +38,26 @@ jobs:
3938 - name : Install dependencies
4039 run : npm ci
4140 - name : Run semantic-release for dart package
41+ run : npx semantic-release
4242 env :
43+ GH_TOKEN : ${{ secrets.RELEASE_GITHUB_TOKEN }}
4344 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4445 PKG_NAME : dart
45- run : npx semantic-release
4646 - name : Run semantic-release for flutter package
47+ run : npx semantic-release
4748 env :
49+ GH_TOKEN : ${{ secrets.RELEASE_GITHUB_TOKEN }}
4850 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
4951 PKG_NAME : flutter
50- run : npx semantic-release
51-
52- # Publishing job - runs when a tag is pushed (created by semantic-release)
5352 release :
5453 if : github.event_name == 'push' && github.ref_type == 'tag'
5554 runs-on : ubuntu-latest
5655 timeout-minutes : 10
5756 permissions :
58- id-token : write # This is required for requesting the JWT
57+ id-token : write
5958 steps :
6059 - name : Checkout code
61- uses : actions/checkout@v3
60+ uses : actions/checkout@v4
6261 with :
6362 ref : ${{ github.ref_name }}
6463 - name : Setup dart
0 commit comments