Skip to content

Commit d49c7e4

Browse files
committed
chore: setup npm trusted publisher
1 parent b9770d8 commit d49c7e4

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

.github/workflows/uuv-github-ci.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
uses: actions/setup-node@v4
4646
with:
4747
node-version: ${{env.NODE_VERSION}}
48-
- run: npm ci && ls -R packages/assistant/node_modules/@typescript-eslint/eslint-plugin/dist/configs
48+
- run: npm ci
4949

5050
build:
5151
runs-on: ubuntu-22.04
@@ -540,20 +540,24 @@ jobs:
540540
if: github.ref == 'refs/heads/main'
541541
runs-on: ubuntu-22.04
542542
needs: [ release ]
543+
permissions:
544+
id-token: write
545+
contents: read
546+
environment: publish-npm
543547
steps:
544548
- uses: actions/checkout@v4
545549
- name: Download Release artifact
546550
uses: actions/download-artifact@v4
547551
with:
548552
name: release-artifacts
549-
- name: Use Node.js ${{env.NODE_VERSION}}
553+
- name: Use Node.js 23
550554
uses: actions/setup-node@v4
551555
with:
552-
node-version: ${{env.NODE_VERSION}}
556+
node-version: 23
553557
registry-url: 'https://registry.npmjs.org'
558+
- name: Install npm 11
559+
run: npm install -g npm@11 && npm --version
554560
- name: Publishing NPM packages
555-
env:
556-
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
557561
run: |
558562
for packagePath in $(find dist/packages -name "*.tgz"); do
559563
npm publish $packagePath --scope ${{env.NPM_PACKAGE_SCOPE}} --access public

0 commit comments

Comments
 (0)