CLI
Seven commands. sigil dev is the one you will use most; the rest are scaffolding and production.
sigil --help
sigil --versioncreate
Scaffolds a new project:
sigil create my-appdev
Development server — compiles on demand, watches files, hot-reloads:
sigil devReads sigil.config.ts and expects dev to be on. This is the command to use while writing an app.
start
Production server behind the loom coordinator:
sigil start
sigil start --scale api=2,frontend=1
sigil start --no-build--scale <spec>— worker counts per group, e.g.api=2,frontend=1. Without it, the config decides.--no-build— skip the build step and serve the existing output. Use it when the build already ran in CI, or you will compile twice on every deploy.
This is the command that runs in production. The coordinator supervises the workers and restarts them if one dies.
build
Compiles a production bundle without serving anything:
sigil buildWhat sigil start does first unless you pass --no-build. Run it alone in CI so a compile failure fails the pipeline instead of a deploy.
preview
Serves a production build locally, without the coordinator's supervision or restart behaviour:
sigil previewUseful for checking a production build on your own machine before shipping it. For anything you intend to deploy, test with sigil start — preview does not exercise the same process model.
routes
Prints the route table the scanner found:
sigil routesThe fastest way to answer "why is this URL 404ing". It prints the methods, the resolved path, and the file each came from — including WS for WebSocket routes. If a route is missing here, it is missing from the build — the most common cause is a directory with only a +page.server.ts and no +page.tsx or +server.ts, which the scanner drops silently.
generate
Scaffolds a file. Aliased to g:
sigil g page books/[id]
sigil g layout admin
sigil g api search
sigil g component Button
sigil g error
sigil g ws
sigil g hooks
sigil g middleware
sigil g auth| Type | Creates |
|---|---|
page | A route: +page.tsx and +page.server.ts |
layout | A +layout.tsx wrapping a directory |
api | A +server.ts handler |
component | A component in src/components |
error | A +error.tsx boundary |
ws | A WebSocket route |
hooks | hooks.server.ts |
middleware | A middleware file |
auth | An auth scaffold |
One caveat: auth is implemented but missing from the --help text, so sigil g --help lists eight types and not nine. It works; the help is wrong.
info
Prints project information — versions, detected config, route count:
sigil infoThe first thing to run when a build behaves differently on your machine than in CI.
Next
- sigil.config.ts — what
dev,buildandstartread - Route files — what
generatescaffolds