Skip to content

chore(pkg): add ci and audit workflows #1

chore(pkg): add ci and audit workflows

chore(pkg): add ci and audit workflows #1

Workflow file for this run

name: CI
on:
pull_request:
push:
branches:
- main
- master
jobs:
precheck:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Audit dependencies
run: bun audit
- name: Typecheck
run: bun run typecheck
- name: Test
run: bun run test
- name: Build
run: bun run build
build:
needs: precheck
if: needs.precheck.result == 'success'
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true
matrix:
os: ${{ fromJSON(github.event_name == 'pull_request' && '["ubuntu-latest","macos-latest","windows-latest"]' || '["ubuntu-latest"]') }}
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Audit dependencies
run: bun audit
- name: Typecheck
run: bun run typecheck
- name: Test
run: bun run test
- name: Build
run: bun run build