Skip to content

Release

Release #24

Workflow file for this run

name: Release
on:
release:
types: [released, prereleased]
jobs:
release:
name: Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Set up Node 14
uses: actions/setup-node@v4
with:
registry-url: 'https://registry.npmjs.org'
node-version: 14.x
- uses: Swatinem/rust-cache@v2
- name: Build and publish 'latest' tag
if: ${{ github.event.action == 'released' }}
run: |
npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Build and publish 'next' tag
if: ${{ github.event.action == 'prereleased' }}
run: |
npm publish --tag next
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}