Skip to content

Fix: comments and tests for word-stats package #658

Fix: comments and tests for word-stats package

Fix: comments and tests for word-stats package #658

Workflow file for this run

name: Release
on:
pull_request:
types: [opened, synchronize, reopened]
release:
# "released" events are emitted either when directly be released or be edited from pre-released.
types: [prereleased, released]
jobs:
deploy:
runs-on: ubuntu-latest
continue-on-error: true
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4.0.0
- uses: actions/setup-node@v4
with:
# https://nodejs.org/en/about/previous-releases
node-version: '22.x'
registry-url: 'https://registry.npmjs.org'
cache: pnpm
cache-dependency-path: pnpm-lock.yaml
- name: install and build
run: |
pnpm install
pnpm build
- name: update version
if: github.event_name == 'release'
run: |
git config user.email "dummy@dummy"
git config user.name "dummy"
pnpm version from-git --allow-same-version --no-git-tag-version || true
- name: deploy
run: pnpm publish --access=public --no-git-checks --recursive
if: github.event_name == 'release' && !github.event.release.prerelease
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: deploy (dry-run)
run: pnpm publish --access=public --no-git-checks --dry-run --recursive
if: github.event_name != 'release' || github.event.release.prerelease
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}