Skip to content

fix: correct shell quoting in release workflow #4

fix: correct shell quoting in release workflow

fix: correct shell quoting in release workflow #4

Workflow file for this run

name: CI/CD
on:
push:
branches: [main]
pull_request:
branches: [main]
workflow_dispatch:
permissions:
contents: read
jobs:
test:
name: Test (Bun on ${{ matrix.os }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v6
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: actions/cache@v5
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-
- run: bun install --frozen-lockfile
- run: bun run build:templates
- run: bun test
- run: bun run typecheck
if: matrix.os == 'ubuntu-latest'
build:
name: Build & Validate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: actions/cache@v5
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-
- run: bun install --frozen-lockfile
- run: bun run format:check
- run: bun run typecheck
- run: bun run build:templates
- run: bun run build
- run: bun run lint:package
- name: Check dist output
run: |
if [ ! -f "dist/index.js" ]; then
echo "Error: dist/index.js not found"
exit 1
fi
if [ ! -f "dist/index.d.ts" ]; then
echo "Error: dist/index.d.ts not found"
exit 1
fi
echo "✅ Build output verified"
- uses: actions/upload-artifact@v6
with:
name: dist
path: dist/
retention-days: 1
validate-examples:
name: Validate Examples
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@v6
- uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- uses: actions/cache@v5
with:
path: ~/.bun/install/cache
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lock') }}
restore-keys: |
${{ runner.os }}-bun-
- run: bun install --frozen-lockfile
- uses: actions/download-artifact@v6
with:
name: dist
path: dist/
- run: bun run examples/demo.ts --no-browser
timeout-minutes: 1
- name: Check example files
run: |
for file in examples/*.ts; do
echo "Checking $file..."
if [[ "$file" == *"demo.ts"* ]]; then
echo "✓ $file - skipping (interactive demo)"
else
bun build "$file" --target=node --outdir=/tmp/build-test > /dev/null && echo "✓ $file builds successfully"
fi
done