Skip to content

Commit 7f676ba

Browse files
authored
Update publish workflow (#648)
1 parent 95d119a commit 7f676ba

File tree

3 files changed

+15
-27
lines changed

3 files changed

+15
-27
lines changed

.github/workflows/publish.yml

Lines changed: 10 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,10 @@ name: NPM Publish
33
on:
44
release:
55
types: [published]
6-
secrets:
7-
NPM_TOKEN:
8-
required: true
6+
7+
permissions:
8+
id-token: write
9+
contents: read
910

1011
jobs:
1112
publish:
@@ -15,20 +16,6 @@ jobs:
1516
image: ghcr.io/viamrobotics/canon:amd64
1617

1718
steps:
18-
- name: Check if organization member
19-
id: is_organization_member
20-
if: github.event_name == 'workflow_dispatch'
21-
uses: jamessingleton/[email protected]
22-
with:
23-
organization: viamrobotics
24-
username: ${{ github.actor }}
25-
token: ${{ secrets.GITHUB_TOKEN }}
26-
27-
- name: Cancelling - not an organization member
28-
uses: andymckay/[email protected]
29-
if: |
30-
github.event_name == 'workflow_dispatch' && steps.is_organization_member.outputs.result == 'false'
31-
3219
- name: Download Release
3320
uses: dsaltares/fetch-gh-release-asset@master
3421
with:
@@ -51,13 +38,14 @@ jobs:
5138
echo "tag=latest" >> $GITHUB_OUTPUT
5239
fi
5340
41+
- uses: actions/setup-node@v4
42+
with:
43+
node-version: '24'
44+
registry-url: 'https://registry.npmjs.org'
45+
5446
- name: Publish
5547
id: publish
56-
uses: JS-DevTools/npm-publish@v2
57-
with:
58-
token: ${{ secrets.NPM_TOKEN }}
59-
tag: ${{ steps.which_tag.outputs.tag }}
60-
package: ${{ steps.release_file.outputs.path }}
48+
run: npm publish ${{ steps.release_file.outputs.path }}
6149

6250
- name: Notify Slack
6351
uses: slackapi/[email protected]

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656
"@connectrpc/connect": "^1.6.0",
5757
"@connectrpc/connect-web": "^1.6.0",
5858
"bsonfy": "^1.0.2",
59-
"exponential-backoff": "^3.1.2"
59+
"exponential-backoff": "^3.1.3"
6060
},
6161
"devDependencies": {
6262
"@bufbuild/buf": "^1.15.0-1",

0 commit comments

Comments
 (0)