@@ -12,12 +12,16 @@ jobs:
1212 node-version : [22.x]
1313 steps :
1414 - name : Checkout
15- uses : actions/checkout@v2
15+ uses : actions/checkout@v4
1616 - name : Use Node.js ${{ matrix.node-version }}
17- uses : actions/setup-node@v1
17+ uses : actions/setup-node@v4
1818 with :
1919 node-version : ${{ matrix.node-version }}
2020 registry-url : " https://registry.npmjs.org"
21+ - name : Upgrade npm for trusted publishing compatibility
22+ run : |
23+ npm i -g npm@^11.5.1
24+ npm --version
2125 - run : yarn install
2226 - run : DEBUG=eslint:cli-engine npm run lint:all
2327 - run : npm run build
@@ -28,25 +32,28 @@ jobs:
2832 runs-on : ubuntu-latest # Firefox in it
2933 strategy :
3034 matrix :
31- node-version : [22.x ]
35+ node-version : [22.14.0 ]
3236 permissions :
3337 contents : write # for release
38+ id-token : write # for npm trusted publishing (OIDC)
3439 steps :
3540 - name : Checkout
36- uses : actions/checkout@v2
41+ uses : actions/checkout@v4
3742 - name : Use Node.js ${{ matrix.node-version }}
38- uses : actions/setup-node@v1
43+ uses : actions/setup-node@v4
3944 with :
4045 node-version : ${{ matrix.node-version }}
4146 registry-url : " https://registry.npmjs.org"
47+ - name : Upgrade npm for trusted publishing compatibility
48+ run : |
49+ npm i -g npm@^11.5.1
50+ npm --version
4251 - run : yarn install
4352 - run : npm run build
4453 - run : git status && git stash
4554 - run : echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
4655 - run : npm run publish:release -- $TAG --yes
4756 if : ${{ env.TAG != '' && !contains(env.TAG, '/') && github.repository == 'ringcentral/ringcentral-js' }}
48- env :
49- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
5057 - name : Release
5158 if : ${{ env.TAG != '' && !contains(env.TAG, '/') && github.repository == 'ringcentral/ringcentral-js' }}
5259 uses : softprops/action-gh-release@v1
0 commit comments