-
Notifications
You must be signed in to change notification settings - Fork 0
overview getting started
- Bun (the runtime and package manager). Install from https://bun.sh.
-
Pi (omp) v16.2.13 on PATH, or set
GARNISH_OMP_SOURCEto a binary path reporting that version.garnish initcopies this binary into Garnish-owned storage and verifies it with a version handshake. The learner's globalompis ignored at runtime. -
A provider API key referenced by environment variable (e.g.
ANTHROPIC_API_KEYorOPENAI_API_KEY). Garnish stores env-var references, never raw keys.
git clone https://github.com/DylanMcCavitt/garnish.git
cd garnish
bun installThere is no separate build step for the library. Typecheck is the static gate:
bun run typecheckRun the full test suite:
bun testRun only the scripted E2E happy path (init through L0 completion to unlock):
bun run test:e2ebun run garnish --helpAvailable commands:
| Command | Purpose |
|---|---|
garnish init |
Onboarding wizard: install certified runtime, configure provider, scaffold sandbox, launch |
garnish status |
Show level, XP, badges, and per-quest progress |
garnish quest |
Show the active quest's full text and checks |
garnish unlock --all |
Unlock everything (escape hatch; no XP awarded) |
garnish unlock --level N |
Unlock one level by id or order |
garnish cheat |
Alias for unlock
|
garnish doctor |
Diagnose runtime, version handshake, and gated config |
bun run garnish initThe wizard asks at most five prompts:
- Provider (anthropic / openai / other:ENV_VAR)
- Speedrun mode (n / all / a level order to skip ahead)
-
Sandbox directory (default: the Garnish root under
sandbox/)
After init, the certified Pi binary launches in an isolated sandbox with the Garnish extension autoloaded. The HUD shows "Tutorial Island, Level 0" and the first quest.
The E2E test in tests/e2e/happy-path.test.ts runs the full flow without a real omp on PATH. It writes a stub shell script that reports omp/16.2.13, sets GARNISH_OMP_SOURCE to it, and drives the bundled extension with recorded event fixtures from tests/e2e/fixtures/l0-session.jsonl. This keeps CI hermetic: no host-global omp dependency, no network, no real model calls.
- Source lives in
src/, tests mirror the structure intests/. - Quest packs live in
packs/core/, one directory per level (l0-tutorial-island/,l1-first-quest/,l2-lore/). - The test root is
tests/(configured inbunfig.toml). - No lint script exists;
bun run typecheckis the static gate. Run typecheck andbun testbefore declaring any change done.
See development workflow for the branch-and-PR cycle and testing for test patterns.