fix: add bun install to go:generate and packages:bundle to build

- Split go:generate into `bun install` + `bun run build` so deps are
  always available before bundling (fixes build on clean checkout)
- Add `packages: 'bundle'` to Bun.build() so node_modules are resolved
  and bundled into the output (required for marked + highlight.js)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
dj-oyu 2026-03-15 16:15:17 +09:00
parent 3fd9516de5
commit b63d0db489
2 changed files with 2 additions and 0 deletions

View file

@ -15,6 +15,7 @@ const result = await Bun.build({
target: 'browser',
format: 'iife',
sourcemap: 'none',
packages: 'bundle',
});
if (!result.success) {

View file

@ -13,6 +13,7 @@ import (
"github.com/sipeed/picoclaw/pkg/research"
)
//go:generate bun install --cwd frontend
//go:generate bun run --cwd frontend build
//go:embed static
var staticFS embed.FS