CLI
The Sloppy CLI is two binaries that ship together:
sloppy— the runtime CLI: builds, runs, inspects, validates.sloppyc— the standalone compiler.sloppy buildandsloppy runinvoke it for you; you only need it directly for low-level work.
sloppy --help
sloppy --versionCommands
| Command | Purpose |
|---|---|
sloppy create | Copy a built-in app template into a new directory |
sloppy build | Compile source into Plan-backed artifacts |
sloppy package | Build a directory app package from source artifacts |
sloppy dev | Experimental build, run, watch, and reload for a local web app |
sloppy run | Run a compiled app or compile-and-run from source |
sloppy routes | List route metadata from a Plan |
sloppy deps | Inspect bundled package, module, asset, and Node shim metadata |
sloppy capabilities | List declared capabilities |
sloppy doctor | Inspect Sloppy artifacts and Plan-visible metadata |
sloppy db | Inspect and apply configured database migrations |
sloppy orm | Generate, inspect, and apply ORM migrations |
sloppy jobs | Inspect and operate SQLite durable scheduler tables |
sloppy audit | Run security/compliance checks against a Plan |
sloppy openapi | Generate an OpenAPI document from a Plan |
sloppyc | Run the compiler directly |
create, build, run, and package are the normal app workflow. The inspection tools work against an already-built app.plan.json.
Project mode vs explicit paths
Most commands work in two ways: read sloppy.json from the current directory (project mode), or take explicit paths.
# project mode — uses sloppy.json
sloppy build
sloppy dev
sloppy run
sloppy package
# explicit
sloppy build src/main.ts
sloppy run src/main.ts
sloppy run .sloppy
sloppy package src/main.ts
sloppy openapi .sloppySee reference/sloppy-json.md for the project config schema.
Defaults
| Flag | Default |
|---|---|
--host | 127.0.0.1 |
--port | 5173 |
--environment | Development |
--out / outDir | .sloppy |
--host and --port apply to experimental sloppy dev and sloppy run; sloppy build accepts them so they can be baked into the Plan but doesn't open a socket. --environment selects which appsettings.{Environment}.json overlay applies.
sloppy create defaults to api. The current public template names are api, minimal-api, program, cli, package-api, and node-compat.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | Recoverable CLI/runtime error, or Program Mode main returned 1; check stderr for the source |
| 2-255 | Program Mode main returned that exit code, or the runtime hit an internal error |
Diagnostics print to stderr; structured output (when --format json is available) goes to stdout.