Skip to content

fix(ci): scope build and test to library packages only #323

fix(ci): scope build and test to library packages only

fix(ci): scope build and test to library packages only #323

Workflow file for this run

name: CI
on:
pull_request:
branches:
- main
push:
branches:
- main
env:
TURBO_CACHE_DIR: .turbo
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Cache Turbo
uses: actions/cache@v4
with:
path: .turbo
key: turbo-lint-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-${{ github.sha }}
restore-keys: |
turbo-lint-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-
turbo-lint-${{ runner.os }}-
- name: Install Dependencies
run: bun install --frozen-lockfile
- name: Run ESLint
run: bun run lint
- name: Check Formatting
run: bun run format:check
typecheck:
name: Type Check
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Cache Turbo
uses: actions/cache@v4
with:
path: .turbo
key: turbo-typecheck-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-${{ github.sha }}
restore-keys: |
turbo-typecheck-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-
turbo-typecheck-${{ runner.os }}-
- name: Install Dependencies
run: bun install --frozen-lockfile
- name: Run TypeScript Type Check
run: bun run typecheck
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Cache Turbo
uses: actions/cache@v4
with:
path: .turbo
key: turbo-build-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-${{ github.sha }}
restore-keys: |
turbo-build-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-
turbo-build-${{ runner.os }}-
- name: Install Dependencies
run: bun install --frozen-lockfile
- name: Build Library Packages
run: bunx turbo build --filter='./packages/*'
- name: Check Build Artifacts
run: |
for pkg in packages/core packages/agentx packages/node-platform packages/server packages/claude-driver packages/mono-driver packages/devtools; do
if [ -d "$pkg/dist" ]; then
echo "✅ $pkg built successfully"
else
echo "❌ $pkg build failed - no dist directory"
exit 1
fi
done
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v4
- name: Setup Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Cache Turbo
uses: actions/cache@v4
with:
path: .turbo
key: turbo-test-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-${{ github.sha }}
restore-keys: |
turbo-test-${{ runner.os }}-${{ hashFiles('**/bun.lock') }}-
turbo-test-${{ runner.os }}-
- name: Install Dependencies
run: bun install --frozen-lockfile
- name: Build (required for tests)
run: bunx turbo build --filter='./packages/*'
- name: Run Unit Tests
run: bunx turbo test --filter='./packages/*'
- name: Run BDD Tests
run: bun run test:bdd