snapdir core library.
Manifest format, BLAKE3 merkle hashing, store trait, directory walk, and
cache live here. Per the library-purity principle, this crate performs no
terminal I/O and reads no $HOME/config/environment for behavior: inputs
arrive as parameters and errors surface as typed [thiserror] enums.
The [manifest] module owns the frozen manifest line format
(PATH_TYPE PERMISSIONS CHECKSUM SIZE PATH) and its (de)serialization. The
[merkle] module owns the directory checksum rule (sort + dedup + concat +
re-hash of the direct children's checksums), the snapshot id
([snapshot_id] — BLAKE3 of the comment-stripped manifest text, distinct
from the root directory checksum), and the [Hasher] abstraction with its
in-process [Blake3Hasher], keyed [Blake3KeyedHasher]
(SNAPDIR_MANIFEST_CONTEXT), [Md5Hasher] and [Sha256Hasher]
(--checksum-bin) implementations. The [excludes] module owns the
%system%/%common% expansion, the grep -E -v matcher, and the
follow/no-follow option semantics.