Skip to content

Commit 24acf45

Browse files
authored
Merge pull request #399 from kategengler/kg-add-publish-workflow
2 parents 27c6b95 + 9d957f0 commit 24acf45

File tree

2 files changed

+34
-0
lines changed

2 files changed

+34
-0
lines changed

.github/workflows/publish.yml

+31
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
name: Publish
2+
3+
on:
4+
push:
5+
tags:
6+
- v*
7+
8+
jobs:
9+
publish:
10+
name: Publish to npm
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout
14+
uses: actions/checkout@v3
15+
16+
- name: Install node
17+
uses: actions/setup-node@v3
18+
with:
19+
node-version: 14.x
20+
registry-url: 'https://registry.npmjs.org'
21+
22+
- name: install dependencies
23+
run: yarn install --frozen-lockfile
24+
25+
- name: auto-dist-tag
26+
run: npx auto-dist-tag --write
27+
28+
- name: publish to npm
29+
run: npm publish
30+
env:
31+
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}

package.json

+3
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,9 @@
9898
"github": {
9999
"release": true,
100100
"tokenRef": "GITHUB_AUTH"
101+
},
102+
"npm": {
103+
"publish": false
101104
}
102105
}
103106
}

0 commit comments

Comments
 (0)