export
rigger export <PROJECT> --hub <DIR> [--check] [--adopt] [--json]Generates a project’s hub from the record. The plan, the changelog and the diary are views of what the database holds, so this is the other half of import: the record is read once, written by hand no more, and the notes follow it.
$ rigger export sample --hub C:\dev\sample\hub План.md written 357 bytes Изменения.md written 258 bytes Дневник.md written 156 bytes
sample wrote 3 of 3 files.What it writes, and what it never touches
Section titled “What it writes, and what it never touches”| File | Where it comes from |
|---|---|
План.md |
versions not yet shipped, their tasks, and the owner’s open questions |
Изменения.md |
versions that shipped, newest first, with what was written about each |
Дневник.md |
one entry per sitting, newest first |
Nothing else in the hub is generated. The vision, the prose of the decision log and the research notes are written by a person and stay that way - the record has no opinion about them, so it cannot rewrite them. Every generated file opens with a marker saying so:
<!-- generated by rigger; edits here are overwritten -->Taking a handwritten file over
Section titled “Taking a handwritten file over”A hub that has been kept by hand for months is not overwritten because a command was typed. The first export refuses, and says which way out is which:
$ rigger export sample --hub C:\dev\sample\huberror: C:\dev\sample\hub\План.md was written by hand and the record does not own it yet.Check what would change with `--check`, then hand it over with `--adopt`.--check writes nothing and reports what would change - it works on a handwritten hub for exactly that reason:
$ rigger export sample --hub C:\dev\sample\hub --check План.md would change 357 bytes Изменения.md would change 258 bytes Дневник.md would change 156 bytes
3 of 3 files differ from the record.--adopt hands the files over, once and on purpose. After that the record owns them and a plain export keeps them current.
Running it twice
Section titled “Running it twice”An export of an unchanged record writes nothing and says so, byte for byte:
$ rigger export sample --hub C:\dev\sample\hub План.md unchanged 357 bytes Изменения.md unchanged 258 bytes Дневник.md unchanged 156 bytes
C:\dev\sample\hub is already what the record says.That stability is a test, not a hope: the same record generates the same bytes, and a file is rewritten only when the record behind it changed.
What the record keeps so a hub survives the trip
Section titled “What the record keeps so a hub survives the trip”A hub is prose with structure in it, and most of what a person wrote is neither a version number nor a task. So the record keeps the shape as well as the substance: the heading exactly as it was written, how deep it sat, which block it belonged to, the order its stages had, the prose written before a task list and the prose written after it, the marker a question list used, and the blank lines a hub leaves around its rules. Guessing any of these rewrites a real file on every run.
The line ending is the file’s own. Every hub written on Windows is CRLF, and a generated file in LF would differ from its source on every single line - which is not a diff anybody reads.