| title | CLI Commands |
|---|---|
| description | Chronicle CLI commands reference. |
| order | 2 |
Chronicle provides a CLI to initialize, develop, build, and serve your documentation site.
Initialize a new Chronicle project. Must be run before other commands.
chronicle init [options]| Flag | Description | Default |
|---|---|---|
-c, --content <path> |
Content directory name | content |
This creates:
chronicle.yaml— site configurationcontent/(or custom name) — content directory with a sampleindex.mdxpackage.json— with@raystack/chronicledependency (if not exists).chronicle/— scaffolded build directory.gitignore— with.chronicleentry
If the content directory already exists and has files, the sample index.mdx is skipped.
Start the development server with hot reload. Requires chronicle init first.
chronicle dev [options]| Flag | Description | Default |
|---|---|---|
-p, --port <port> |
Port number | 3000 |
Build the site for production. Requires chronicle init first.
chronicle buildStart the production server. Requires a prior chronicle build.
chronicle start [options]| Flag | Description | Default |
|---|---|---|
-p, --port <port> |
Port number | 3000 |
Build and start the production server in one step. Requires chronicle init first.
chronicle serve [options]| Flag | Description | Default |
|---|---|---|
-p, --port <port> |
Port number | 3000 |
chronicle.yaml is resolved in this order:
- Current working directory
- Content directory