Skip to content

Commit f1ce1b7

Browse files
committed
docs: updated readme
1 parent 9401668 commit f1ce1b7

1 file changed

Lines changed: 13 additions & 0 deletions

File tree

README.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,17 @@ Frontmatter is parsed line-by-line — no YAML dependency. Four fields:
9494

9595
`synopsis` is the key design decision: read it, decide whether to open the file, move on. `source` lets future-you reconstruct *why* a note exists without re-reading it.
9696

97+
### Schema contract
98+
99+
The frontmatter contract is published as a public, stdlib-only Go package at `github.com/polymorcodeus/park/schema` and exposed through the CLI:
100+
101+
```bash
102+
park schema # human-readable contract
103+
park schema --json # machine-readable contract for downstream tooling
104+
```
105+
106+
The JSON output includes the canonical category enum, field kinds, the date format, and the exact write template. Import the package directly when building tools that write or validate park notes.
107+
97108
### Reclassification
98109

99110
`park reclassify <file> -c <category>` rewrites frontmatter *before* moving the file. A failed move never leaves a note in a half-updated state. Same-category moves are rejected.
@@ -109,6 +120,8 @@ Frontmatter is parsed line-by-line — no YAML dependency. Four fields:
109120
| `show <file>` | glamour-render a note, no TUI |
110121
| `reclassify <file> -c <cat>` | reclassify a note (alias `recat`) |
111122
| `config` | print the default TOML config |
123+
| `schema` | print the frontmatter schema contract |
124+
| `schema --json` | print the contract as machine-readable JSON |
112125

113126
### `park new` options
114127

0 commit comments

Comments
 (0)