@windagency/codemap-gen-for-agents 1.0.0 → 1.0.3
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/README.md +6 -6
- package/THIRD_PARTY_LICENSES.md +4 -4
- package/dist/extraction/tree-sitter-common/tree-sitter-parser.d.ts +1 -1
- package/dist/extraction/tree-sitter-common/tree-sitter-parser.js +1 -1
- package/dist/extraction/tree-sitter-common/tree-sitter-parser.js.map +1 -1
- package/dist/extraction/tree-sitter-go/go-parser.js +3 -2
- package/dist/extraction/tree-sitter-go/go-parser.js.map +1 -1
- package/dist/extraction/tree-sitter-java/java-parser.js +3 -2
- package/dist/extraction/tree-sitter-java/java-parser.js.map +1 -1
- package/dist/extraction/tree-sitter-python/python-parser.js +3 -2
- package/dist/extraction/tree-sitter-python/python-parser.js.map +1 -1
- package/dist/extraction/tree-sitter-rust/rust-parser.js +3 -2
- package/dist/extraction/tree-sitter-rust/rust-parser.js.map +1 -1
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -1,7 +1,5 @@
|
|
|
1
1
|
# codemap-gen-for-agents
|
|
2
2
|
|
|
3
|
-
[Back to 02-language-convention.md](CODING_RULES/02-language-convention.md) • [Back to 10-commits-and-versioning.md](CODING_RULES/10-commits-and-versioning.md) • [Back to GIT.md](documentation/GIT.md) • [Back to TESTING.md](documentation/TESTING.md) • [Back to USER_GUIDE.md](documentation/USER_GUIDE.md) • [Back to SECURITY.md](SECURITY.md)
|
|
4
|
-
|
|
5
3
|

|
|
6
4
|
|
|
7
5
|
[](https://www.npmjs.com/package/@windagency/codemap-gen-for-agents)
|
|
@@ -12,7 +10,7 @@
|
|
|
12
10
|
|
|
13
11
|
Point it at a repo - TypeScript/JavaScript, Go, Rust, Java, Python, any mix in one place - and it statically analyses the whole thing into one graph, then hands you two views of it:
|
|
14
12
|
|
|
15
|
-
|
|
|
13
|
+
| Script | Description |
|
|
16
14
|
| --------------------- | ----------------------------------------------------------------------------- |
|
|
17
15
|
| 🤖 **`codemap.json`** | Machine-readable. Context for Claude Code, Claude Desktop, or any MCP client. |
|
|
18
16
|
| 🧑💻 **`codemap.html`** | One offline file. Open it in a browser and click around. |
|
|
@@ -47,10 +45,12 @@ npm install -g @windagency/codemap-gen-for-agents # or: pnpm add -g / yarn gl
|
|
|
47
45
|
|
|
48
46
|
This puts `codemap` and `codemap-mcp` on your `PATH`. Yarn Berry (v2+) has no global-install command at all - use `yarn dlx` below instead, every time.
|
|
49
47
|
|
|
48
|
+
**Linux on arm64:** `tree-sitter-java` 0.23.5 ships an x86-64 binary as its `linux-arm64` prebuild, so the Java grammar has to compile from source during install. Have Python 3, `make` and a C++ compiler installed first (Debian/Ubuntu: `apt install python3 make g++`). npm 12 also skips install scripts for global installs, so allow that one build explicitly: `npm install -g --allow-scripts=tree-sitter-java @windagency/codemap-gen-for-agents`. Without it, `codemap generate` fails on any repository containing Java files. The grammar loads only when a run has Java to extract, so other repositories are unaffected. Every other platform's prebuild matches its architecture, so nothing extra is needed elsewhere, and npm 11 runs the build without the flag.
|
|
49
|
+
|
|
50
50
|
**Or run it without installing.** This package ships two bins (`codemap`, `codemap-mcp`), neither named after the package itself, so every runner needs an explicit `--package`/`-p` flag to say which one to run:
|
|
51
51
|
|
|
52
|
-
| Runner | Command
|
|
53
|
-
| ----------------- |
|
|
52
|
+
| Runner | Command |
|
|
53
|
+
| ----------------- | ------------------------------------------------------------------------------------------------ |
|
|
54
54
|
| npm (`npx`) | `npx -p @windagency/codemap-gen-for-agents codemap generate --root . --out .codemap` |
|
|
55
55
|
| pnpm | `pnpm dlx --package=@windagency/codemap-gen-for-agents codemap generate --root . --out .codemap` |
|
|
56
56
|
| Yarn (Berry, v2+) | `yarn dlx -p @windagency/codemap-gen-for-agents codemap generate --root . --out .codemap` |
|
|
@@ -137,7 +137,7 @@ Four stages (Discovery → Parser → GraphBuilder → ModuleDetector) behind th
|
|
|
137
137
|
| [`documentation/LLD.md`](documentation/LLD.md) | Maintainer | Per-component interfaces, types, and implementation detail |
|
|
138
138
|
| [`documentation/FLOWS.md`](documentation/FLOWS.md) | Both | Step-by-step runtime flows (generate, incremental re-run, MCP read, HTML interaction) |
|
|
139
139
|
| [`documentation/adr/`](documentation/adr) | Maintainer | Why each architectural decision was made, in order |
|
|
140
|
-
| [`documentation/DEPLOYMENT.md`](documentation/DEPLOYMENT.md) | Maintainer | Commit-driven release pipeline: CI, commitlint, semantic-release, npm publish, signing
|
|
140
|
+
| [`documentation/DEPLOYMENT.md`](documentation/DEPLOYMENT.md) | Maintainer | Commit-driven release pipeline: CI, commitlint, semantic-release, staged npm publish, signing |
|
|
141
141
|
| [`documentation/GIT.md`](documentation/GIT.md) | Contributor | Git hook behaviour, commit signing setup, branch model |
|
|
142
142
|
| [`documentation/GITFLOW.md`](documentation/GITFLOW.md) | Contributor | Visual branch flow: `feat-`/`fix-` → `int` → `main`, `hotfix-` → `main` + `int`, `release/*.x` lines |
|
|
143
143
|
| [`documentation/SEMVER.md`](documentation/SEMVER.md) | Contributor | SemVer policy, `CHANGELOG.md` mechanics |
|
package/THIRD_PARTY_LICENSES.md
CHANGED
|
@@ -22,10 +22,10 @@ The packages this project's own `package.json` depends on directly.
|
|
|
22
22
|
| --- | --- | --- | --- |
|
|
23
23
|
| typescript | 7.0.2 | Apache-2.0 | Microsoft Corp. |
|
|
24
24
|
| d3 | 7.9.0 | ISC | Mike Bostock |
|
|
25
|
-
| @modelcontextprotocol/sdk | 1.
|
|
25
|
+
| @modelcontextprotocol/sdk | 1.32.1 | MIT | Anthropic, PBC |
|
|
26
26
|
| graphology | 0.26.0 | MIT | - |
|
|
27
27
|
| graphology-communities-louvain | 2.0.2 | MIT | - |
|
|
28
|
-
| ignore | 7.0.
|
|
28
|
+
| ignore | 7.0.12 | MIT | kael |
|
|
29
29
|
| picomatch | 4.0.7 | MIT | Jon Schlinkert |
|
|
30
30
|
| tree-sitter | 0.25.1 | MIT | Max Brunsfeld |
|
|
31
31
|
| tree-sitter-go | 0.25.0 | MIT | Max Brunsfeld |
|
|
@@ -86,7 +86,7 @@ Every package resolved into the production tree (direct and transitive), as inst
|
|
|
86
86
|
| wrappy | 1.0.2 | ISC | Isaac Z. Schlueter |
|
|
87
87
|
| zod-to-json-schema | 3.25.2 | ISC | Stefan Terdell |
|
|
88
88
|
| @hono/node-server | 2.1.3 | MIT | Yusuke Wada |
|
|
89
|
-
| @modelcontextprotocol/sdk | 1.
|
|
89
|
+
| @modelcontextprotocol/sdk | 1.32.1 | MIT | Anthropic, PBC |
|
|
90
90
|
| accepts | 2.0.0 | MIT | - |
|
|
91
91
|
| ajv | 8.20.0 | MIT | Evgeny Poberezkin |
|
|
92
92
|
| ajv-formats | 3.0.1 | MIT | Evgeny Poberezkin |
|
|
@@ -134,7 +134,7 @@ Every package resolved into the production tree (direct and transitive), as inst
|
|
|
134
134
|
| hono | 4.13.12 | MIT | Yusuke Wada |
|
|
135
135
|
| http-errors | 2.0.1 | MIT | Jonathan Ong |
|
|
136
136
|
| iconv-lite | 0.6.3,0.7.3 | MIT | Alexander Shtuchkin |
|
|
137
|
-
| ignore | 7.0.
|
|
137
|
+
| ignore | 7.0.12 | MIT | kael |
|
|
138
138
|
| ip-address | 10.7.2 | MIT | Beau Gunderson |
|
|
139
139
|
| ipaddr.js | 1.9.1 | MIT | whitequark |
|
|
140
140
|
| is-promise | 4.0.0 | MIT | ForbesLindesay |
|
|
@@ -14,7 +14,7 @@ export interface TreeSitterFile {
|
|
|
14
14
|
entry: FileSymbolIndex;
|
|
15
15
|
}
|
|
16
16
|
export interface TreeSitterLanguage<LanguageIndex> {
|
|
17
|
-
|
|
17
|
+
loadGrammar: () => TreeSitterParser.Language;
|
|
18
18
|
collectDeclaredSymbols: (root: TreeSitterParser.SyntaxNode) => DeclaredItem[];
|
|
19
19
|
buildLanguageIndex: (program: TreeSitterProgram) => LanguageIndex;
|
|
20
20
|
extractFile: (file: TreeSitterFile, program: TreeSitterProgram, languageIndex: LanguageIndex) => {
|
|
@@ -8,7 +8,7 @@ export function parseWithTreeSitter(language, rootDir, programFiles, extractFile
|
|
|
8
8
|
if (extractFiles.length === 0)
|
|
9
9
|
return [];
|
|
10
10
|
const parser = new TreeSitterParser();
|
|
11
|
-
parser.setLanguage(language.
|
|
11
|
+
parser.setLanguage(language.loadGrammar());
|
|
12
12
|
const parsed = buildProgramIndex(parser, programFiles, language.collectDeclaredSymbols);
|
|
13
13
|
const program = {
|
|
14
14
|
rootDir,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tree-sitter-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-common/tree-sitter-parser.ts"],"names":[],"mappings":"AACA,OAAO,EACN,iBAAiB,GAGjB,MAAM,iDAAiD,CAAC;AAEzD,OAAO,gBAAgB,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"tree-sitter-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-common/tree-sitter-parser.ts"],"names":[],"mappings":"AACA,OAAO,EACN,iBAAiB,GAGjB,MAAM,iDAAiD,CAAC;AAEzD,OAAO,gBAAgB,MAAM,aAAa,CAAC;AAmC3C,2FAA2F;AAC3F,yGAAyG;AACzG,+FAA+F;AAC/F,mFAAmF;AACnF,MAAM,UAAU,mBAAmB,CAClC,QAA2C,EAC3C,OAAe,EACf,YAAsB,EACtB,YAAsB;IAEtB,IAAI,YAAY,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,EAAE,CAAC;IAEzC,MAAM,MAAM,GAAG,IAAI,gBAAgB,EAAE,CAAC;IACtC,MAAM,CAAC,WAAW,CAAC,QAAQ,CAAC,WAAW,EAAE,CAAC,CAAC;IAE3C,MAAM,MAAM,GAAG,iBAAiB,CAAC,MAAM,EAAE,YAAY,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC;IACxF,MAAM,OAAO,GAAsB;QAClC,OAAO;QACP,YAAY,EAAE,YAAY,CAAC,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QAC3E,KAAK,EAAE,MAAM,CAAC,KAAK;QACnB,UAAU,EAAE,MAAM,CAAC,UAAU;KAC7B,CAAC;IACF,MAAM,aAAa,GAAG,QAAQ,CAAC,kBAAkB,CAAC,OAAO,CAAC,CAAC;IAE3D,OAAO,YAAY,CAAC,OAAO,CAAC,CAAC,QAAQ,EAAsB,EAAE;QAC5D,MAAM,KAAK,GAAG,OAAO,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QAC1C,MAAM,IAAI,GAAG,OAAO,CAAC,UAAU,CAAC,GAAG,CAAC,QAAQ,CAAC,CAAC;QAC9C,IAAI,CAAC,KAAK,IAAI,CAAC,IAAI;YAAE,OAAO,EAAE,CAAC;QAE/B,MAAM,EAAE,OAAO,EAAE,KAAK,EAAE,GAAG,QAAQ,CAAC,WAAW,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,aAAa,CAAC,CAAC;QACnG,OAAO,CAAC,EAAE,QAAQ,EAAE,OAAO,EAAE,KAAK,CAAC,KAAK,CAAC,UAAU,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC,CAAC;IACxE,CAAC,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -1,15 +1,16 @@
|
|
|
1
|
+
import { createRequire } from "node:module";
|
|
1
2
|
import { memoizeManifestLookup } from "../tree-sitter-common/program-index.js";
|
|
2
3
|
import { parseWithTreeSitter, } from "../tree-sitter-common/tree-sitter-parser.js";
|
|
3
4
|
import { toRawCalls } from "./go-call-resolution.js";
|
|
4
5
|
import { buildImportAliasToFiles, collectImportSpecs, toRawImports, } from "./go-import-resolution.js";
|
|
5
6
|
import { findNearestGoModule } from "./go-mod.js";
|
|
6
7
|
import { collectDeclaredSymbols } from "./go-symbol-classification.js";
|
|
7
|
-
|
|
8
|
+
const require = createRequire(import.meta.url);
|
|
8
9
|
function buildGoIndex({ rootDir }) {
|
|
9
10
|
return { goModuleFor: memoizeManifestLookup(rootDir, findNearestGoModule) };
|
|
10
11
|
}
|
|
11
12
|
const GO = {
|
|
12
|
-
|
|
13
|
+
loadGrammar: () => require("tree-sitter-go"),
|
|
13
14
|
collectDeclaredSymbols,
|
|
14
15
|
buildLanguageIndex: buildGoIndex,
|
|
15
16
|
extractFile: ({ filePath, tree, entry }, { programFiles, index }, go) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"go-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-go/go-parser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"go-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-go/go-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAG5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,iDAAiD,CAAC;AACxF,OAAO,EACN,mBAAmB,GAGnB,MAAM,sDAAsD,CAAC;AAC9D,OAAO,EAAE,UAAU,EAAE,MAAM,kDAAkD,CAAC;AAC9E,OAAO,EACN,uBAAuB,EACvB,kBAAkB,EAClB,YAAY,GACZ,MAAM,oDAAoD,CAAC;AAC5D,OAAO,EAAE,mBAAmB,EAAE,MAAM,sCAAsC,CAAC;AAC3E,OAAO,EAAE,sBAAsB,EAAE,MAAM,wDAAwD,CAAC;AAEhG,MAAM,OAAO,GAAG,aAAa,CAAC,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC;AAE/C,SAAS,YAAY,CAAC,EAAE,OAAO,EAAqB;IACnD,OAAO,EAAE,WAAW,EAAE,qBAAqB,CAAC,OAAO,EAAE,mBAAmB,CAAC,EAAE,CAAC;AAC7E,CAAC;AAED,MAAM,EAAE,GAAwD;IAC/D,WAAW,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,gBAAgB,CAAoC;IAC/E,sBAAsB;IACtB,kBAAkB,EAAE,YAAY;IAChC,WAAW,EAAE,CAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,EAAE,EAAE,YAAY,EAAE,KAAK,EAAE,EAAE,EAAE,EAAE,EAAE;QACvE,MAAM,QAAQ,GAAG,EAAE,CAAC,WAAW,CAAC,QAAQ,CAAC,CAAC;QAC1C,MAAM,KAAK,GAAG,kBAAkB,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QAChD,OAAO;YACN,OAAO,EAAE,YAAY,CAAC,KAAK,EAAE,QAAQ,EAAE,YAAY,CAAC;YACpD,KAAK,EAAE,UAAU,CAChB,IAAI,CAAC,QAAQ,EACb,KAAK,CAAC,KAAK,CAAC,YAAY,EACxB,KAAK,EACL,uBAAuB,CAAC,KAAK,EAAE,QAAQ,EAAE,YAAY,CAAC,CACtD;SACD,CAAC;IACH,CAAC;CACD,CAAC;AAEF,0FAA0F;AAC1F,6FAA6F;AAC7F,sDAAsD;AACtD,MAAM,OAAO,kBAAkB;IAC9B,KAAK,CAAC,OAAe,EAAE,YAAsB,EAAE,YAAsB;QACpE,OAAO,mBAAmB,CAAC,EAAE,EAAE,OAAO,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;IACrE,CAAC;CACD"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { createRequire } from "node:module";
|
|
1
2
|
import { memoizeManifestLookup } from "../tree-sitter-common/program-index.js";
|
|
2
3
|
import { parseWithTreeSitter, } from "../tree-sitter-common/tree-sitter-parser.js";
|
|
3
4
|
import { buildTypeNameIndex, toRawCalls } from "./java-call-resolution.js";
|
|
4
5
|
import { buildFqcnIndex, buildVisibleTypeIndex, collectImportSpecs, collectSupertypeReferences, toRawImports, toSupertypeImports, } from "./java-import-resolution.js";
|
|
5
6
|
import { findNearestJavaProject } from "./java-project.js";
|
|
6
7
|
import { collectDeclaredSymbols } from "./java-symbol-classification.js";
|
|
7
|
-
|
|
8
|
+
const require = createRequire(import.meta.url);
|
|
8
9
|
function buildJavaIndex({ rootDir, programFiles, index, treeByFile }) {
|
|
9
10
|
return {
|
|
10
11
|
projectFor: memoizeManifestLookup(rootDir, findNearestJavaProject),
|
|
@@ -16,7 +17,7 @@ function buildJavaIndex({ rootDir, programFiles, index, treeByFile }) {
|
|
|
16
17
|
};
|
|
17
18
|
}
|
|
18
19
|
const JAVA = {
|
|
19
|
-
|
|
20
|
+
loadGrammar: () => require("tree-sitter-java"),
|
|
20
21
|
collectDeclaredSymbols,
|
|
21
22
|
buildLanguageIndex: buildJavaIndex,
|
|
22
23
|
extractFile: ({ filePath, tree, entry }, { index }, java) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"java-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-java/java-parser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"java-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-java/java-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAG5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,iDAAiD,CAAC;AACxF,OAAO,EACN,mBAAmB,GAGnB,MAAM,sDAAsD,CAAC;AAC9D,OAAO,EAAE,kBAAkB,EAAE,UAAU,EAAE,MAAM,sDAAsD,CAAC;AACtG,OAAO,EACN,cAAc,EACd,qBAAqB,EACrB,kBAAkB,EAClB,0BAA0B,EAC1B,YAAY,EACZ,kBAAkB,GAClB,MAAM,wDAAwD,CAAC;AAChE,OAAO,EAAE,sBAAsB,EAAE,MAAM,8CAA8C,CAAC;AACtF,OAAO,EAAE,sBAAsB,EAAE,MAAM,4DAA4D,CAAC;AAEpG,MAAM,OAAO,GAAG,aAAa,CAAC,OAAO,IAAI,CAAC,GAAG,CAAC,CAAC;AAE/C,SAAS,cAAc,CAAC,EAAE,OAAO,EAAE,YAAY,EAAE,KAAK,EAAE,UAAU,EAAqB;IACtF,OAAO;QACN,UAAU,EAAE,qBAAqB,CAAC,OAAO,EAAE,sBA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A6F;AAC7F,sDAAsD;AACtD,MAAM,OAAO,oBAAoB;IAChC,KAAK,CAAC,OAAe,EAAE,YAAsB,EAAE,YAAsB;QACpE,OAAO,mBAAmB,CAAC,IAAI,EAAE,OAAO,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;IACvE,CAAC;CACD"}
|
|
@@ -1,17 +1,18 @@
|
|
|
1
|
+
import { createRequire } from "node:module";
|
|
1
2
|
import { memoizeManifestLookup } from "../tree-sitter-common/program-index.js";
|
|
2
3
|
import { parseWithTreeSitter, } from "../tree-sitter-common/tree-sitter-parser.js";
|
|
3
4
|
import { findNearestPythonProject } from "./pyproject-manifest.js";
|
|
4
5
|
import { toRawCalls } from "./python-call-resolution.js";
|
|
5
6
|
import { buildImportAliasToFiles, collectImportSpecs, toRawImports, } from "./python-import-resolution.js";
|
|
6
7
|
import { collectDeclaredSymbols } from "./python-symbol-classification.js";
|
|
7
|
-
|
|
8
|
+
const require = createRequire(import.meta.url);
|
|
8
9
|
function buildPythonIndex({ rootDir }) {
|
|
9
10
|
return {
|
|
10
11
|
projectFor: memoizeManifestLookup(rootDir, findNearestPythonProject),
|
|
11
12
|
};
|
|
12
13
|
}
|
|
13
14
|
const PYTHON = {
|
|
14
|
-
|
|
15
|
+
loadGrammar: () => require("tree-sitter-python"),
|
|
15
16
|
collectDeclaredSymbols,
|
|
16
17
|
buildLanguageIndex: buildPythonIndex,
|
|
17
18
|
extractFile: ({ filePath, tree, entry }, { programFiles, index }, python) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"python-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-python/python-parser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"python-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-python/python-parser.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAG5C,OAAO,EAAE,qBAAqB,EAAE,MAAM,iDAAiD,CAAC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,+EAA+E;AAC/E,MAAM,OAAO,sBAAsB;IAClC,KAAK,CAAC,OAAe,EAAE,YAAsB,EAAE,YAAsB;QACpE,OAAO,mBAAmB,CAAC,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;IACzE,CAAC;CACD"}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { createRequire } from "node:module";
|
|
1
2
|
import { memoizeManifestLookup } from "../tree-sitter-common/program-index.js";
|
|
2
3
|
import { parseWithTreeSitter, } from "../tree-sitter-common/tree-sitter-parser.js";
|
|
3
4
|
import { findNearestRustCrate } from "./cargo-manifest.js";
|
|
4
5
|
import { buildImplTypeIndex, toRawCalls } from "./rust-call-resolution.js";
|
|
5
6
|
import { buildModuleAliasToFile, buildReExportsByFile, collectModDeclarations, collectUseSpecs, toModDeclarationImports, toRawImports, } from "./rust-import-resolution.js";
|
|
6
7
|
import { collectDeclaredSymbols } from "./rust-symbol-classification.js";
|
|
7
|
-
|
|
8
|
+
const require = createRequire(import.meta.url);
|
|
8
9
|
function buildRustIndex({ rootDir, programFiles, index, treeByFile }) {
|
|
9
10
|
const crateFor = memoizeManifestLookup(rootDir, findNearestRustCrate);
|
|
10
11
|
return {
|
|
@@ -14,7 +15,7 @@ function buildRustIndex({ rootDir, programFiles, index, treeByFile }) {
|
|
|
14
15
|
};
|
|
15
16
|
}
|
|
16
17
|
const RUST = {
|
|
17
|
-
|
|
18
|
+
loadGrammar: () => require("tree-sitter-rust"),
|
|
18
19
|
collectDeclaredSymbols,
|
|
19
20
|
buildLanguageIndex: buildRustIndex,
|
|
20
21
|
extractFile: ({ filePath, tree, entry }, { programFiles, index }, rust) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"rust-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-rust/rust-parser.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"rust-parser.js","sourceRoot":"","sources":["../../../src/extraction/tree-sitter-rust/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,CAAC,QAAQ,CAAC,CAAC;QACtC,MAAM,KAAK,GAAG,eAAe,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC7C,MAAM,eAAe,GAAG,sBAAsB,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC9D,OAAO;YACN,OAAO,EAAE;gBACR,GAAG,YAAY,CAAC,KAAK,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,CAAC;gBACrD,GAAG,uBAAuB,CAAC,eAAe,EAAE,QAAQ,EAAE,YAAY,CAAC;aACnE;YACD,KAAK,EAAE,UAAU,CAAC,IAAI,CAAC,QAAQ,EAAE,KAAK,CAAC,KAAK,CAAC,YAAY,EAAE;gBAC1D,KAAK;gBACL,aAAa,EAAE,IAAI,CAAC,aAAa;gBACjC,iBAAiB,EAAE,sBAAsB,CAAC,KAAK,EAAE,eAAe,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,CAAC;gBAChG,eAAe,EAAE,IAAI,CAAC,eAAe;gBACrC,KAAK;gBACL,QAAQ;gBACR,YAAY;aACZ,CAAC;SACF,CAAC;IACH,CAAC;CACD,CAAC;AAEF,4FAA4F;AAC5F,6FAA6F;AAC7F,sDAAsD;AACtD,MAAM,OAAO,oBAAoB;IAChC,KAAK,CAAC,OAAe,EAAE,YAAsB,EAAE,YAAsB;QACpE,OAAO,mBAAmB,CAAC,IAAI,EAAE,OAAO,EAAE,YAAY,EAAE,YAAY,CAAC,CAAC;IACvE,CAAC;CACD"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@windagency/codemap-gen-for-agents",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.3",
|
|
4
4
|
"description": "Code-map generator for AI coding agents",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -68,6 +68,7 @@
|
|
|
68
68
|
"@commitlint/config-conventional": "^21.2.3",
|
|
69
69
|
"@semantic-release/changelog": "^7.0.0",
|
|
70
70
|
"@semantic-release/commit-analyzer": "^13.0.1",
|
|
71
|
+
"@semantic-release/exec": "^7.1.0",
|
|
71
72
|
"@semantic-release/git": "^11.0.1",
|
|
72
73
|
"@semantic-release/github": "^12.0.10",
|
|
73
74
|
"@semantic-release/npm": "^13.2.0",
|