CLI Commands

CLI Commands

Chronicle provides a CLI to initialize, develop, build, and serve your documentation site.

init

Initialize a new Chronicle project.

chronicle init [options]
FlagDescriptionDefault
-c, --content <path>Content directory namecontent

This creates:

  • chronicle.yaml — site configuration
  • content/ (or custom name) — content directory with a sample index.mdx
  • .gitignore — with node_modules, dist, .output entries

If the content directory already exists and has files, the sample index.mdx is skipped.

dev

Start the development server with hot reload.

chronicle dev [options]
FlagDescriptionDefault
--content <path>Content directorycontent
--config <path>Path to chronicle.yaml./chronicle.yaml
-p, --port <port>Port number3000
--host <host>Host addresslocalhost

build

Build the site for production.

chronicle build [options]
FlagDescriptionDefault
--content <path>Content directorycontent
--config <path>Path to chronicle.yaml./chronicle.yaml
--preset <preset>Deploy preset (vercel, cloudflare, node-server)

start

Start the production server. Requires a prior chronicle build.

chronicle start [options]
FlagDescriptionDefault
--content <path>Content directorycontent
-p, --port <port>Port number3000
--host <host>Host addresslocalhost

serve

Build and start the production server in one step.

chronicle serve [options]
FlagDescriptionDefault
--content <path>Content directorycontent
--config <path>Path to chronicle.yaml./chronicle.yaml
-p, --port <port>Port number3000
--host <host>Host addresslocalhost
--preset <preset>Deploy preset (vercel, cloudflare, node-server)

Resolution Order

CLI flags take precedence over chronicle.yaml values, which take precedence over defaults.

OptionCLI flagConfig fieldDefault
Content directory--contentcontentcontent
Deploy preset--presetpreset
Config path--config./chronicle.yaml