1
Fork 0
mirror of https://github.com/thegeneralist01/archivr synced 2026-07-21 18:55:36 +02:00

docs: document runtime entrypoints

This commit is contained in:
TheGeneralist 2026-06-21 19:22:59 +02:00
parent b56c969624
commit 44c17eee3d
Signed by: thegeneralist01
SSH key fingerprint: SHA256:pp9qddbCNmVNoSjevdvQvM5z0DHN7LTa8qBMbcMq/R4
2 changed files with 77 additions and 0 deletions

View file

@ -57,6 +57,40 @@ label = "Personal"
archive_path = "/path/to/archive/.archivr"
```
## How To Run It
There are two user-facing binaries:
| Binary | Purpose |
|---|---|
| `archivr` | CLI for initializing archives and capturing material into one archive |
| `archivr-server` | Web server for browsing one or more existing archives |
The CLI writes archive data:
```sh
nix run .#archivr -- init ./my-archive --name "My Archive"
nix run .#archivr -- archive file:///absolute/path/to/file.pdf
```
The server reads archive data:
```sh
nix run .#archivr-server -- ./archivr-server.toml
```
If no config path is passed, the server reads `./archivr-server.toml`.
The config is a server registry, not archive data:
```toml
[[archives]]
id = "personal"
label = "Personal"
archive_path = "/absolute/path/to/my-archive/.archivr"
```
The packaged Nix server wrapper sets `ARCHIVR_STATIC_DIR` so the server can find the installed web UI assets. Source-tree runs do not need that variable because they fall back to `crates/archivr-server/static`.
## Write Data Flow
When archiving something through the CLI: