feat(installer): --dev flag builds CLI + gateway from source #681

Merged
jason.woltje merged 2 commits from feat/installer-dev-build-from-source into main 2026-06-24 23:54:52 +00:00

2 Commits

Author SHA1 Message Date
Jarvis
4dd9806af1 fix(installer): clearer pnpm/corepack errors + dev-aware --check
Some checks failed
ci/woodpecker/push/ci Pipeline was canceled
ci/woodpecker/pr/ci Pipeline was successful
Review follow-ups on the --dev feature:
- Pin corepack to pnpm@10.6.2 (the repo packageManager) and surface
  corepack enable/prepare failures, with an actionable hard-fail when pnpm
  is still absent — the fresh-machine path no longer dies on a bare
  "command not found".
- `--check --dev` now reports the installed version instead of a
  misleading "Could not reach registry" warning (dev mode skips the
  registry lookup).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RMoEx7hfdFGjUiCHuN1RRi
2026-06-24 17:58:21 -05:00
Jarvis
745b9c4967 feat(installer): --dev flag builds CLI + gateway from source
Adds `install.sh --dev` (and MOSAIC_DEV=1): instead of installing
@mosaicstack/mosaic from the registry @latest, download the monorepo archive
at --ref, `pnpm install` + build, `pnpm pack` both @mosaicstack/mosaic and
@mosaicstack/gateway, and `npm install -g` both local tarballs. ZERO registry
writes — no dev dist-tags. Workspace deps resolve from the registry at the
versions `pnpm pack` rewrites `workspace:*` into.

Exports MOSAIC_GATEWAY_SKIP_NPM_INSTALL=1 so the auto-launched wizard keeps the
source-built global gateway instead of overwriting it with the registry build.

Refactors the archive download into a shared ensure_monorepo helper reused by
both the framework install (Part 1) and the dev build (Part 2).

Lets a branch be tested end-to-end on a clean machine before cutting a release,
reducing semver churn.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01RMoEx7hfdFGjUiCHuN1RRi
2026-06-24 17:58:21 -05:00