Skip to content

CLI

The Sloppy CLI is two binaries that ship together:

  • sloppy — the runtime CLI: builds, runs, inspects, validates.
  • sloppyc — the standalone compiler. sloppy build and sloppy run invoke it for you; you only need it directly for low-level work.
sloppy --help
sloppy --version

Commands

CommandPurpose
sloppy createCopy a built-in app template into a new directory
sloppy buildCompile source into Plan-backed artifacts
sloppy packageBuild a directory app package from source artifacts
sloppy devExperimental build, run, watch, and reload for a local web app
sloppy runRun a compiled app or compile-and-run from source
sloppy routesList route metadata from a Plan
sloppy depsInspect bundled package, module, asset, and Node shim metadata
sloppy capabilitiesList declared capabilities
sloppy doctorInspect Sloppy artifacts and Plan-visible metadata
sloppy dbInspect and apply configured database migrations
sloppy ormGenerate, inspect, and apply ORM migrations
sloppy jobsInspect and operate SQLite durable scheduler tables
sloppy auditRun security/compliance checks against a Plan
sloppy openapiGenerate an OpenAPI document from a Plan
sloppycRun 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 .sloppy

See reference/sloppy-json.md for the project config schema.

Defaults

FlagDefault
--host127.0.0.1
--port5173
--environmentDevelopment
--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

CodeMeaning
0Success
1Recoverable CLI/runtime error, or Program Mode main returned 1; check stderr for the source
2-255Program 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.

Public alpha. APIs and artifact formats may still change between alpha revisions.