codebase-snapshot 0.20.5 → 0.20.6
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 +51 -0
- package/README.md +1 -1
- package/dist/bin.js +1532 -1037
- package/dist/{chunk-HYTY6T7P.js → chunk-E4VHKJJU.js} +32 -8
- package/dist/{chunk-C3WVC4FV.js → chunk-KPDO7W5D.js} +1194 -776
- package/dist/cli.cjs +1557 -1059
- package/dist/cli.d.cts +1 -1
- package/dist/cli.d.ts +1 -1
- package/dist/cli.js +73 -19
- package/dist/{generate-worker-CNRsO_z7.d.cts → generate-worker-CkWFKtf0.d.ts} +6 -0
- package/dist/{generate-worker-CNRsO_z7.d.ts → generate-worker-Wne8FzN5.d.cts} +6 -0
- package/dist/index.cjs +1178 -772
- package/dist/index.d.cts +6 -4
- package/dist/index.d.ts +6 -4
- package/dist/index.js +1 -1
- package/dist/mcp.cjs +470 -180
- package/dist/mcp.d.cts +2 -1
- package/dist/mcp.d.ts +2 -1
- package/dist/mcp.js +2 -2
- package/dist/{types-DnYsA6_Y.d.cts → types-CykWdR6V.d.cts} +2 -0
- package/dist/{types-DnYsA6_Y.d.ts → types-CykWdR6V.d.ts} +2 -0
- package/docs/cli.md +5 -5
- package/docs/deploy.md +2 -2
- package/docs/mcp.md +4 -4
- package/package.json +1 -1
package/dist/mcp.d.cts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export { G as GenerateSummary, W as WorkerResults, g as generateInWorker } from './generate-worker-
|
|
1
|
+
export { G as GenerateSummary, W as WorkerResults, g as generateInWorker } from './generate-worker-Wne8FzN5.cjs';
|
|
2
2
|
import { Readable, Writable } from 'node:stream';
|
|
3
|
+
import './types-CykWdR6V.cjs';
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* JSON-RPC 2.0 envelopes and the Model Context Protocol revisions this server speaks.
|
package/dist/mcp.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
export { G as GenerateSummary, W as WorkerResults, g as generateInWorker } from './generate-worker-
|
|
1
|
+
export { G as GenerateSummary, W as WorkerResults, g as generateInWorker } from './generate-worker-CkWFKtf0.js';
|
|
2
2
|
import { Readable, Writable } from 'node:stream';
|
|
3
|
+
import './types-CykWdR6V.js';
|
|
3
4
|
|
|
4
5
|
/**
|
|
5
6
|
* JSON-RPC 2.0 envelopes and the Model Context Protocol revisions this server speaks.
|
package/dist/mcp.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { generateToken, startHttpTransport } from './chunk-
|
|
2
|
-
export { ERROR_CODES, LEGACY_PROTOCOL_VERSIONS, MAX_LINE_BYTES, METHOD, MODERN_PROTOCOL_VERSIONS, REPORT_RESOURCE_URIS, RESOURCE_TEMPLATE_URIS, SERVER_INSTRUCTIONS, STATIC_RESOURCE_URIS, SUPPORTED_PROTOCOL_VERSIONS, buildPrompts, buildResourceProvider, buildTools, classifyRequest, coerceNumericStrings, createLineReader, createMcpServer, createServer, createSession, createWriter, findSection, generateInWorker, inspectModernMeta, isCommentStrippable, negotiateLegacyVersion, parsePartSections, runStdioServer, stripComments, validateArguments, windowText } from './chunk-
|
|
1
|
+
export { generateToken, startHttpTransport } from './chunk-E4VHKJJU.js';
|
|
2
|
+
export { ERROR_CODES, LEGACY_PROTOCOL_VERSIONS, MAX_LINE_BYTES, METHOD, MODERN_PROTOCOL_VERSIONS, REPORT_RESOURCE_URIS, RESOURCE_TEMPLATE_URIS, SERVER_INSTRUCTIONS, STATIC_RESOURCE_URIS, SUPPORTED_PROTOCOL_VERSIONS, buildPrompts, buildResourceProvider, buildTools, classifyRequest, coerceNumericStrings, createLineReader, createMcpServer, createServer, createSession, createWriter, findSection, generateInWorker, inspectModernMeta, isCommentStrippable, negotiateLegacyVersion, parsePartSections, runStdioServer, stripComments, validateArguments, windowText } from './chunk-KPDO7W5D.js';
|
|
@@ -239,6 +239,8 @@ interface PartMetadata {
|
|
|
239
239
|
fileCount: number;
|
|
240
240
|
layersCovered: string[];
|
|
241
241
|
includedFiles: PartFileEntry[];
|
|
242
|
+
/** The partitioner had to hard-clip the rendered part; generation refuses this rather than lie. */
|
|
243
|
+
hardClipped?: true;
|
|
242
244
|
}
|
|
243
245
|
interface SecretRule {
|
|
244
246
|
rule: string;
|
|
@@ -239,6 +239,8 @@ interface PartMetadata {
|
|
|
239
239
|
fileCount: number;
|
|
240
240
|
layersCovered: string[];
|
|
241
241
|
includedFiles: PartFileEntry[];
|
|
242
|
+
/** The partitioner had to hard-clip the rendered part; generation refuses this rather than lie. */
|
|
243
|
+
hardClipped?: true;
|
|
242
244
|
}
|
|
243
245
|
interface SecretRule {
|
|
244
246
|
rule: string;
|
package/docs/cli.md
CHANGED
|
@@ -98,7 +98,7 @@ Exit `0` when the snapshot passes its own integrity check, `1` when it does not.
|
|
|
98
98
|
|
|
99
99
|
```
|
|
100
100
|
📸 Generating snapshot for: /path/to/repo
|
|
101
|
-
Branch: main (fallback) | Part budget: 300 KB | Generator: 0.20.
|
|
101
|
+
Branch: main (fallback) | Part budget: 300 KB | Generator: 0.20.6 (project dependency ^0.20.6)
|
|
102
102
|
|
|
103
103
|
✅ Snapshot generated in 0.14s:
|
|
104
104
|
- Tracked files: 121 included of 128 paths found — 7 skipped (default-ignore 5, binary 1, sensitive-file 1); every one is listed in snapshot/reports/audit.md
|
|
@@ -223,7 +223,7 @@ The whole first run in one command, with defaults and no prompts. This is the sa
|
|
|
223
223
|
🚀 Setup for: /path/to/repo
|
|
224
224
|
✅ Created snapshot.config.ts (preset: nextjs)
|
|
225
225
|
Added npm scripts: snapshot, snapshot:validate
|
|
226
|
-
Added devDependency: codebase-snapshot ^0.20.
|
|
226
|
+
Added devDependency: codebase-snapshot ^0.20.6
|
|
227
227
|
Added to .gitignore: /snapshot/, /snapshot.tmp/
|
|
228
228
|
⏳ Installing dependencies…
|
|
229
229
|
✅ Installed dependencies (npm install, 2.1s)
|
|
@@ -275,7 +275,7 @@ It also has three side effects on files you own, and it says so when it does the
|
|
|
275
275
|
```
|
|
276
276
|
✅ Created snapshot.config.ts (preset: node-lib)
|
|
277
277
|
Added npm scripts: snapshot, snapshot:validate
|
|
278
|
-
Added devDependency: codebase-snapshot ^0.20.
|
|
278
|
+
Added devDependency: codebase-snapshot ^0.20.6
|
|
279
279
|
Added to .gitignore: /snapshot/, /snapshot.tmp/
|
|
280
280
|
```
|
|
281
281
|
|
|
@@ -425,8 +425,8 @@ agent](agent.md).
|
|
|
425
425
|
Ask the npm registry whether a newer release exists, and print the version it compared against:
|
|
426
426
|
|
|
427
427
|
```bash
|
|
428
|
-
npx codebase-snapshot@0.20.
|
|
429
|
-
npx codebase-snapshot@0.20.
|
|
428
|
+
npx codebase-snapshot@0.20.6 update # is 0.17.0 still current? print the answer
|
|
429
|
+
npx codebase-snapshot@0.20.6 update --format json
|
|
430
430
|
```
|
|
431
431
|
|
|
432
432
|
```text
|
package/docs/deploy.md
CHANGED
|
@@ -61,8 +61,8 @@ After=network.target
|
|
|
61
61
|
Type=oneshot
|
|
62
62
|
User=deploy
|
|
63
63
|
WorkingDirectory=/srv/app
|
|
64
|
-
ExecStart=/usr/bin/npx -y codebase-snapshot@0.20.
|
|
65
|
-
ExecStartPost=/usr/bin/npx -y codebase-snapshot@0.20.
|
|
64
|
+
ExecStart=/usr/bin/npx -y codebase-snapshot@0.20.6 generate --cwd /srv/app
|
|
65
|
+
ExecStartPost=/usr/bin/npx -y codebase-snapshot@0.20.6 validate --cwd /srv/app
|
|
66
66
|
```
|
|
67
67
|
|
|
68
68
|
```ini
|
package/docs/mcp.md
CHANGED
|
@@ -10,7 +10,7 @@ walk — that the client sees.
|
|
|
10
10
|
## Start it
|
|
11
11
|
|
|
12
12
|
```bash
|
|
13
|
-
npx -y codebase-snapshot@0.20.
|
|
13
|
+
npx -y codebase-snapshot@0.20.6 mcp
|
|
14
14
|
```
|
|
15
15
|
|
|
16
16
|
The server serves the directory it was started in. `--cwd <path>` points it elsewhere, and that
|
|
@@ -25,7 +25,7 @@ Claude Desktop and Cursor:
|
|
|
25
25
|
"mcpServers": {
|
|
26
26
|
"codebase-snapshot": {
|
|
27
27
|
"command": "npx",
|
|
28
|
-
"args": ["-y", "codebase-snapshot@0.20.
|
|
28
|
+
"args": ["-y", "codebase-snapshot@0.20.6", "mcp", "--cwd", "/absolute/path/to/repo"]
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
31
|
}
|
|
@@ -34,7 +34,7 @@ Claude Desktop and Cursor:
|
|
|
34
34
|
Claude Code registers the same thing from a shell:
|
|
35
35
|
|
|
36
36
|
```bash
|
|
37
|
-
claude mcp add codebase-snapshot -- npx -y codebase-snapshot@0.20.
|
|
37
|
+
claude mcp add codebase-snapshot -- npx -y codebase-snapshot@0.20.6 mcp --cwd /absolute/path/to/repo
|
|
38
38
|
```
|
|
39
39
|
|
|
40
40
|
On Windows, wrap the command as `cmd /c npx` with the same arguments — `npx` is a `.cmd` shim
|
|
@@ -43,7 +43,7 @@ there, and clients that spawn without a shell cannot execute it directly.
|
|
|
43
43
|
## Over HTTP, for clients that cannot spawn a process
|
|
44
44
|
|
|
45
45
|
```bash
|
|
46
|
-
npx -y codebase-snapshot@0.20.
|
|
46
|
+
npx -y codebase-snapshot@0.20.6 mcp --http --port 4789
|
|
47
47
|
```
|
|
48
48
|
|
|
49
49
|
This is the Streamable HTTP shape: POST one JSON-RPC message (or an array) to `/mcp` and read
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codebase-snapshot",
|
|
3
|
-
"version": "0.20.
|
|
3
|
+
"version": "0.20.6",
|
|
4
4
|
"description": "Create a codebase snapshot an LLM can read: budgeted Markdown parts for Claude, ChatGPT and Cursor, a manifest of every included and skipped file, secret redaction, and validate, which fails when the snapshot drifts. Local CLI and MCP server.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"codebase-snapshot",
|