Skip to content

Commit c7d7e1e

Browse files
francofrizzoclaude
andcommitted
ci: merge into single job, skip on docs-only changes, overlap Supabase with checks
- Single job saves 1 billed minute per run (no duplicate setup) - Path filters skip CI for README/CLAUDE.md/config-only changes - Supabase starts in background while checks run, ready by E2E time - Projected: 4 min → 2 min billed per push Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 6f8b6e3 commit c7d7e1e

1 file changed

Lines changed: 43 additions & 20 deletions

File tree

.github/workflows/ci.yml

Lines changed: 43 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -3,26 +3,31 @@ name: CI
33
on:
44
push:
55
branches: [main]
6+
paths:
7+
- "src/**"
8+
- "tests/**"
9+
- "supabase/**"
10+
- "package.json"
11+
- "pnpm-lock.yaml"
12+
- "tsconfig*.json"
13+
- "vite.config.ts"
14+
- "playwright.config.ts"
15+
- ".github/workflows/ci.yml"
616
pull_request:
717
branches: [main]
18+
paths:
19+
- "src/**"
20+
- "tests/**"
21+
- "supabase/**"
22+
- "package.json"
23+
- "pnpm-lock.yaml"
24+
- "tsconfig*.json"
25+
- "vite.config.ts"
26+
- "playwright.config.ts"
27+
- ".github/workflows/ci.yml"
828

929
jobs:
10-
check:
11-
runs-on: ubuntu-latest
12-
steps:
13-
- uses: actions/checkout@v4
14-
- uses: pnpm/action-setup@v4
15-
- uses: actions/setup-node@v4
16-
with:
17-
node-version: 22
18-
cache: pnpm
19-
- run: pnpm install --frozen-lockfile
20-
- run: pnpm run type-check
21-
- run: pnpm run lint
22-
- run: pnpm test
23-
- run: pnpm run build
24-
25-
e2e:
30+
ci:
2631
runs-on: ubuntu-latest
2732
steps:
2833
- uses: actions/checkout@v4
@@ -47,11 +52,29 @@ jobs:
4752
if: steps.playwright-cache.outputs.cache-hit != 'true'
4853
run: pnpm exec playwright install chromium --with-deps
4954

50-
- name: Start Supabase & install Playwright deps in parallel
55+
# Start Supabase in background — runs during checks, ready by E2E time
56+
- name: Start Supabase (background)
57+
run: supabase start --exclude realtime,edge-runtime,logflare,vector,studio,imgproxy,supavisor &
58+
59+
# --- Checks (Supabase starts in parallel) ---
60+
- run: pnpm run type-check
61+
- run: pnpm run lint
62+
- run: pnpm test
63+
- run: pnpm run build
64+
65+
# --- E2E ---
66+
- name: Install Playwright system deps
67+
if: steps.playwright-cache.outputs.cache-hit == 'true'
68+
run: pnpm exec playwright install-deps chromium
69+
70+
- name: Wait for Supabase
5171
run: |
52-
supabase start --exclude realtime,edge-runtime,logflare,vector,studio,imgproxy,supavisor &
53-
pnpm exec playwright install-deps chromium &
54-
wait
72+
for i in $(seq 1 30); do
73+
supabase status &>/dev/null && break
74+
echo "Waiting for Supabase... ($i)"
75+
sleep 2
76+
done
77+
supabase status
5578
5679
- run: pnpm exec tsx tests/e2e/seed.ts
5780
- run: pnpm exec playwright test

0 commit comments

Comments
 (0)