Skip to content

Commit 93df85c

Browse files
ci: Use trusted publishing (#33)
* ci: Enable trusted publishing * chore: Update semantic-release for OIDC use.
1 parent 385c056 commit 93df85c

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

.github/actions/setup-tools/action.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,11 @@ runs:
77
- name: Install Node.js
88
uses: actions/setup-node@v4
99
with:
10-
node-version: 23
10+
node-version: 24 # semantic-release requires at least this version, or 22 LTS
11+
# Ensure npm 11.5.1 or later is installed for Trusted publishing
12+
- name: Update npm
13+
shell: bash
14+
run: npm install -g npm@latest
1115
- name: Install dependencies
1216
shell: bash
1317
run: npm i

.github/workflows/release_plugin.yml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ permissions:
1111
contents: write
1212
issues: write
1313
deployments: write
14-
id-token: write # to enable use of OIDC for npm provenance
14+
id-token: write # to enable use of OIDC for npm provenance and trusted publishing
1515

1616
jobs:
1717
setup:
@@ -46,7 +46,6 @@ jobs:
4646
env:
4747
GITHUB_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
4848
GH_TOKEN: ${{ secrets.CAP_GH_RELEASE_TOKEN }}
49-
NPM_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
5049
run: npx semantic-release
5150

5251
publish-android:

package.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,13 +58,14 @@
5858
"@semantic-release/changelog": "^6.0.3",
5959
"@semantic-release/exec": "^7.1.0",
6060
"@semantic-release/git": "^10.0.1",
61-
"@semantic-release/github": "^11.0.1",
62-
"@semantic-release/npm": "^12.0.1",
61+
"@semantic-release/github": "^12.0.0",
62+
"@semantic-release/npm": "^13.1.1",
6363
"eslint": "^8.57.0",
6464
"prettier": "~2.3.0",
6565
"prettier-plugin-java": "~1.0.2",
6666
"rimraf": "^6.0.1",
6767
"rollup": "^4.26.0",
68+
"semantic-release": "^25.0.1",
6869
"swiftlint": "^1.0.1",
6970
"typescript": "~4.1.5"
7071
},

0 commit comments

Comments
 (0)