diff --git a/AGENTS.md b/AGENTS.md index 734599b..7842abc 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -25,8 +25,8 @@ bun compile:linux # Compile server for Linux x64 bun compile:mac # Compile server for macOS arm64 bun compile:win # Compile server for Windows x64 bun dist # Full packaging pipeline: server build → compile → desktop distributable (current platform) -bun dist:linux # Full pipeline → Linux distributable -bun dist:mac # Full pipeline → macOS distributable +bun dist:linux # Full pipeline → Linux distributables (x64 + arm64) +bun dist:mac # Full pipeline → macOS distributables (arm64 + x64) bun dist:win # Full pipeline → Windows distributable bun fix # Lint + format (Biome auto-fix) bun typecheck # TypeScript check across monorepo @@ -37,9 +37,14 @@ bun typecheck # TypeScript check across monorepo bun dev # Vite dev server (localhost:3000) bun build # Production build -> .output/ bun compile # Compile to standalone binary (current platform) -bun compile:linux # Compile for Linux x64 -bun compile:mac # Compile for macOS arm64 -bun compile:win # Compile for Windows x64 +bun compile:darwin # Compile for macOS (default: arm64) +bun compile:darwin:arm64 # Compile for macOS arm64 +bun compile:darwin:x64 # Compile for macOS x64 +bun compile:linux # Compile for Linux (default: x64) +bun compile:linux:arm64 # Compile for Linux arm64 +bun compile:linux:x64 # Compile for Linux x64 +bun compile:windows # Compile for Windows (default: x64) +bun compile:windows:x64 # Compile for Windows x64 bun fix # Biome auto-fix bun typecheck # TypeScript check @@ -55,9 +60,13 @@ bun db:studio # Open Drizzle Studio bun dev # electron-vite dev mode (requires server dev running) bun build # electron-vite build (main + preload) bun dist # Build + package for current platform -bun dist:linux # Build + package for Linux -bun dist:mac # Build + package for macOS -bun dist:win # Build + package for Windows +bun dist:linux # Build + package for Linux (x64 + arm64) +bun dist:linux:x64 # Build + package for Linux x64 +bun dist:linux:arm64 # Build + package for Linux arm64 +bun dist:mac # Build + package for macOS (arm64 + x64) +bun dist:mac:arm64 # Build + package for macOS arm64 +bun dist:mac:x64 # Build + package for macOS x64 +bun dist:win # Build + package for Windows x64 bun fix # Biome auto-fix bun typecheck # TypeScript check ``` diff --git a/apps/desktop/AGENTS.md b/apps/desktop/AGENTS.md index 88dfb5e..0b39d90 100644 --- a/apps/desktop/AGENTS.md +++ b/apps/desktop/AGENTS.md @@ -25,9 +25,13 @@ Thin Electron shell hosting the fullstack server app. bun dev # electron-vite dev (requires server dev running) bun build # electron-vite build (main + preload) bun dist # Build + package for current platform -bun dist:linux # Build + package for Linux -bun dist:mac # Build + package for macOS -bun dist:win # Build + package for Windows +bun dist:linux # Build + package for Linux (x64 + arm64) +bun dist:linux:x64 # Build + package for Linux x64 +bun dist:linux:arm64 # Build + package for Linux arm64 +bun dist:mac # Build + package for macOS (arm64 + x64) +bun dist:mac:arm64 # Build + package for macOS arm64 +bun dist:mac:x64 # Build + package for macOS x64 +bun dist:win # Build + package for Windows x64 bun fix # Biome auto-fix bun typecheck # TypeScript check ``` @@ -61,12 +65,13 @@ bun typecheck # TypeScript check From monorepo root, run `bun dist` to execute the full pipeline automatically (via Turbo task dependencies): 1. **Build server**: `apps/server` → `vite build` → `.output/` -2. **Compile server**: `apps/server` → `bun compile.ts` → `out/server-{os}-{arch}` +2. **Compile server**: `apps/server` → `bun compile.ts --target ...` → `out/server-{os}-{arch}` 3. **Package desktop**: `apps/desktop` → `electron-vite build` + `electron-builder` → distributable The `electron-builder.yml` `extraResources` config reads binaries directly from `../server/out/`, no manual copy needed. To build for a specific platform explicitly, use `bun dist:linux` / `bun dist:mac` / `bun dist:win` in `apps/desktop`. +For single-arch output, use `bun dist:linux:x64`, `bun dist:linux:arm64`, `bun dist:mac:x64`, or `bun dist:mac:arm64`. ## Critical Rules diff --git a/apps/server/AGENTS.md b/apps/server/AGENTS.md index 2ec9c51..828304d 100644 --- a/apps/server/AGENTS.md +++ b/apps/server/AGENTS.md @@ -26,9 +26,14 @@ bun db:studio # Drizzle Studio GUI # Build bun build # Production build → .output/ bun compile # Compile to standalone binary (current platform, depends on build) -bun compile:linux # Compile for Linux x64 -bun compile:mac # Compile for macOS arm64 -bun compile:win # Compile for Windows x64 +bun compile:darwin # Compile for macOS (default: arm64) +bun compile:darwin:arm64 # Compile for macOS arm64 +bun compile:darwin:x64 # Compile for macOS x64 +bun compile:linux # Compile for Linux (default: x64) +bun compile:linux:arm64 # Compile for Linux arm64 +bun compile:linux:x64 # Compile for Linux x64 +bun compile:windows # Compile for Windows (default: x64) +bun compile:windows:x64 # Compile for Windows x64 # Code Quality bun fix # Biome auto-fix