Skip to content

Commit

Permalink
DEV: Add release workflow (#22)
Browse files Browse the repository at this point in the history
closes #22
  • Loading branch information
dwhieb committed Feb 28, 2024
1 parent 86bab52 commit a25686e
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: release

on:
release:
types:
- published

jobs:
publish:
name: publish
runs-on: ubuntu-latest
steps:

- name: Check out repo
uses: actions/checkout@v4

- name: Set up Node for npm
uses: actions/setup-node@v4
with:
node-version: latest
registry-url: https://registry.npmjs.org/

- name: Install dependencies
run: npm ci

- name: Run tests
run: npm test

- name: Publish to npm
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

- name: Set up Node for GitHub
uses: actions/setup-node@v4
with:
node-version: latest
registry-url: https://npm.pkg.github.com
scope: '@digitallinguistics'

- name: Publish to GitHub Package Registry
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit a25686e

Please sign in to comment.