Skip to content
This repository was archived by the owner on Apr 15, 2025. It is now read-only.

Commit e018bfe

Browse files
committed
Publish workflow
1 parent e5a8c77 commit e018bfe

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

.github/workflows/publish.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Publish
2+
3+
on:
4+
release:
5+
types: [created]
6+
7+
jobs:
8+
publish-npm:
9+
name: Publish to npm
10+
runs-on: ubuntu-latest
11+
permissions:
12+
contents: read
13+
id-token: write
14+
steps:
15+
- uses: actions/checkout@v3
16+
- uses: actions/setup-node@v3
17+
with:
18+
node-version: 18
19+
registry-url: https://registry.npmjs.org/
20+
cache: npm
21+
- run: npm install -g npm@latest
22+
- run: npm ci
23+
- run: npm version ${TAG_NAME} --git-tag-version=false
24+
env:
25+
TAG_NAME: ${{ github.event.release.tag_name }}
26+
- run: npm publish --provenance --access public
27+
env:
28+
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}

0 commit comments

Comments
 (0)