paper.yml
A repo’s paper.yml, at its root, says which of its markdown files go to your device, as reading copies or as proofs, and how the marks come back. Every key is optional. An empty file sends nothing.
| Key | Type | Default | What it does |
|---|---|---|---|
copies |
list | none | Reading copies, kept current on the device. Each entry is a glob (docs/**/*.md) or {glob, folder}. A copy is rewritten in place when its words, pictures or renderer change, so your marks stay beside it. Marks on a copy become notes. |
proofs |
list | none | Proofs to send, one round each. Each entry is a file or {file, title}. The line is removed from the file once it’s sent. Without a title, a proof is called <repo name> <the file's title>. |
folder |
text | the copies folder in settings.json |
Where this repo’s copies land, as a path under the device’s documents folder (study/my-repo). A path written from the top of Drive (Supernote/Document/study/my-repo) works too. A {glob, folder} entry in copies overrides it for those files. |
edits |
pull-request or main |
pull-request |
How a proof’s edits come back to the repo: as a pull request, or straight to the main branch. |
placed_by |
workflow or local |
workflow |
Who sends this repo. workflow means GitHub Actions renders and the freehand script places the PDFs in Drive. local means freehand watch on your computer does both. Each only sends a repo that names it, so a repo is never sent twice. |
renderers |
map | Freehand’s own | A repo’s own renderer for copy, proof or both. See below. |
drive |
map | from settings.json |
Drive folders by full path and ID. Optional: the folders come from settings.json, so paper.yml needs no IDs. See below. |
follow |
list | none | Files to send a new proof round for whenever they’ve moved on. Read by your AI, not by Freehand’s code: it checks each followed file once a day, and sends the next round only when the last is closed and the file has settled. |
Example
Section titled “Example”placed_by: localfolder: study/my-repocopies: - docs/**/*.md - {glob: docs/research/*.md, folder: study/research}proofs: - docs/plan.md - {file: docs/launch.md, title: "my-app launch plan"}edits: pull-requestrenderers
Section titled “renderers”A repo whose pages should look their own way can name a renderer for each mode:
renderers: copy: setup: cd tools/pdf && npm ci # once, before rendering run: node tools/pdf/copy.mjs # called as: <run> <file> --mode --title --round --date --out <dir> files: [tools/pdf/copy.mjs] # its own files: a change to them sends every copy againrun is required. It runs from the repo’s root and must print, as its last line, {"pdf": "<path>", "pages": <n>}. A copy’s renderer may add "to": "<folder>/<name>.pdf" (under the documents folder) to name the copy itself, and a proof’s may add "done_page". A copy is never renamed once it’s on the device, so a renderer that names copies must keep giving the same name. Freehand still writes the record and the snapshot.
drive: root: {path: Supernote/Document} # the documents folder; this is the default proofs: {path: Supernote/Document/proofs, id: <folder id>} copies: {path: Supernote/Document/study, id: <folder id>} folders: # other known folders, full paths - {path: Supernote/Document/articles, id: <folder id>}A copy goes into the nearest known folder, and any missing folders below it are made.
What a send leaves behind
Section titled “What a send leaves behind”Freehand writes freehand/paper.json in the repo: each copy’s fingerprint and each title’s last round, so a copy goes again only when something changed. With placed_by: workflow, the workflow commits it. With local, it writes the file and leaves committing to you.