Skip to content

Commit c1c6fa4

Browse files
authored
Fix npm release and enable trusted publishing (#1211)
2 parents 041ca35 + dcf796d commit c1c6fa4

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

.github/workflows/release.yml

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@ on:
66
- main
77
types: [ closed ]
88

9+
permissions:
10+
id-token: write # Required for OIDC. See https://docs.npmjs.com/trusted-publishers#step-2-configure-your-cicd-workflow
11+
contents: read
912

1013
jobs:
1114
changelog:
@@ -22,6 +25,11 @@ jobs:
2225
with:
2326
token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }}
2427

28+
- uses: actions/setup-node@v4
29+
with:
30+
node-version: '24'
31+
registry-url: 'https://registry.npmjs.org'
32+
2533
- name: Configure Git author
2634
run: |
2735
git config --global user.name "Open Terms Archive Release Bot"
@@ -59,10 +67,11 @@ jobs:
5967
body: ${{ steps.release-changelog.outputs.content }}
6068
token: ${{ secrets.RELEASE_BOT_GITHUB_TOKEN }}
6169

70+
- name: Update npm
71+
run: npm install -g npm@latest
72+
6273
- name: Publish to NPM public repository
63-
uses: JS-DevTools/npm-publish@v1
64-
with:
65-
token: ${{ secrets.NPMJS_ACCESS_TOKEN }}
74+
run: npm publish
6675

6776
- name: Trigger documentation deploy
6877
uses: peter-evans/repository-dispatch@v2

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
All changes that impact users of this module are documented in this file, in the [Common Changelog](https://common-changelog.org) format with some additional specifications defined in the CONTRIBUTING file. This codebase adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
44

5+
## Unreleased [no-release]
6+
7+
_Modifications made in this changeset do not add, remove or alter any behavior, dependency, API or functionality of the software. They only change non-functional parts of the repository, such as the README file or CI workflows._
8+
59
## 10.1.1 - 2025-11-25
610

711
_Full changeset and discussions: [#1209](https://github.com/OpenTermsArchive/engine/pull/1209)._

0 commit comments

Comments
 (0)