Documentation
Toolchain
The walnut CLI typechecks and compiles Walnut to native code.
Install: homebrew.md.
Commands
| Command | Behavior |
|---|---|
walnut new <App> | Scaffold an app |
walnut check [dir] | Parse + static typecheck |
walnut run <file> | Run a script main on the host — jit.md |
walnut repl | Compiling REPL — jit.md |
walnut build [dir] | Typecheck → compile → Xcode project |
walnut simulator | Build + install/launch in Simulator (--watch = hot reload) |
walnut device | Build + install/launch on a phone (device.md) |
walnut testflight | Release IPA → TestFlight (testflight.md) |
walnut screenshots / store upload | Listing capture + App Store Connect metadata |
walnut format <file…> | Format .walnut sources |
walnut test [dir] | Run in-language tests — testing.md |
walnut docs | Generate API docs — documentation.md |
walnut install / add / update | Packages — packages.md |
walnut login / publish | Registry — registry.md |
walnut license | License status — licensing.md |
walnut lsp | Language server — editor-support.md |
Build pipeline (apps)
- Discover app
src/plus locked packages - Typecheck
- Compile to native object code under
ios/Generated/ - Generate / update the Xcode project and build for Simulator or device
Host LLVM
Host commands (run, repl, some package flows) need Homebrew llvm. The formula installs it for you.
Manifest
walnut.json / walnut.toml hold name, bundleId, sources, and runtime. Optional developmentTeam is used by walnut device.
Editor support
See editor-support.md.