Release #22
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
workflow_dispatch: | |
inputs: | |
semverType: | |
description: 'Semver Type' | |
required: true | |
default: 'patch' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 16 | |
- name: General setup and install dependencies | |
run: | | |
git config --global user.name 'Release Bot' | |
git config --global user.email 'simonbengtsson@users.noreply.github.com' | |
npm ci | |
- name: Build and update version | |
run: | | |
echo "Type: ${{ github.event.inputs.semverType }}" | |
npm version ${{ github.event.inputs.semverType }} | |
- name: Deploy and publish | |
run: | | |
echo '//registry.npmjs.org/:_authToken=${NPM_TOKEN}' > .npmrc | |
npm run deploy | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |