Update package version to 2.0.0 and add CI/CD workflow for automated builds and publishing

This commit is contained in:
Space-Banane
2026-03-18 16:03:12 +01:00
parent 44382915d9
commit 01fcdd1907
2 changed files with 58 additions and 1 deletions
+54
View File
@@ -0,0 +1,54 @@
name: CI / CD
on:
push:
branches:
- '**'
pull_request:
branches:
- main
jobs:
build:
name: Test Build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10
- uses: actions/setup-node@v4
with:
node-version: '24'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm build
publish:
name: Publish to NPM
needs: build
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v4
with:
version: 10
- uses: actions/setup-node@v4
with:
node-version: '24'
registry-url: 'https://registry.npmjs.org'
cache: 'pnpm'
- run: pnpm install --frozen-lockfile
- run: pnpm build
- run: pnpm publish --no-git-checks
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}