Skip to content

Commit

Permalink
Merge pull request #399 from kategengler/kg-add-publish-workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
kategengler authored Feb 1, 2023
2 parents 27c6b95 + 9d957f0 commit 24acf45
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Publish

on:
push:
tags:
- v*

jobs:
publish:
name: Publish to npm
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3

- name: Install node
uses: actions/setup-node@v3
with:
node-version: 14.x
registry-url: 'https://registry.npmjs.org'

- name: install dependencies
run: yarn install --frozen-lockfile

- name: auto-dist-tag
run: npx auto-dist-tag --write

- name: publish to npm
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
3 changes: 3 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,9 @@
"github": {
"release": true,
"tokenRef": "GITHUB_AUTH"
},
"npm": {
"publish": false
}
}
}

0 comments on commit 24acf45

Please sign in to comment.