Skip to content

Commit d7b4115

Browse files
rsbhclaude
andcommitted
docs: update cli and config docs for new flags and config fields
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 93859bb commit d7b4115

File tree

3 files changed

+35
-11
lines changed

3 files changed

+35
-11
lines changed

docs/cli.mdx

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ Chronicle provides a CLI to initialize, develop, build, and serve your documenta
1010

1111
## init
1212

13-
Initialize a new Chronicle project. Must be run before other commands.
13+
Initialize a new Chronicle project.
1414

1515
```bash
1616
chronicle init [options]
@@ -37,7 +37,8 @@ chronicle dev [options]
3737

3838
| Flag | Description | Default |
3939
|------|-------------|---------|
40-
| `-c, --content <path>` | Content directory | `content` |
40+
| `--content <path>` | Content directory | `content` |
41+
| `--config <path>` | Path to `chronicle.yaml` | `./chronicle.yaml` |
4142
| `-p, --port <port>` | Port number | `3000` |
4243

4344
## build
@@ -50,7 +51,8 @@ chronicle build [options]
5051

5152
| Flag | Description | Default |
5253
|------|-------------|---------|
53-
| `-c, --content <path>` | Content directory | `content` |
54+
| `--content <path>` | Content directory | `content` |
55+
| `--config <path>` | Path to `chronicle.yaml` | `./chronicle.yaml` |
5456
| `--preset <preset>` | Deploy preset (`vercel`, `cloudflare`, `node-server`) ||
5557

5658
## start
@@ -63,7 +65,7 @@ chronicle start [options]
6365

6466
| Flag | Description | Default |
6567
|------|-------------|---------|
66-
| `-c, --content <path>` | Content directory | `content` |
68+
| `--content <path>` | Content directory | `content` |
6769
| `-p, --port <port>` | Port number | `3000` |
6870

6971
## serve
@@ -76,13 +78,17 @@ chronicle serve [options]
7678

7779
| Flag | Description | Default |
7880
|------|-------------|---------|
79-
| `-c, --content <path>` | Content directory | `content` |
81+
| `--content <path>` | Content directory | `content` |
82+
| `--config <path>` | Path to `chronicle.yaml` | `./chronicle.yaml` |
8083
| `-p, --port <port>` | Port number | `3000` |
8184
| `--preset <preset>` | Deploy preset (`vercel`, `cloudflare`, `node-server`) ||
8285

83-
## Config Resolution
86+
## Resolution Order
8487

85-
`chronicle.yaml` is resolved in this order:
88+
CLI flags take precedence over `chronicle.yaml` values, which take precedence over defaults.
8689

87-
1. Current working directory
88-
2. Content directory
90+
| Option | CLI flag | Config field | Default |
91+
|--------|----------|-------------|---------|
92+
| Content directory | `--content` | `content` | `content` |
93+
| Deploy preset | `--preset` | `preset` ||
94+
| Config path | `--config` || `./chronicle.yaml` |

docs/components.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ Chronicle overrides these HTML elements with styled components:
203203
| HTML Element | Chronicle Component | Notes |
204204
|-------------|-------------------|-------|
205205
| `<p>` | `MdxParagraph` | Auto-converts to `<div>` when containing block elements |
206-
| `<img>` | `Image` | Next.js optimized for local, standard for external |
206+
| `<img>` | `Image` | Optimized for local, standard for external |
207207
| `<a>` | `Link` | Smart routing with external link detection |
208208
| `<code>` | `MdxCode` | Inline code styling |
209209
| `<pre>` | `MdxPre` | Code blocks with optional title header |

docs/configuration.mdx

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,16 @@ order: 3
66

77
# Configuration
88

9-
All site configuration lives in a single `chronicle.yaml` file in your content directory.
9+
All site configuration lives in a single `chronicle.yaml` file in your project root. The config is validated using Zod — invalid fields will produce clear error messages at startup.
1010

1111
## Full Example
1212

1313
```yaml
1414
title: My Project Docs
1515
description: Documentation for My Project
1616
url: https://docs.example.com
17+
content: docs
18+
preset: vercel
1719

1820
logo:
1921
light: ./logo-light.png
@@ -80,6 +82,22 @@ Optional site URL. Used for SEO metadata, sitemap, and canonical URLs.
8082
url: https://docs.example.com
8183
```
8284
85+
### content
86+
87+
Optional content directory path. Can be overridden by the `--content` CLI flag.
88+
89+
```yaml
90+
content: docs
91+
```
92+
93+
### preset
94+
95+
Optional deploy preset. Can be overridden by the `--preset` CLI flag.
96+
97+
```yaml
98+
preset: vercel # vercel, cloudflare, or node-server
99+
```
100+
83101
### description
84102

85103
Optional meta description for SEO.

0 commit comments

Comments
 (0)