Artifact b56a5c6f9c062542cb77586fff471e32602260ad9129f1471d09ca37088234a5:
- File
README.md
— part of check-in
[0ae7fb2622]
at
2026-07-08 21:53:01
on branch trunk
— Scaffold zit: Zig project + RFC references + module layout
Fossil-in-Zig, ported from the four RFC drafts (docs/rfcs/). Layout mirrors the RFC layering: delta -> artifact -> repostate -> sync. delta int codec + checksum and artifact naming/Z-card implemented with RFC-derived test vectors; everything else stubbed against its section. Builds clean; zig build test green. See docs/HANDOFF.md. (user: dmestas, size: 1930) [annotate] [blame] [check-ins using]
zit
A Fossil version-control system implemented in Zig — a direct port of the Fossil formats and protocol from their specifications.
zit is driven by four companion Internet-Drafts (the frozen reference finals
are in docs/rfcs/):
| Module | RFC | What it specifies |
|---|---|---|
delta |
draft-fossil-delta-format-00 |
byte-level delta encoding |
artifact |
draft-fossil-artifact-format-00 |
manifest / control-artifact card format, naming, checksums |
repostate |
draft-fossil-repo-state-00 |
derived branch / tag / leaf / current-trunk views |
sync |
draft-fossil-sync-protocol-00 |
HTTP sync / clone protocol |
Implementation follows the RFC dependency layering:
delta -> artifact -> repostate -> sync
Scope
zit targets the version-control substrate: the check-in (manifest), cluster, and tag/control artifact types. The collaboration types (wiki, ticket, forum, attachment, technote) are carried opaquely — stored and transported by hash, but not interpreted.
Build
Requires Zig 0.16+.
zig build # build the `zit` binary into zig-out/bin/
zig build run -- version
zig build test # run unit tests
Status
Scaffold. Implemented so far:
delta: base-64 integer codec (MSB-first) and the checksum (mod 2³²), each with RFC-derived test vectors.artifact: artifact naming (SHA-1 / SHA3-256, lowercase hex) and the Z-card MD5, with the RFC's own example vectors as tests.
Everything else is stubbed against its RFC section. Work proceeds test-first, one RFC rule at a time, verifying against the reference implementation (fossil 2.28) where a byte-exact check is possible.
Source control
This project is itself under Fossil. The repository lives in .zit.fossil
(ignored); open a checkout with fossil open --keep .zit.fossil.