Skip to content

Merge branch 'boilerplate' into main #79

Merge branch 'boilerplate' into main

Merge branch 'boilerplate' into main #79

Workflow file for this run

name: Publish to GitHub Packages
on:
push:
branches:
- main
- boilerplate
jobs:
build-and-publish:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '18'
- uses: pnpm/action-setup@v4
with:
version: 9
- name: Install dependencies
run: pnpm install
- name: Run tests
run: pnpm test
- name: Build project
run: pnpm build
- name: Configure npm registry
run: |
echo "//npm.pkg.github.com/:_authToken=${{ secrets.GITHUB_TOKEN }}" > .npmrc
echo "node-bin-path=$(which node)" >> .npmrc
echo "registry=https://npm.pkg.github.com/" >> .npmrc
- name: Publish to GitHub Packages
if: github.ref == 'refs/heads/boilerplate'
run: pnpm publish --access public --no-git-checks
env:
NODE_AUTH_TOKEN: ${{ secrets.GITHUB_TOKEN }}