Skip to content

v0.2.1

v0.2.1 #5

Workflow file for this run

name: Publish to npm
on:
release:
types: [published]
permissions:
contents: read
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: oven-sh/setup-bun@v2
- uses: actions/setup-node@v4
with:
node-version: 20
- name: Sync version from release tag
run: |
VERSION="${GITHUB_REF_NAME#v}"
npm version --no-git-tag-version --allow-same-version "$VERSION"
- name: Install dependencies
run: |
bun install
cd src/client && bun install
- name: Build client
run: cd src/client && bun run build
- name: Publish to npm
run: |
echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > .npmrc
bun publish --access public --tolerate-republish
rm .npmrc
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}