Skip to content

feat(build): distinguish exit codes by severity (0=ok, 1=error, 2=waring #6260

feat(build): distinguish exit codes by severity (0=ok, 1=error, 2=waring

feat(build): distinguish exit codes by severity (0=ok, 1=error, 2=waring #6260

Workflow file for this run

name: tscircuit Smoke Init Test
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
smoke-init-test:
runs-on: ubuntu-latest
if: "${{ github.event_name != 'pull_request' || github.event.pull_request.title != 'chore: bump version' }}"
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup bun
uses: oven-sh/setup-bun@v2
with:
bun-version: latest
- name: Install dependencies
run: bun install
- name: Build package
run: bun run build
- name: Pack package
run: bun pm pack
- name: Create temporary directory
run: |
TEMP_DIR=$(mktemp -d)
echo "TEMP_DIR=$TEMP_DIR" >> $GITHUB_ENV
- name: Install tscircuit globally from packed file
run: |
PACKAGE_FILE=$(ls *.tgz)
npm install -g "$PACKAGE_FILE"
- name: Test tsci init in temporary directory
run: |
cd "$TEMP_DIR"
tscircuit-cli init -y
- name: Test tsci build in temporary directory
run: |
cd "$TEMP_DIR"
export DEBUG="tsci:generate-circuit-json"
tscircuit-cli build index.circuit.tsx --ignore-errors || true
- name: Verify build output
run: |
cd "$TEMP_DIR"
ls -la
test -f index.circuit.tsx || (echo "index.circuit.tsx not found" && exit 1)