codebase-snapshot 0.20.9 → 0.20.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +64 -6
- package/README.md +20 -17
- package/SECURITY.md +0 -1
- package/dist/bin.js +5982 -4752
- package/dist/{chunk-SU6YGIQT.js → chunk-GNVRD7XS.js} +8256 -7065
- package/dist/cli.cjs +8099 -6875
- package/dist/cli.d.cts +2 -2
- package/dist/cli.d.ts +2 -2
- package/dist/cli.js +51 -18
- package/dist/{generate-worker--m4IM5zj.d.ts → generate-worker-CRMESc0b.d.ts} +9 -9
- package/dist/{generate-worker-DfNd8f67.d.cts → generate-worker-DMzNbsAW.d.cts} +9 -9
- package/dist/index.cjs +8665 -7466
- package/dist/index.d.cts +56 -40
- package/dist/index.d.ts +56 -40
- package/dist/index.js +1 -1
- package/dist/mcp.cjs +2249 -7440
- package/dist/mcp.d.cts +17 -8
- package/dist/mcp.d.ts +17 -8
- package/dist/mcp.js +1 -1
- package/dist/{types-D2_K7jfI.d.ts → types-C5ytHMYz.d.cts} +2 -0
- package/dist/{types-D2_K7jfI.d.cts → types-C5ytHMYz.d.ts} +2 -0
- package/docs/benchmarks.md +9 -6
- package/docs/budget.md +3 -2
- package/docs/cli.md +24 -22
- package/docs/configuration.md +18 -17
- package/docs/deploy.md +2 -2
- package/docs/health.md +1 -1
- package/docs/how-to-feed-a-repo-to-claude.md +8 -11
- package/docs/mcp.md +55 -33
- package/docs/migration.md +47 -43
- package/docs/output.md +2 -1
- package/docs/security-review.md +46 -8
- package/docs/vs-gitingest.md +2 -2
- package/docs/vs-repomix.md +7 -6
- package/docs/workspace.md +4 -2
- package/package.json +2 -1
package/docs/migration.md
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
|
-
# Migrating
|
|
1
|
+
# Migrating to 0.20.13
|
|
2
2
|
|
|
3
3
|
Nothing was removed. Every command, flag, config key and MCP tool that existed in 0.12.14 still
|
|
4
|
-
works
|
|
5
|
-
|
|
4
|
+
works. This page maps what was added and the behaviour changes that matter when upgrading an old
|
|
5
|
+
checkout, config or snapshot.
|
|
6
6
|
|
|
7
7
|
## New commands
|
|
8
8
|
|
|
9
9
|
| Command | Since | What it does |
|
|
10
10
|
| :--- | :--- | :--- |
|
|
11
|
-
| `snapshot health` | 0.12.15 | Audits the written snapshot: hashes, artifacts, secrets, host paths, tokens, freshness, signature. `--strict`, `--format json`. |
|
|
11
|
+
| `snapshot health` | 0.12.15 | Audits the written snapshot: hashes, artifacts, secrets, host paths, tokens, freshness, signature. `--strict`, `--format json`, `--deep`, `--all-members`. |
|
|
12
12
|
| `snapshot serve` | 0.12.19 | A browser page to generate, preview and download a snapshot; MCP on the same port. |
|
|
13
13
|
| `snapshot mcp --http` | 0.12.18 | MCP over Streamable HTTP instead of stdio; `GET /sse` for legacy clients since 0.12.29. |
|
|
14
|
+
| `snapshot update` | 0.18.0 | Bypasses the update cache, prints the registry answer, exits 0 current / 1 newer / 2 unreachable. |
|
|
14
15
|
|
|
15
16
|
## New `generate` flags
|
|
16
17
|
|
|
@@ -18,7 +19,7 @@ added, so a reader can find the feature they need without reading a hundred chan
|
|
|
18
19
|
| :--- | :--- | :--- |
|
|
19
20
|
| `--remote <url>` | 0.12.20 | Shallow, SSRF-safe clone of a public repository; provenance in the manifest. |
|
|
20
21
|
| `--ref <branch>` | 0.12.20 | Branch or tag for `--remote`. |
|
|
21
|
-
| `--allow-private` | 0.12.20 |
|
|
22
|
+
| `--allow-private` | 0.12.20 | Explicit override for private addresses and `file:` URLs. |
|
|
22
23
|
| `--keep-clone` | 0.12.20 | Keep the temporary clone. |
|
|
23
24
|
| `--include-diffs` | 0.12.24 | `reports/diff.md` from the uncommitted diff. |
|
|
24
25
|
| `--include-logs <n>` | 0.12.24 | `reports/log.md` with the last n commits. |
|
|
@@ -26,7 +27,7 @@ added, so a reader can find the feature they need without reading a hundred chan
|
|
|
26
27
|
| `--delta <path>` | 0.12.25 | Only what changed since a base snapshot, plus its importers. |
|
|
27
28
|
| `--slice "<question>"` | 0.12.26 | Only what the retrieval planner picks for a question. |
|
|
28
29
|
| `--slice-tokens <n>` | 0.12.26 | The slice budget (default 30000). |
|
|
29
|
-
| `--pack single
|
|
30
|
+
| `--pack single|xml|json` | 0.12.31 | One full-repository file in the chosen shape. |
|
|
30
31
|
| `--sign` | 0.12.32 | Ed25519 signature over the manifest. |
|
|
31
32
|
| `--budget-tokens <n>` | 0.12.33 | Fit the repository into a token budget by selecting whole files. |
|
|
32
33
|
|
|
@@ -35,53 +36,56 @@ added, so a reader can find the feature they need without reading a hundred chan
|
|
|
35
36
|
| Key | Since | Notes |
|
|
36
37
|
| :--- | :--- | :--- |
|
|
37
38
|
| `artifacts.diff`, `artifacts.log`, `artifacts.tokenTree` | 0.12.24 | Default `false`. `--skip-artifacts` still wins. |
|
|
38
|
-
| `logCount` | 0.12.24 | 1
|
|
39
|
+
| `logCount` | 0.12.24 | 1-500, default 20. |
|
|
39
40
|
| `pack` | 0.12.31 | `single`, `xml` or `json`; unset keeps the monolith pair. |
|
|
41
|
+
| `discovery` | 0.13.x | `auto`, `git` or `walk`; recorded in the config digest. |
|
|
42
|
+
| `maxParts` | 0.16.x | Grow the part budget until the snapshot has at most this many parts. |
|
|
40
43
|
|
|
41
44
|
## MCP
|
|
42
45
|
|
|
43
|
-
Tools went from eight to
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
`
|
|
47
|
-
|
|
46
|
+
Tools went from eight to **26**: health, budget, history, tests, workspace, entrypoints,
|
|
47
|
+
neighbors, routes, cycles, search, stats, review, diff_context, symbol, context, query,
|
|
48
|
+
plan_for, answer, plan, generate, validate, locate, dependents, read, explain and status.
|
|
49
|
+
Prompts went from two (`orient`, `keep-current`) to seven (`audit`, `review`, `explain`,
|
|
50
|
+
`onboard`, `security-review` were added). Resources gained `snapshot://prompt` and the three
|
|
51
|
+
opt-in reports.
|
|
48
52
|
|
|
49
|
-
|
|
50
|
-
|
|
53
|
+
stdio is still the default. `--http` adds Streamable HTTP with a bearer token and a loopback
|
|
54
|
+
bind; `--no-auth` is refused on a non-loopback bind. The page and the MCP endpoint can share
|
|
51
55
|
one port with `serve`.
|
|
52
56
|
|
|
53
|
-
##
|
|
57
|
+
## 0.18.0 to 0.20.13: what changed
|
|
54
58
|
|
|
55
|
-
|
|
56
|
-
flags change the artifact selection the manifest records, so passing them is required to compare
|
|
57
|
-
like with like. Before, a snapshot generated with one of them reported a selection mismatch.
|
|
58
|
-
2. **npm publishes only at `x.y.0`** (0.12.16 onward). Every patch is committed, tagged and pushed;
|
|
59
|
-
the registry carries `0.13.0`, `0.14.0`, … so `latest` stays a milestone rather than a patch. If
|
|
60
|
-
you pin an exact patch version, install from the git tag or build from source until the next
|
|
61
|
-
minor.
|
|
62
|
-
|
|
63
|
-
## What changed after 0.12.x
|
|
64
|
-
|
|
65
|
-
The line from `0.13.0` to `0.17.0` added checks and two tools; it removed nothing. What a reader
|
|
66
|
-
upgrading across those milestones should know:
|
|
67
|
-
|
|
68
|
-
| Change | Since | Why it matters to you |
|
|
59
|
+
| Change | Since | Why it matters |
|
|
69
60
|
| :--- | :--- | :--- |
|
|
70
|
-
|
|
|
71
|
-
|
|
|
72
|
-
|
|
|
73
|
-
|
|
|
74
|
-
|
|
|
75
|
-
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
61
|
+
| `snapshot update` and a corrected update cache | 0.18.0, 0.20.0 | The command bypasses the cache; a failed check is remembered for five minutes, not an hour. |
|
|
62
|
+
| `health` recognises its own redaction marker and scans parts per section | 0.18.2, 0.19.0 | A clean snapshot no longer scores 70 for leaks that do not exist. The remaining host-path warning is documentation examples, not a credential. |
|
|
63
|
+
| The audit verifies snapshot claims, not only hashes | 0.20.1, 0.20.2 | Artifact counts, bodies, packs and workspace indexes are recomputed; a hand-edited snapshot fails. |
|
|
64
|
+
| `health` skips a secret check in linear time | 0.20.3 | A large skipped-secret set no longer re-reads the snapshot per token. |
|
|
65
|
+
| Security hardening across CLI, scanner, redaction, MCP, serve and remote | 0.20.4-0.20.12 | CodeQL, audit and live-verdict findings: path confinement, redaction continuations, rate limiting, 413 flushing, part-size caps, IPv6 remote parsing, git/walk parity and clone cleanup. |
|
|
66
|
+
| MCP 2026-07-28 transport conformance | 0.20.13 | Required HTTP routing headers and header/body agreement, cache hints on every cacheable result, `-32602` for a missing modern resource, and stateless handling of `mcp-session-id`. Official v2 client tests cover modern stdio and HTTP. |
|
|
67
|
+
|
|
68
|
+
## Behaviour changes to know
|
|
69
|
+
|
|
70
|
+
1. **`validate` accepts `--include-diffs`, `--include-logs` and `--token-tree`** (0.12.28).
|
|
71
|
+
Those flags change the artifact selection the manifest records, so pass the same flags to
|
|
72
|
+
compare like with like.
|
|
73
|
+
2. **The 0.20 line is published in place.** Every 0.20.x patch is committed, tagged and may be
|
|
74
|
+
published; earlier lines published only at `x.y.0`. Pin an exact version when the same build
|
|
75
|
+
must run everywhere.
|
|
76
|
+
3. **The 0.20.12 HTTP/MCP limits are stricter.** Empty JSON-RPC batches are invalid, oversized
|
|
77
|
+
bodies return 413 before the socket closes, and content tools refuse a part above 16 MiB.
|
|
78
|
+
4. **The 0.20.13 modern transport is stricter.** A `2026-07-28` HTTP request must carry
|
|
79
|
+
`MCP-Protocol-Version`, `Mcp-Method` and, for named calls, `Mcp-Name`; a mismatch is
|
|
80
|
+
refused before dispatch instead of being silently routed on the body. Modern cacheable
|
|
81
|
+
results carry `ttlMs: 0` and `cacheScope: "private"`, and a missing resource is `-32602`.
|
|
82
|
+
|
|
83
|
+
`validate` on a snapshot written by an older version still works: newer manifest keys are
|
|
80
84
|
optional, and an artifact the manifest does not record is not required to exist.
|
|
81
85
|
|
|
82
86
|
## If you are on an older 0.12.x
|
|
83
87
|
|
|
84
|
-
Upgrade to the latest 0.12.x first; every change since 0.12.14 is a patch on the same line, and
|
|
85
|
-
configuration file format has not changed. Run `snapshot health` after the first generate on
|
|
86
|
-
version
|
|
87
|
-
would refuse.
|
|
88
|
+
Upgrade to the latest 0.12.x first; every change since 0.12.14 is a patch on the same line, and
|
|
89
|
+
the configuration file format has not changed. Run `snapshot health` after the first generate on
|
|
90
|
+
the new version - it is the fastest way to see whether an old snapshot carries anything the
|
|
91
|
+
newer checks would refuse.
|
package/docs/output.md
CHANGED
|
@@ -335,7 +335,8 @@ Reasons, and what each one means:
|
|
|
335
335
|
| `reason` | The file was dropped because |
|
|
336
336
|
| :--- | :--- |
|
|
337
337
|
| `excluded` | It matched your own `excludePatterns`, or fell outside a non-empty `include` allow-list. |
|
|
338
|
-
| `default-ignore` | A built-in rule caught it, the preset's ecosystem ignores did (`node_modules`, `__pycache__`, `target`, …)
|
|
338
|
+
| `default-ignore` | A built-in rule caught it, or the preset's ecosystem ignores did (`node_modules`, `__pycache__`, `target`, …). |
|
|
339
|
+
| `tool-output` | The path sits under a directory carrying a complete .codebase-snapshot marker. It is a prior snapshot, recorded rather than silently dropped; the configured outDir/tmpDir for this run is silent bookkeeping and never appears here. |
|
|
339
340
|
| `sensitive-file` | Its name is credential-bearing (`.env`, `*.pem`, `.npmrc`, …). |
|
|
340
341
|
| `sensitive-path` | The path itself matched a secret rule. The file is skipped and the path is masked in every artifact. |
|
|
341
342
|
| `binary` | It is not text: it holds a NUL byte outside a UTF-16 stream, or more than 1% control characters (a 4 KB blob of `0x07` is valid UTF-8 but is not text). `detail` carries the size and, when there is one to give, the reason: the control-byte count (`Size: 13 B; 5 control byte(s)`), or the offset of a NUL found past the 8 MB head scan (`Size: 9000010 B; NUL byte at offset 9000000`). A NUL inside the head scan is caught by the cheap extension-and-prefix check, so its `detail` is the size alone. |
|
package/docs/security-review.md
CHANGED
|
@@ -33,10 +33,11 @@ untrusted input can arrive.
|
|
|
33
33
|
- **A symlink is only a second name for included content.** The target must survive the same
|
|
34
34
|
include/exclude/ignore filters as the link alias; `.git/config` cannot be reached through a
|
|
35
35
|
tracked `notes.txt`.
|
|
36
|
-
- **Every snapshot file read is confined.** PROMPT.md, reports, the manifest
|
|
37
|
-
are opened through one reader that refuses a symlink and requires the canonical
|
|
38
|
-
the snapshot directory. The MCP resources, `snapshot_history`,
|
|
39
|
-
`serve` use it;
|
|
36
|
+
- **Every snapshot file read is confined.** PROMPT.md, reports, the manifest, WORKSPACE.json and
|
|
37
|
+
signature.json are opened through one reader that refuses a symlink and requires the canonical
|
|
38
|
+
target inside the snapshot directory. The MCP resources, `snapshot_history`,
|
|
39
|
+
`snapshot_workspace`, signing verification and `serve` use it; a part lookup also requires its
|
|
40
|
+
`parts/` directory and the resolved part to stay inside the snapshot.
|
|
40
41
|
- **The diff report fails closed.** Git is forced to emit unquoted ASCII prefixes, a section that
|
|
41
42
|
cannot be attributed to a path is omitted rather than trusted, redaction runs before truncation
|
|
42
43
|
with the diffed file's extension, and `--only` applies to the diff too.
|
|
@@ -56,12 +57,19 @@ executable config in it is refused, because a fetched repository is not a truste
|
|
|
56
57
|
`--no-auth` is refused on a non-loopback bind.
|
|
57
58
|
- **Constant-time** token comparison; the token is generated with `crypto.randomBytes`.
|
|
58
59
|
- **CORS only for loopback origins** and explicit `--allow-origin` values; everything else is 403.
|
|
60
|
+
The allowed request headers include `Mcp-Method` and `Mcp-Name` so a browser can send the
|
|
61
|
+
modern routing headers.
|
|
62
|
+
- **Header/body agreement.** A modern request is refused with HTTP 400 and `-32020` when
|
|
63
|
+
`MCP-Protocol-Version`, `Mcp-Method` or `Mcp-Name` is missing or disagrees with the parsed
|
|
64
|
+
body. Routing decisions cannot be made from a header the handler did not verify against the
|
|
65
|
+
value it executes.
|
|
59
66
|
- **Bounded work**: 2 MiB bodies, 60 requests per 10 s per address, one JSON document per response,
|
|
60
67
|
and at most four MCP tool calls in flight across all HTTP sessions. The session and rate maps are
|
|
61
68
|
capped and evicted, so a client cannot grow either without bound.
|
|
62
69
|
- **Untrusted regexes are bounded.** `snapshot_search`, `snapshot_routes` and `snapshot_query`
|
|
63
|
-
reject nested quantifiers, more than one unbounded repetition
|
|
64
|
-
before compiling;
|
|
70
|
+
reject nested quantifiers, more than one unbounded repetition, optional-chain blowups and
|
|
71
|
+
backreferences before compiling; glob and gitignore patterns are bounded by wildcard, brace and
|
|
72
|
+
alternative counts. JavaScript has no regex timeout, so the alternative is a main-thread stall.
|
|
65
73
|
- **Errors are JSON-RPC error objects**, never stack traces.
|
|
66
74
|
|
|
67
75
|
### The browser page
|
|
@@ -69,7 +77,8 @@ executable config in it is refused, because a fetched repository is not a truste
|
|
|
69
77
|
- The page is HTML and is served without a token; **every API call requires one**. The token is not
|
|
70
78
|
baked into the HTML, so serving `/` cannot leak it.
|
|
71
79
|
- A request with a cross-origin `Origin` is refused before any auth check.
|
|
72
|
-
- `api/snapshot.zip` only
|
|
80
|
+
- `api/snapshot.zip` zips only the parts, artifacts and signature the manifest declares; a
|
|
81
|
+
directory with a PWA `manifest.json` and an arbitrary file is refused.
|
|
73
82
|
- Every path is resolved with `realpath` before the allowed-root check, so a symlink inside the
|
|
74
83
|
served directory cannot read or zip a target outside it. `POST /api/generate` applies the same
|
|
75
84
|
check to its local source and to the `outDir` it is about to write; a remote clone's
|
|
@@ -111,7 +120,7 @@ to treat file content as data. This is a real, documented limitation, not a solv
|
|
|
111
120
|
|
|
112
121
|
## What changed since this review was written
|
|
113
122
|
|
|
114
|
-
The review was written at 0.12.34. Between then and 0.
|
|
123
|
+
The review was written at 0.12.34. Between then and 0.20.13 the surfaces it covers grew; each
|
|
115
124
|
addition was reviewed with the same question — what new input arrives, and what does it reach?
|
|
116
125
|
|
|
117
126
|
- **`GET /metrics`** (0.13.3) publishes counters with a fixed label set. Repo paths, tokens and
|
|
@@ -132,6 +141,32 @@ addition was reviewed with the same question — what new input arrives, and wha
|
|
|
132
141
|
catastrophic MCP regexes are refused before compilation, HTTP tool concurrency is bounded,
|
|
133
142
|
failed clones are removed, workspace dry runs write nothing, staged validation reads the index,
|
|
134
143
|
and hook installation refuses a symlink or hard link.
|
|
144
|
+
- **The 0.20.10 third audit** closed the remaining gaps: parts-directory and configured
|
|
145
|
+
`outDir`/`tmpDir` escapes are refused; WORKSPACE/signature reads are confined; PEM quote
|
|
146
|
+
tracking, template literals, YAML block scalars, Dockerfile variants and diff prefixes are
|
|
147
|
+
redacted; optional-quantifier and backreference ReDoS and exponential globs are refused;
|
|
148
|
+
MCP era probes, CORS session exposure, whole-response caps, explicit false overrides and an
|
|
149
|
+
empty-first-line read are fixed; validation distinguishes replaced files and skipped paths from
|
|
150
|
+
drift; MCP runs health/validate/review/explain in a worker, and `serve` zips only manifest
|
|
151
|
+
inventory and runs its health audit and remote clone without blocking request handling.
|
|
152
|
+
- **The 0.20.11 fourth audit** closed cross-path twins: a nested ownership marker is recorded
|
|
153
|
+
as `tool-output` instead of vanishing; Dockerfile redaction is re-scan idempotent; quoted
|
|
154
|
+
credentials and unterminated PEM bodies have no length/prefix blind spot; alternation and glob
|
|
155
|
+
branch budgets bound the event loop; workspace members inherit every generation flag;
|
|
156
|
+
`validate` agrees with `--skip-artifacts parts`; HTTP batches are charged per message and
|
|
157
|
+
batched `initialize` mints a session; `snapshot_symbol` is bounded; explicit false overrides
|
|
158
|
+
reach validation; `..notes.ts` is accepted at the segment boundary; `health --all-members`
|
|
159
|
+
confines the index and members; `serve` rejects non-HTTP loopback origins and records nested
|
|
160
|
+
repository roots; and report fences grow with their content.
|
|
161
|
+
- **The 0.20.12 live verdict** executed the fourth audit's hypotheses against the built CLI: HTTP
|
|
162
|
+
envelopes are charged before parsing and empty batches are invalid; Dockerfile continuations
|
|
163
|
+
are masked before per-line rules; content tools refuse parts above 16 MiB; `serve` answers 404
|
|
164
|
+
for a missing local source and cleans an in-flight clone on close; IPv6 remote literals parse;
|
|
165
|
+
`**` counts as one wildcard and brace products are bounded; and the describe contract, tool
|
|
166
|
+
annotations and documentation statements were corrected where the source disagreed.
|
|
167
|
+
- **The 0.20.13 MCP conformance pass** checked the modern Streamable HTTP rules against the
|
|
168
|
+
published revision and the official v2 client: header/body agreement, cache fields and
|
|
169
|
+
resource errors.
|
|
135
170
|
|
|
136
171
|
The residual risks below are unchanged, including the two that are deliberate rather than solved.
|
|
137
172
|
|
|
@@ -143,11 +178,14 @@ The residual risks below are unchanged, including the two that are deliberate ra
|
|
|
143
178
|
| Redaction masks the span only | redaction suite (hundreds of cases) |
|
|
144
179
|
| Health catches a leaked secret and never echoes it | `tests/health.test.js` |
|
|
145
180
|
| HTTP: 401 without token, 403 cross-origin, 413 oversize, 400 bad JSON | `tests/mcp-http.test.js` |
|
|
181
|
+
| Modern HTTP: required headers, mismatch 400/-32020, cache fields, -32602, CORS | `tests/mcp-modern-http.test.js` |
|
|
182
|
+
| Official MCP v2 client: modern stdio and modern HTTP, discovery, tools, resources | `tests/mcp-sdk-interop.test.js` |
|
|
146
183
|
| SSE: token required, unknown session 404, shutdown does not hang | `tests/mcp-http.test.js` |
|
|
147
184
|
| Remote: private addresses refused, credentials in URL refused, `file:` gated | `tests/remote-source.test.js` |
|
|
148
185
|
| Serve: page without token, API with token, zip restricted | `tests/web-serve.test.js` |
|
|
149
186
|
| Signature: tamper detected | `tests/signing.test.js` |
|
|
150
187
|
| Second 0.20 audit: symlink targets, auth case, diff quoting, brief headings, ReDoS, HTTP cap, workspace dry run, staged validation, hook links | `tests/audit-0-20-5-ultimate.test.js` |
|
|
188
|
+
| Fourth 0.20 audit: marker visibility, Dockerfile re-scan, long quoted secrets, unterminated PEM, alternation/glob budgets, workspace flags, skip-parts validation, HTTP batching, symbol cap, false overrides, `..notes.ts`, CLI workspace confinement, serve origin/fences | `tests/audit-0-20-11-followup.test.js` |
|
|
151
189
|
|
|
152
190
|
## Residual risks, stated
|
|
153
191
|
|
package/docs/vs-gitingest.md
CHANGED
|
@@ -31,11 +31,11 @@ If you want to paste a repo into a chat right now: **use gitingest.**
|
|
|
31
31
|
| Excluded-file accounting | Every skipped path recorded with a reason | Ignore rules applied |
|
|
32
32
|
| Secret redaction | 32 default rules, value-span masking, audit table | Relies on ignore rules |
|
|
33
33
|
| Runtime | Node.js | Python |
|
|
34
|
-
| Repo URL input |
|
|
34
|
+
| Repo URL input | **Yes** — `generate --remote` (Node + git; `file://` needs `--allow-private`) | **Yes** — zero install |
|
|
35
35
|
|
|
36
36
|
## Where gitingest is the better choice
|
|
37
37
|
|
|
38
|
-
- **You have not installed anything and do not want to.**
|
|
38
|
+
- **You have not installed anything and do not want to.** This tool needs Node and git, so a hosted URL box is still the shortest path.
|
|
39
39
|
- **You want one digest, not parts.** If the destination is a chat window, one blob is the right
|
|
40
40
|
shape.
|
|
41
41
|
- **You are in Python.** `pip install gitingest` fits an existing pipeline without adding a Node
|
package/docs/vs-repomix.md
CHANGED
|
@@ -28,7 +28,7 @@ If you want the most popular, most integrated tool: **use repomix.**
|
|
|
28
28
|
| Size control | **Yes** — `maxPartBytes` is a per-part byte ceiling; a file that cannot fit one part becomes a head/tail preview listed in `incomplete[]` | `--split-output <size>` splits by output size, and `--token-budget <n>` exits non-zero above a token count |
|
|
29
29
|
| Reproducible output | Parts are byte-identical across runs; a fingerprint covers them | Content is stable; no published determinism guarantee |
|
|
30
30
|
| Staleness check | `validate` re-hashes the repository and exits non-zero on drift | Not a feature |
|
|
31
|
-
| Remote repositories |
|
|
31
|
+
| Remote repositories | **Yes** — `--remote` clones an HTTPS URL (or `file://` with `--allow-private`); git is required | **Yes** — packs a GitHub URL directly |
|
|
32
32
|
| MCP server | **Yes** — 26 tools over stdio, and it serves the validated snapshot rather than the working tree | **Yes** — packs a repository, including by URL |
|
|
33
33
|
| Secret handling | 32 default rules, value-span masking, per-line audit table | Secretlint integration |
|
|
34
34
|
| Language awareness | 25 presets, AST or structural summaries labelled by confidence | Tree-sitter parsing with a compression mode |
|
|
@@ -39,11 +39,12 @@ If you want the most popular, most integrated tool: **use repomix.**
|
|
|
39
39
|
|
|
40
40
|
- **You want one file.** Pasting a single artifact into a chat is simpler than assembling parts, and
|
|
41
41
|
repomix is built around that workflow.
|
|
42
|
-
- **You
|
|
43
|
-
|
|
44
|
-
- **You want MCP
|
|
45
|
-
serves
|
|
46
|
-
|
|
42
|
+
- **You want a zero-install URL box.** repomix can pack a GitHub URL without a local checkout;
|
|
43
|
+
this project needs Node and git for `--remote`, and its browser page still runs locally.
|
|
44
|
+
- **You want MCP to fetch a URL on demand.** repomix's server can pack a repository by URL. This
|
|
45
|
+
project's MCP server serves local roots and refuses to read outside them; remote fetching is a
|
|
46
|
+
CLI/page action (`--remote`), not a read tool. Both ship a server; ours is narrower on purpose,
|
|
47
|
+
and it can tell the agent whether the snapshot it is reading is still current.
|
|
47
48
|
- **You want the ecosystem.** More stars, more tutorials, more people who have already hit your
|
|
48
49
|
problem.
|
|
49
50
|
- **Your limit is a token count, not a byte count.** `--token-budget <n>` fails the run when the
|
package/docs/workspace.md
CHANGED
|
@@ -70,8 +70,10 @@ directory configured if the member should be served on its own.
|
|
|
70
70
|
## Rules
|
|
71
71
|
|
|
72
72
|
- **Defaults, not member configs.** A member may contain a `snapshot.config.ts`, and a config can run
|
|
73
|
-
code. A workspace is a set of repositories the caller named, not one they configured, so
|
|
74
|
-
|
|
73
|
+
code. A workspace is a set of repositories the caller named, not one they configured, so member
|
|
74
|
+
config files are ignored. The flags the caller passed to the workspace run (budget, compression,
|
|
75
|
+
scope, artifact selection, discovery) are still applied to every member. Run the member directly
|
|
76
|
+
if its own config should apply.
|
|
75
77
|
- **A failure is reported, not skipped.** A missing member prints its name and the run exits `1`
|
|
76
78
|
after writing the members that succeeded, so a partial workspace is never mistaken for a complete
|
|
77
79
|
one.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codebase-snapshot",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.13",
|
|
4
4
|
"description": "Turn a repository into LLM-ready Markdown under a hard byte budget: a manifest of every included and skipped file, secret redaction, drift validation, and an MCP server for Claude, ChatGPT and Cursor.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"codebase-snapshot",
|
|
@@ -127,6 +127,7 @@
|
|
|
127
127
|
"esbuild": "^0.28.1"
|
|
128
128
|
},
|
|
129
129
|
"devDependencies": {
|
|
130
|
+
"@modelcontextprotocol/client": "^2.4.0",
|
|
130
131
|
"@types/node": "^22.0.0",
|
|
131
132
|
"marked": "^18.1.3",
|
|
132
133
|
"tsup": "^8.3.0"
|