@@ -182,7 +182,7 @@ jobs:
182
182
RELEASE_COMMENT_ID : ${{ needs.release.outputs.comment-id }}
183
183
GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
184
184
run : |
185
- npm exec --offline -- template-oss-release-manager --lockfile=false --publish=false
185
+ npm exec --offline -- template-oss-release-manager --lockfile=false --publish=true
186
186
npm run rp-pull-request --ignore-scripts --if-present
187
187
- name : Commit
188
188
id : commit
@@ -331,40 +331,26 @@ jobs:
331
331
defaults :
332
332
run :
333
333
shell : bash
334
+ permissions :
335
+ deployments : write
336
+ id-token : write
334
337
steps :
338
+ - name : Checkout
339
+ uses : actions/checkout@v3
340
+ with :
341
+ ref : ${{ fromJSON(needs.release.outputs.release).tagName }}
335
342
- name : Setup Node
336
343
uses : actions/setup-node@v3
337
- id : node
338
344
with :
339
- node-version : 20.x
340
- check-latest : contains('20.x', '.x')
341
-
342
- - name : View in Registry
345
+ node-version : 18.x
346
+ - name : Install npm@latest
343
347
run : |
344
- EXIT_CODE=0
345
-
346
- function is_published {
347
- if npm view "$@" --loglevel=error > /dev/null; then
348
- echo 0
349
- else
350
- echo 1
351
- fi
352
- }
353
-
354
- for release in $(echo '${{ needs.release.outputs.releases }}' | jq -r '.[] | @base64'); do
355
- name=$(echo "$release" | base64 --decode | jq -r .pkgName)
356
- version=$(echo "$release" | base64 --decode | jq -r .version)
357
- spec="$name@$version"
358
- status=$(is_published "$spec")
359
- if [[ "$status" -eq 1 ]]; then
360
- echo "$spec ERROR"
361
- EXIT_CODE=$status
362
- else
363
- echo "$spec OK"
364
- fi
365
- done
366
-
367
- exit $EXIT_CODE
348
+ npm i --prefer-online --no-fund --no-audit -g npm@latest
349
+ npm config set '//registry.npmjs.org/:_authToken'=\${PUBLISH_TOKEN}
350
+ - name : Publish
351
+ env :
352
+ PUBLISH_TOKEN : ${{ secrets.PUBLISH_TOKEN }}
353
+ run : npm publish --provenance --tag=next-6
368
354
369
355
post-release-integration :
370
356
needs : [ release, release-integration ]
0 commit comments