Skip to content

Commit 852fd46

Browse files
committed
publish fix
1 parent e18fcf9 commit 852fd46

File tree

3 files changed

+69
-31
lines changed

3 files changed

+69
-31
lines changed

.github/workflows/publish-evm.yml

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,39 @@ on:
44
release:
55
types: [created]
66

7+
permissions:
8+
id-token: write
9+
contents: read
10+
711
jobs:
812
publish:
913
runs-on: ubuntu-latest
1014
steps:
11-
- uses: actions/checkout@v2
12-
# Setup .npmrc file to publish to npm
13-
- uses: actions/setup-node@v2
15+
- uses: actions/checkout@v3
16+
17+
- uses: actions/setup-node@v4
1418
with:
15-
node-version: '18.x'
19+
node-version: '24'
1620
registry-url: 'https://registry.npmjs.org'
1721

1822
- run: mv package.evm.json package.json
1923

20-
- run: yarn install
21-
2224
- name: get-npm-version
2325
id: package-version
2426
uses: martinbeentjes/npm-get-version-action@master
27+
28+
- name: Remove token auth (force OIDC)
29+
run: |
30+
rm -f .npmrc ~/.npmrc || true
31+
npm config delete "//registry.npmjs.org/:_authToken" || true
2532
26-
- run: npm publish --access public
27-
env:
28-
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION_TOKEN }}
33+
- run: npm publish --ignore-scripts --access public
34+
35+
- name: Upload npm logs
36+
if: always()
37+
uses: actions/upload-artifact@v4
38+
with:
39+
name: npm-logs
40+
path: /home/runner/.npm/_logs/
41+
if-no-files-found: warn
42+
retention-days: 14

.github/workflows/publish-svm.yml

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,39 @@ on:
44
release:
55
types: [created]
66

7+
permissions:
8+
id-token: write
9+
contents: read
10+
711
jobs:
812
publish:
913
runs-on: ubuntu-latest
1014
steps:
11-
- uses: actions/checkout@v2
12-
# Setup .npmrc file to publish to npm
13-
- uses: actions/setup-node@v2
15+
- uses: actions/checkout@v3
16+
17+
- uses: actions/setup-node@v4
1418
with:
15-
node-version: '18.x'
19+
node-version: '24'
1620
registry-url: 'https://registry.npmjs.org'
1721

1822
- run: mv package.svm.json package.json
1923

20-
- run: yarn install
21-
2224
- name: get-npm-version
2325
id: package-version
2426
uses: martinbeentjes/npm-get-version-action@master
27+
28+
- name: Remove token auth (force OIDC)
29+
run: |
30+
rm -f .npmrc ~/.npmrc || true
31+
npm config delete "//registry.npmjs.org/:_authToken" || true
2532
26-
- run: npm publish --access public
27-
env:
28-
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION_TOKEN }}
33+
- run: npm publish --ignore-scripts --access public
34+
35+
- name: Upload npm logs
36+
if: always()
37+
uses: actions/upload-artifact@v4
38+
with:
39+
name: npm-logs
40+
path: /home/runner/.npm/_logs/
41+
if-no-files-found: warn
42+
retention-days: 14

.github/workflows/publish.yml

Lines changed: 23 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,23 +4,33 @@ on:
44
release:
55
types: [created]
66

7+
permissions:
8+
id-token: write
9+
contents: read
10+
711
jobs:
812
publish:
913
runs-on: ubuntu-latest
1014
steps:
11-
- uses: actions/checkout@v2
12-
# Setup .npmrc file to publish to npm
13-
- uses: actions/setup-node@v2
15+
- uses: actions/checkout@v3
16+
17+
- uses: actions/setup-node@v4
1418
with:
15-
node-version: '18.x'
19+
node-version: '24'
1620
registry-url: 'https://registry.npmjs.org'
17-
18-
- run: yarn install
1921

20-
- name: get-npm-version
21-
id: package-version
22-
uses: martinbeentjes/npm-get-version-action@master
23-
24-
- run: npm publish --access public
25-
env:
26-
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTOMATION_TOKEN }}
22+
- name: Remove token auth (force OIDC)
23+
run: |
24+
rm -f .npmrc ~/.npmrc || true
25+
npm config delete "//registry.npmjs.org/:_authToken" || true
26+
27+
- run: npm publish --ignore-scripts --access public
28+
29+
- name: Upload npm logs
30+
if: always()
31+
uses: actions/upload-artifact@v4
32+
with:
33+
name: npm-logs
34+
path: /home/runner/.npm/_logs/
35+
if-no-files-found: warn
36+
retention-days: 14

0 commit comments

Comments
 (0)