Skip to content

V2.5

V2.5 #76

Workflow file for this run

name: CI
on:
push:
branches: ['main']
pull_request:
branches: ['main']
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup PNPM v8
uses: pnpm/action-setup@v4
with:
version: 9.x.x
- name: Setup Node v21
uses: actions/setup-node@v4
with:
node-version: 21
cache: 'pnpm'
cache-dependency-path: 'pnpm-lock.yaml'
- name: Setup Supabase v1.187.8
uses: supabase/setup-cli@v1
with:
version: 1.187.8
- name: Install dependencies
run: |
pnpm install
pnpx playwright install --with-deps
- name: Start database
run: |
supabase start
supabase db reset
- name: Set environment variables
uses: nick-fields/retry@v2
with:
max_attempts: 3
timeout_minutes: 1
command: |
supabase status --output env | node convert_env.js > .env
test -s .env
- name: Install again, just in case
run: npx playwright install
- run: pnpm test
check-types:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup PNPM v9
uses: pnpm/action-setup@v4
with:
version: 9.x.x
- name: Setup Node v21
uses: actions/setup-node@v4
with:
node-version: 21
cache: 'pnpm'
cache-dependency-path: 'pnpm-lock.yaml'
- name: Setup Supabase v1.187.8
uses: supabase/setup-cli@v1
with:
version: 1.187.8
- name: Install dependencies
run: pnpm install
- name: Start database
run: |
supabase db start
supabase db reset
- name: Verify generated types match Postgres schema
run: |
supabase gen types typescript --local > src/lib/supabase.d.ts
if ! git diff --ignore-space-at-eol --exit-code --quiet src/lib/supabase.d.ts; then
echo "Detected uncommitted changes after build. See status below:" >> $GITHUB_STEP_SUMMARY
echo "```diff" >> >> $GITHUB_STEP_SUMMARY
echo $(git diff) >> $GITHUB_STEP_SUMMARY
echo "```" >> $GITHUB_STEP_SUMMARY
exit 1
fi