Milestone 1: sync engine and lunesync CLI

Rust workspace with core (watch, settle, save, sync over a plain Git
remote, keep-both on same-line edits, offline queueing, tidy) and the
lunesync CLI (device, add, run, service, status, checkpoint, tidy,
history). Tests cover byte-exact round trips, keep-both, offline
catch-up and adopting an existing vault.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-28 23:11:24 +07:00
commit 25b8be5bbd
18 changed files with 3601 additions and 0 deletions

25
CLAUDE.md Normal file
View File

@@ -0,0 +1,25 @@
# Project guardrails
Read `docs/SPEC.md` before any work. It is the single source of truth.
## The one rule that matters
Build **only the current milestone** (see SPEC §5–6). Every feature must pass the north-star test: sync you can trust, access as a lifecycle, or approachable. If it passes none, it waits — even if it seems useful.
## Working with Sen
- Sen likes big steps. Plans are few, large, user-reviewable milestones — never deep trees of sub-tasks.
- A milestone is done when its story in SPEC works when Sen acts it out. Show him how to run it.
- Decisions in SPEC §3 are settled. To change one, ask Sen, then record it in SPEC §8 with the date. Never change direction silently.
- Implementation details not covered by SPEC (crates, file layout, internal APIs) are yours to choose; mention notable ones briefly.
## Keep it small
- Docs live in two files: this one and `docs/SPEC.md`. Don't create more planning documents, status reports or evidence folders.
- No security audits, CVE sweeps, multi-arch packaging or release evidence before Milestone 7.
- No microservices, CRDTs, custom VCS, plugin systems or agent integrations.
- Tests: cover sync correctness (no lost data, conflicts keep both, byte-exact round trips). Skip ceremony.
## Product rules that are easy to break
- Never lose user data. When unsure, keep both copies.
- Never block sync waiting for a human.
- Never store secrets; never grant infrastructure access.
- Never show Git words (commit, push, merge, branch) in user-facing text.
- Only delete folders the app created (marker in `.git/`).