Skip to content

Commit d6a7d3b

Browse files
committed
fix: separate OG image generation from generate step
OG images require Playwright which isn't available during the generate step in CI. Split into generate:og script and run it after Playwright install in the deploy workflow.
1 parent 1fbd764 commit d6a7d3b

2 files changed

Lines changed: 5 additions & 1 deletion

File tree

.github/workflows/deploy-pages.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,9 @@ jobs:
4343

4444
# Build playground (Vite)
4545
- run: pnpm --filter spac-playground generate
46+
- run: npx playwright install --with-deps chromium
47+
working-directory: packages/playground
48+
- run: pnpm --filter spac-playground generate:og
4649
- run: pnpm --filter spac-playground build
4750
env:
4851
GITHUB_PAGES: true

packages/playground/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
"lint": "eslint .",
1010
"preview": "vite preview",
1111
"codegen": "tsx scripts/codegen-from-specs.ts",
12-
"generate": "tsx scripts/codegen-from-specs.ts && tsx scripts/generate-fixtures.ts && tsx scripts/bundle-declarations.ts && tsx scripts/validate-fixtures.ts && tsx scripts/generate-og-images.ts",
12+
"generate": "tsx scripts/codegen-from-specs.ts && tsx scripts/generate-fixtures.ts && tsx scripts/bundle-declarations.ts && tsx scripts/validate-fixtures.ts",
13+
"generate:og": "tsx scripts/generate-og-images.ts",
1314
"test:e2e": "playwright test"
1415
},
1516
"dependencies": {

0 commit comments

Comments
 (0)