Markdown export mirror
lll export [DIR] writes the configured team as Markdown: one file per issue,
one per document, attachment bytes beside the issue that owns them. The default
destination is mirror/ under the current directory.
lll export mirror
rg 'regression' mirror/issues mirror/docs
Each mirror holds:
| path | what | round-trips |
|---|---|---|
issues/KEY-N.md |
YAML front matter plus the description | yes |
issues/KEY-N.comments.md |
the issue’s comments | no, export only |
issues/KEY-N/ |
attachment bytes, when the issue has any | bytes yes, names no |
docs/SLUG.md |
a document | yes, including kind, coordinates and issue links |
Front matter carries the fields the prose does not: state, priority, assignee,
project, labels, and the issue’s number and sort.
| Restore identity | Issue numbers |
|---|---|
| Superuser | Preserved, including gaps |
| Member or bot | Allocated by the server; the command prints old → new mappings |
The export is byte-stable: the same server state exported twice produces identical files, so a scheduled mirror under Git commits only real changes. Comment timestamps are absolute for the same reason (LLL-453).
Restore a mirror
lll import dir refuses a team that already has issues. --replace deletes
every issue in the team before importing. There is no merge or per-field diff.
lll import dir mirror # into a team with no issues
lll import dir mirror --replace # delete every issue in the team, then import
Editing a mirror file changes nothing on the server until import. Import
rebuilds the issues from disk. The decision record is
lll doc view issue-text-and-state-live-in-lll.
A malformed file fails the whole import with nothing written — every file is parsed before the first record is created.
Parent links use issue keys in front matter (parent: ENG-7). They are
resolved after all issues exist, so forward links and deep trees survive a
restore. Missing parents, duplicate keys and cycles refuse before any writes,
including --replace; a mirror with parents also requires server support
before replacement starts. Older files without parent restore as roots.
Restored fields
Issue numbers follow the restore-identity table above. Import restores sort
order, titles, descriptions, states, priorities, emoji, assignees, projects, labels, refs, the original creation
origin, blocked_by dependency links, documents with their kind and retrieval
coordinates, and attachment bytes. Issue links inside documents and dependency
links between issues use mirror keys, resolved to the new record ids after
every issue exists. These links survive renumbering; issue keys written inside
description text stay as written.
Fields not restored
- comments and their authorship; comments are export-only
created/updated, because a restored record is a new record and PocketBase stamps it on insert- attachment filenames, because PocketBase assigns its own stored name on upload; the bytes are identical, the name gains a suffix
- the original creator, unless the import runs with superuser
credentials.
gopb/provenance.goattributes every member-authenticated create to the member making it, so an import run by a member is recorded as filed by that member. The mirror still carries the original name for a person reading it; theoriginblock (host, path, branch, commit, tool) is restored either way. - a document’s author (LLL-618). The mirror does not carry it. The server sets it from the token, so an import by a member records that member as every document’s author, and a superuser import leaves them authorless.
Database backups
A Markdown mirror is not a database backup. It carries no record ids, no member accounts and no comment authorship. Use the hosted recovery procedure — Fly volume snapshots — for a restorable backup. This is for reading the tracker without a server, grepping it, and keeping its history in Git beside the code’s.