From b74e06b66539b5e8f78c1885a29729e3bf52c81b Mon Sep 17 00:00:00 2001 From: Drake Stapleton Date: Thu, 1 Oct 2026 08:21:08 -0500 Subject: [PATCH] tools(crumb): seed skips vendor and evidence directories Third-party code and immutable evidence must not get crumb files. Co-Authored-By: Drake Stapleton Co-Authored-By: Claude Sonnet 5.5 --- docs/CRUMB_PROTOCOL.md | 1 + tools/crumb/crumb.c | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/CRUMB_PROTOCOL.md b/docs/CRUMB_PROTOCOL.md index 04d57f6..d9dbb16 100644 --- a/docs/CRUMB_PROTOCOL.md +++ b/docs/CRUMB_PROTOCOL.md @@ -39,6 +39,7 @@ Spec-faithful mapping for a lane: a lane is an agent id; "I am working here" is ``` cd tools/crumb && make && make test crumb seed # writes .crumb in the root, top-level dirs, and every dir that holds files; idempotent +# skips dot-dirs, vendor, evidence (immutable records), target, node_modules, build, dist, nested git roots ``` `seed` never overwrites a hand-written `purpose`, `invariants`, `exports`, or existing `below`/`above` entry. It owns only `extensions.seed`. diff --git a/tools/crumb/crumb.c b/tools/crumb/crumb.c index eabf3f2..192a64b 100644 --- a/tools/crumb/crumb.c +++ b/tools/crumb/crumb.c @@ -444,7 +444,7 @@ static int cmd_sniff(const char *agent, const char *dir) { /* SPEC 5.1 */ /* ---------- tree walk ---------- */ static int skip_name(const char *n) { - return n[0] == '.' || !strcmp(n, "target") || !strcmp(n, "node_modules") || !strcmp(n, "build") || !strcmp(n, "dist") || !strcmp(n, "__pycache__"); + return n[0] == '.' || !strcmp(n, "target") || !strcmp(n, "node_modules") || !strcmp(n, "build") || !strcmp(n, "dist") || !strcmp(n, "vendor") || !strcmp(n, "evidence") || !strcmp(n, "__pycache__"); } static int is_src(const char *n) { static const char *ext[] = { "c", "h", "cc", "cpp", "hpp", "S", "s", "rs", "mojo", "sh", NULL };