Skip to content

Commit c7b16e9

Browse files
authored
Add publish pipeline (#123)
1 parent 3d22dec commit c7b16e9

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+
on:
3+
release:
4+
types: [published]
5+
6+
jobs:
7+
publish:
8+
name: Publish NPM package
9+
runs-on: ubuntu-latest
10+
steps:
11+
- name: Checkout the repository
12+
uses: actions/checkout@v3
13+
14+
- name: Setup Node.js
15+
uses: actions/setup-node@v3
16+
with:
17+
node-version-file: '.nvmrc'
18+
19+
- name: Install dependencies
20+
run: npm ci
21+
22+
- name: Run tests
23+
run: npm test
24+
25+
- name: Publish package
26+
uses: JS-DevTools/npm-publish@v2
27+
with:
28+
token: ${{ secrets.NPM_TOKEN_ORG }}

0 commit comments

Comments
 (0)