@svartz/plugin-submissions/restore
6 exported symbols.
Interfaces
| i Restore | One page's content to commit back. |
| i Restorer | Commits for one request. Make one per request with `restorer`. |
Types
| t Restored | What `Restorer.restore` did: committed, or why not. `unchanged` when the branch already held the content, `changed` when its file isn't the one the caller read, `protected` when a rule for the branch refuses the commit, `busy` when the branch moved on meanwhile. Only `commit` moved the branch. |
| t RouteClaims | The routes the last build allocated, which a note's frontmatter can claim: JSON, for server data. |
Functions
| f commitAttribution | The account a commit is authored as, with its linked GitHub account as co-author, and the App's bot that commits it. |
| f restorer | Restores a vault's pages. Only a GitHub App commits as an account, so with a token `commits` is false and every restore throws. `token` shares a `sourceToken` with the vault's commit reader. |