5 Commits

Author SHA1 Message Date
YeonGyu-Kim 68b80e0343 perf(web): optimize CI + build pipeline
- web-ci.yml: cache .next/cache via actions/cache; drop duplicate
  next build (was running twice — typecheck + main); workflow now
  short-circuits on cache hits.
- scripts/prepare-build.mjs: gate fetch-cache purge behind
  PREPARE_BUILD_PURGE_CACHE env (default off). preview/deploy npm
  scripts no longer invoke it.
- scripts/generate-docs-content.mjs: skip write when content
  unchanged (idempotent); avoids "file mtime changed" cache busts.
- eslint.config.mjs: strip rules already enforced by Biome
  (formatting, import order, unused vars) — removes redundant
  passes, halves lint time on cold runs.
- playwright.config.ts: 2 workers in CI (was 1); webServer command
  uses already-built artifacts via 'bun run build'.

Cold build: 16.2s → 8.7s (-46%). Recompile 1.45s.
2026-05-20 14:26:08 +09:00
YeonGyu-Kim bf96794599 chore(web): move site under packages 2026-05-18 16:44:02 +09:00
YeonGyu-Kim 65fc0d9434 ci: generate docs content before web checks; bun prepare hook for local dev
The first build of #3860 failed at type-check because the generated
`lib/docs-content.generated.ts` is gitignored (regenerated on every
build) and CI's `type-check` step runs before `build`. Two fixes:

- web-ci.yml: explicit `Generate docs content from repo-root docs/`
  step right after `bun install` so format-check, lint, and type-check
  all see the file.
- web/package.json: add `prepare` lifecycle script. `bun install`
  invokes it automatically, so a fresh local checkout boots into a
  working state too.

Build still re-runs the generator via prebuild, so docs/ edits land in
the bundle without an explicit dev action.
2026-05-08 16:46:05 +09:00
YeonGyu-Kim aadcbbfcc6 chore(workflows): trigger web CI + deploy on docs/ changes
Now that docs/ is the single source of truth that the marketing site
renders at build time, edits to those files must run web CI and trigger
the Cloudflare deploy. Add `docs/**` to the paths filter in both
web-ci.yml and web-deploy.yml.

A markdown-only fix in docs/ is now sufficient to redeploy
oh-my-openagent.com — no companion web/ change needed.
2026-05-08 16:15:54 +09:00
YeonGyu-Kim 14398d5fa8 ci(web): add web-ci and web-deploy GitHub Actions workflows
web-ci.yml — runs on push/PR to master|dev that touches web/**:
- format:check (prettier --check)
- lint (eslint flat config)
- type-check (tsc --noEmit)
- bun run build (next build, sanity)
- bunx opennextjs-cloudflare build (Cloudflare worker bundle)

web-deploy.yml — runs on push to master that touches web/** OR manual
workflow_dispatch (with optional environment input):
- bun install --frozen-lockfile
- bun run prebuild + bunx opennextjs-cloudflare build
- cloudflare/wrangler-action@v3 deploy with CLOUDFLARE_API_TOKEN +
  CLOUDFLARE_ACCOUNT_ID secrets, scoped to working-directory: web

Both gated by paths-filter so plugin-only changes do not trigger them.
Concurrency group cancels in-progress CI runs but NOT in-progress deploys.
A web-production GitHub environment is referenced so deploys can be
gated behind required reviewers / wait timers if desired.

Verified locally end-to-end before push:
- bun install: 678 packages
- format:check: pass after `bun run format` reformatted 21 files
- lint: pass
- type-check: pass
- bun run build: pass (4 locales × pages built)
- bunx opennextjs-cloudflare build: pass (.open-next/worker.js generated)
2026-05-08 13:35:00 +09:00