@kkvcrobatz107/codegraph 0.9.6-pkm.1

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.
Files changed (501) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +595 -0
  3. package/dist/bin/codegraph.d.ts +25 -0
  4. package/dist/bin/codegraph.d.ts.map +1 -0
  5. package/dist/bin/codegraph.js +1563 -0
  6. package/dist/bin/codegraph.js.map +1 -0
  7. package/dist/bin/node-version-check.d.ts +37 -0
  8. package/dist/bin/node-version-check.d.ts.map +1 -0
  9. package/dist/bin/node-version-check.js +79 -0
  10. package/dist/bin/node-version-check.js.map +1 -0
  11. package/dist/bin/uninstall.d.ts +14 -0
  12. package/dist/bin/uninstall.d.ts.map +1 -0
  13. package/dist/bin/uninstall.js +36 -0
  14. package/dist/bin/uninstall.js.map +1 -0
  15. package/dist/context/formatter.d.ts +30 -0
  16. package/dist/context/formatter.d.ts.map +1 -0
  17. package/dist/context/formatter.js +244 -0
  18. package/dist/context/formatter.js.map +1 -0
  19. package/dist/context/index.d.ts +110 -0
  20. package/dist/context/index.d.ts.map +1 -0
  21. package/dist/context/index.js +1169 -0
  22. package/dist/context/index.js.map +1 -0
  23. package/dist/db/index.d.ts +101 -0
  24. package/dist/db/index.d.ts.map +1 -0
  25. package/dist/db/index.js +251 -0
  26. package/dist/db/index.js.map +1 -0
  27. package/dist/db/migrations.d.ts +44 -0
  28. package/dist/db/migrations.d.ts.map +1 -0
  29. package/dist/db/migrations.js +131 -0
  30. package/dist/db/migrations.js.map +1 -0
  31. package/dist/db/queries.d.ts +281 -0
  32. package/dist/db/queries.d.ts.map +1 -0
  33. package/dist/db/queries.js +1300 -0
  34. package/dist/db/queries.js.map +1 -0
  35. package/dist/db/schema.sql +151 -0
  36. package/dist/db/sqlite-adapter.d.ts +46 -0
  37. package/dist/db/sqlite-adapter.d.ts.map +1 -0
  38. package/dist/db/sqlite-adapter.js +114 -0
  39. package/dist/db/sqlite-adapter.js.map +1 -0
  40. package/dist/directory.d.ts +57 -0
  41. package/dist/directory.d.ts.map +1 -0
  42. package/dist/directory.js +264 -0
  43. package/dist/directory.js.map +1 -0
  44. package/dist/errors.d.ts +136 -0
  45. package/dist/errors.d.ts.map +1 -0
  46. package/dist/errors.js +219 -0
  47. package/dist/errors.js.map +1 -0
  48. package/dist/extraction/dfm-extractor.d.ts +31 -0
  49. package/dist/extraction/dfm-extractor.d.ts.map +1 -0
  50. package/dist/extraction/dfm-extractor.js +151 -0
  51. package/dist/extraction/dfm-extractor.js.map +1 -0
  52. package/dist/extraction/grammars.d.ts +90 -0
  53. package/dist/extraction/grammars.d.ts.map +1 -0
  54. package/dist/extraction/grammars.js +407 -0
  55. package/dist/extraction/grammars.js.map +1 -0
  56. package/dist/extraction/index.d.ts +138 -0
  57. package/dist/extraction/index.d.ts.map +1 -0
  58. package/dist/extraction/index.js +1378 -0
  59. package/dist/extraction/index.js.map +1 -0
  60. package/dist/extraction/languages/c-cpp.d.ts +4 -0
  61. package/dist/extraction/languages/c-cpp.d.ts.map +1 -0
  62. package/dist/extraction/languages/c-cpp.js +171 -0
  63. package/dist/extraction/languages/c-cpp.js.map +1 -0
  64. package/dist/extraction/languages/csharp.d.ts +3 -0
  65. package/dist/extraction/languages/csharp.d.ts.map +1 -0
  66. package/dist/extraction/languages/csharp.js +73 -0
  67. package/dist/extraction/languages/csharp.js.map +1 -0
  68. package/dist/extraction/languages/dart.d.ts +3 -0
  69. package/dist/extraction/languages/dart.d.ts.map +1 -0
  70. package/dist/extraction/languages/dart.js +192 -0
  71. package/dist/extraction/languages/dart.js.map +1 -0
  72. package/dist/extraction/languages/go.d.ts +3 -0
  73. package/dist/extraction/languages/go.d.ts.map +1 -0
  74. package/dist/extraction/languages/go.js +70 -0
  75. package/dist/extraction/languages/go.js.map +1 -0
  76. package/dist/extraction/languages/index.d.ts +10 -0
  77. package/dist/extraction/languages/index.d.ts.map +1 -0
  78. package/dist/extraction/languages/index.js +51 -0
  79. package/dist/extraction/languages/index.js.map +1 -0
  80. package/dist/extraction/languages/java.d.ts +3 -0
  81. package/dist/extraction/languages/java.d.ts.map +1 -0
  82. package/dist/extraction/languages/java.js +70 -0
  83. package/dist/extraction/languages/java.js.map +1 -0
  84. package/dist/extraction/languages/javascript.d.ts +3 -0
  85. package/dist/extraction/languages/javascript.d.ts.map +1 -0
  86. package/dist/extraction/languages/javascript.js +90 -0
  87. package/dist/extraction/languages/javascript.js.map +1 -0
  88. package/dist/extraction/languages/kotlin.d.ts +3 -0
  89. package/dist/extraction/languages/kotlin.d.ts.map +1 -0
  90. package/dist/extraction/languages/kotlin.js +259 -0
  91. package/dist/extraction/languages/kotlin.js.map +1 -0
  92. package/dist/extraction/languages/lua.d.ts +3 -0
  93. package/dist/extraction/languages/lua.d.ts.map +1 -0
  94. package/dist/extraction/languages/lua.js +150 -0
  95. package/dist/extraction/languages/lua.js.map +1 -0
  96. package/dist/extraction/languages/luau.d.ts +3 -0
  97. package/dist/extraction/languages/luau.d.ts.map +1 -0
  98. package/dist/extraction/languages/luau.js +37 -0
  99. package/dist/extraction/languages/luau.js.map +1 -0
  100. package/dist/extraction/languages/objc.d.ts +3 -0
  101. package/dist/extraction/languages/objc.d.ts.map +1 -0
  102. package/dist/extraction/languages/objc.js +133 -0
  103. package/dist/extraction/languages/objc.js.map +1 -0
  104. package/dist/extraction/languages/pascal.d.ts +3 -0
  105. package/dist/extraction/languages/pascal.d.ts.map +1 -0
  106. package/dist/extraction/languages/pascal.js +66 -0
  107. package/dist/extraction/languages/pascal.js.map +1 -0
  108. package/dist/extraction/languages/php.d.ts +3 -0
  109. package/dist/extraction/languages/php.d.ts.map +1 -0
  110. package/dist/extraction/languages/php.js +107 -0
  111. package/dist/extraction/languages/php.js.map +1 -0
  112. package/dist/extraction/languages/python.d.ts +3 -0
  113. package/dist/extraction/languages/python.d.ts.map +1 -0
  114. package/dist/extraction/languages/python.js +56 -0
  115. package/dist/extraction/languages/python.js.map +1 -0
  116. package/dist/extraction/languages/ruby.d.ts +3 -0
  117. package/dist/extraction/languages/ruby.d.ts.map +1 -0
  118. package/dist/extraction/languages/ruby.js +114 -0
  119. package/dist/extraction/languages/ruby.js.map +1 -0
  120. package/dist/extraction/languages/rust.d.ts +3 -0
  121. package/dist/extraction/languages/rust.d.ts.map +1 -0
  122. package/dist/extraction/languages/rust.js +109 -0
  123. package/dist/extraction/languages/rust.js.map +1 -0
  124. package/dist/extraction/languages/scala.d.ts +3 -0
  125. package/dist/extraction/languages/scala.d.ts.map +1 -0
  126. package/dist/extraction/languages/scala.js +139 -0
  127. package/dist/extraction/languages/scala.js.map +1 -0
  128. package/dist/extraction/languages/swift.d.ts +3 -0
  129. package/dist/extraction/languages/swift.d.ts.map +1 -0
  130. package/dist/extraction/languages/swift.js +91 -0
  131. package/dist/extraction/languages/swift.js.map +1 -0
  132. package/dist/extraction/languages/typescript.d.ts +3 -0
  133. package/dist/extraction/languages/typescript.d.ts.map +1 -0
  134. package/dist/extraction/languages/typescript.js +129 -0
  135. package/dist/extraction/languages/typescript.js.map +1 -0
  136. package/dist/extraction/liquid-extractor.d.ts +52 -0
  137. package/dist/extraction/liquid-extractor.d.ts.map +1 -0
  138. package/dist/extraction/liquid-extractor.js +313 -0
  139. package/dist/extraction/liquid-extractor.js.map +1 -0
  140. package/dist/extraction/mybatis-extractor.d.ts +48 -0
  141. package/dist/extraction/mybatis-extractor.d.ts.map +1 -0
  142. package/dist/extraction/mybatis-extractor.js +198 -0
  143. package/dist/extraction/mybatis-extractor.js.map +1 -0
  144. package/dist/extraction/parse-worker.d.ts +8 -0
  145. package/dist/extraction/parse-worker.d.ts.map +1 -0
  146. package/dist/extraction/parse-worker.js +94 -0
  147. package/dist/extraction/parse-worker.js.map +1 -0
  148. package/dist/extraction/svelte-extractor.d.ts +56 -0
  149. package/dist/extraction/svelte-extractor.d.ts.map +1 -0
  150. package/dist/extraction/svelte-extractor.js +272 -0
  151. package/dist/extraction/svelte-extractor.js.map +1 -0
  152. package/dist/extraction/tree-sitter-helpers.d.ts +28 -0
  153. package/dist/extraction/tree-sitter-helpers.d.ts.map +1 -0
  154. package/dist/extraction/tree-sitter-helpers.js +103 -0
  155. package/dist/extraction/tree-sitter-helpers.js.map +1 -0
  156. package/dist/extraction/tree-sitter-types.d.ts +193 -0
  157. package/dist/extraction/tree-sitter-types.d.ts.map +1 -0
  158. package/dist/extraction/tree-sitter-types.js +10 -0
  159. package/dist/extraction/tree-sitter-types.js.map +1 -0
  160. package/dist/extraction/tree-sitter.d.ts +291 -0
  161. package/dist/extraction/tree-sitter.d.ts.map +1 -0
  162. package/dist/extraction/tree-sitter.js +2961 -0
  163. package/dist/extraction/tree-sitter.js.map +1 -0
  164. package/dist/extraction/vue-extractor.d.ts +36 -0
  165. package/dist/extraction/vue-extractor.d.ts.map +1 -0
  166. package/dist/extraction/vue-extractor.js +163 -0
  167. package/dist/extraction/vue-extractor.js.map +1 -0
  168. package/dist/extraction/wasm/tree-sitter-lua.wasm +0 -0
  169. package/dist/extraction/wasm/tree-sitter-luau.wasm +0 -0
  170. package/dist/extraction/wasm/tree-sitter-pascal.wasm +0 -0
  171. package/dist/extraction/wasm/tree-sitter-scala.wasm +0 -0
  172. package/dist/extraction/wasm-runtime-flags.d.ts +38 -0
  173. package/dist/extraction/wasm-runtime-flags.d.ts.map +1 -0
  174. package/dist/extraction/wasm-runtime-flags.js +105 -0
  175. package/dist/extraction/wasm-runtime-flags.js.map +1 -0
  176. package/dist/graph/index.d.ts +8 -0
  177. package/dist/graph/index.d.ts.map +1 -0
  178. package/dist/graph/index.js +13 -0
  179. package/dist/graph/index.js.map +1 -0
  180. package/dist/graph/queries.d.ts +106 -0
  181. package/dist/graph/queries.d.ts.map +1 -0
  182. package/dist/graph/queries.js +366 -0
  183. package/dist/graph/queries.js.map +1 -0
  184. package/dist/graph/traversal.d.ts +127 -0
  185. package/dist/graph/traversal.d.ts.map +1 -0
  186. package/dist/graph/traversal.js +528 -0
  187. package/dist/graph/traversal.js.map +1 -0
  188. package/dist/index.d.ts +460 -0
  189. package/dist/index.d.ts.map +1 -0
  190. package/dist/index.js +863 -0
  191. package/dist/index.js.map +1 -0
  192. package/dist/installer/claude-md-template.d.ts +14 -0
  193. package/dist/installer/claude-md-template.d.ts.map +1 -0
  194. package/dist/installer/claude-md-template.js +21 -0
  195. package/dist/installer/claude-md-template.js.map +1 -0
  196. package/dist/installer/config-writer.d.ts +29 -0
  197. package/dist/installer/config-writer.d.ts.map +1 -0
  198. package/dist/installer/config-writer.js +111 -0
  199. package/dist/installer/config-writer.js.map +1 -0
  200. package/dist/installer/index.d.ts +117 -0
  201. package/dist/installer/index.d.ts.map +1 -0
  202. package/dist/installer/index.js +528 -0
  203. package/dist/installer/index.js.map +1 -0
  204. package/dist/installer/instructions-template.d.ts +28 -0
  205. package/dist/installer/instructions-template.d.ts.map +1 -0
  206. package/dist/installer/instructions-template.js +65 -0
  207. package/dist/installer/instructions-template.js.map +1 -0
  208. package/dist/installer/targets/antigravity.d.ts +57 -0
  209. package/dist/installer/targets/antigravity.d.ts.map +1 -0
  210. package/dist/installer/targets/antigravity.js +307 -0
  211. package/dist/installer/targets/antigravity.js.map +1 -0
  212. package/dist/installer/targets/claude.d.ts +47 -0
  213. package/dist/installer/targets/claude.d.ts.map +1 -0
  214. package/dist/installer/targets/claude.js +401 -0
  215. package/dist/installer/targets/claude.js.map +1 -0
  216. package/dist/installer/targets/codex.d.ts +18 -0
  217. package/dist/installer/targets/codex.d.ts.map +1 -0
  218. package/dist/installer/targets/codex.js +185 -0
  219. package/dist/installer/targets/codex.js.map +1 -0
  220. package/dist/installer/targets/cursor.d.ts +35 -0
  221. package/dist/installer/targets/cursor.d.ts.map +1 -0
  222. package/dist/installer/targets/cursor.js +283 -0
  223. package/dist/installer/targets/cursor.js.map +1 -0
  224. package/dist/installer/targets/gemini.d.ts +26 -0
  225. package/dist/installer/targets/gemini.d.ts.map +1 -0
  226. package/dist/installer/targets/gemini.js +165 -0
  227. package/dist/installer/targets/gemini.js.map +1 -0
  228. package/dist/installer/targets/hermes.d.ts +18 -0
  229. package/dist/installer/targets/hermes.d.ts.map +1 -0
  230. package/dist/installer/targets/hermes.js +359 -0
  231. package/dist/installer/targets/hermes.js.map +1 -0
  232. package/dist/installer/targets/kiro.d.ts +27 -0
  233. package/dist/installer/targets/kiro.d.ts.map +1 -0
  234. package/dist/installer/targets/kiro.js +196 -0
  235. package/dist/installer/targets/kiro.js.map +1 -0
  236. package/dist/installer/targets/opencode.d.ts +30 -0
  237. package/dist/installer/targets/opencode.d.ts.map +1 -0
  238. package/dist/installer/targets/opencode.js +235 -0
  239. package/dist/installer/targets/opencode.js.map +1 -0
  240. package/dist/installer/targets/registry.d.ts +35 -0
  241. package/dist/installer/targets/registry.d.ts.map +1 -0
  242. package/dist/installer/targets/registry.js +91 -0
  243. package/dist/installer/targets/registry.js.map +1 -0
  244. package/dist/installer/targets/shared.d.ts +77 -0
  245. package/dist/installer/targets/shared.d.ts.map +1 -0
  246. package/dist/installer/targets/shared.js +246 -0
  247. package/dist/installer/targets/shared.js.map +1 -0
  248. package/dist/installer/targets/toml.d.ts +52 -0
  249. package/dist/installer/targets/toml.d.ts.map +1 -0
  250. package/dist/installer/targets/toml.js +147 -0
  251. package/dist/installer/targets/toml.js.map +1 -0
  252. package/dist/installer/targets/types.d.ts +116 -0
  253. package/dist/installer/targets/types.d.ts.map +1 -0
  254. package/dist/installer/targets/types.js +16 -0
  255. package/dist/installer/targets/types.js.map +1 -0
  256. package/dist/mcp/daemon-paths.d.ts +46 -0
  257. package/dist/mcp/daemon-paths.d.ts.map +1 -0
  258. package/dist/mcp/daemon-paths.js +125 -0
  259. package/dist/mcp/daemon-paths.js.map +1 -0
  260. package/dist/mcp/daemon.d.ts +161 -0
  261. package/dist/mcp/daemon.d.ts.map +1 -0
  262. package/dist/mcp/daemon.js +403 -0
  263. package/dist/mcp/daemon.js.map +1 -0
  264. package/dist/mcp/engine.d.ts +100 -0
  265. package/dist/mcp/engine.d.ts.map +1 -0
  266. package/dist/mcp/engine.js +291 -0
  267. package/dist/mcp/engine.js.map +1 -0
  268. package/dist/mcp/index.d.ts +109 -0
  269. package/dist/mcp/index.d.ts.map +1 -0
  270. package/dist/mcp/index.js +470 -0
  271. package/dist/mcp/index.js.map +1 -0
  272. package/dist/mcp/proxy.d.ts +46 -0
  273. package/dist/mcp/proxy.d.ts.map +1 -0
  274. package/dist/mcp/proxy.js +276 -0
  275. package/dist/mcp/proxy.js.map +1 -0
  276. package/dist/mcp/server-instructions.d.ts +19 -0
  277. package/dist/mcp/server-instructions.d.ts.map +1 -0
  278. package/dist/mcp/server-instructions.js +73 -0
  279. package/dist/mcp/server-instructions.js.map +1 -0
  280. package/dist/mcp/session.d.ts +67 -0
  281. package/dist/mcp/session.d.ts.map +1 -0
  282. package/dist/mcp/session.js +276 -0
  283. package/dist/mcp/session.js.map +1 -0
  284. package/dist/mcp/tools.d.ts +385 -0
  285. package/dist/mcp/tools.d.ts.map +1 -0
  286. package/dist/mcp/tools.js +2545 -0
  287. package/dist/mcp/tools.js.map +1 -0
  288. package/dist/mcp/transport.d.ts +188 -0
  289. package/dist/mcp/transport.d.ts.map +1 -0
  290. package/dist/mcp/transport.js +343 -0
  291. package/dist/mcp/transport.js.map +1 -0
  292. package/dist/mcp/version.d.ts +19 -0
  293. package/dist/mcp/version.d.ts.map +1 -0
  294. package/dist/mcp/version.js +71 -0
  295. package/dist/mcp/version.js.map +1 -0
  296. package/dist/resolution/callback-synthesizer.d.ts +10 -0
  297. package/dist/resolution/callback-synthesizer.d.ts.map +1 -0
  298. package/dist/resolution/callback-synthesizer.js +924 -0
  299. package/dist/resolution/callback-synthesizer.js.map +1 -0
  300. package/dist/resolution/frameworks/cargo-workspace.d.ts +18 -0
  301. package/dist/resolution/frameworks/cargo-workspace.d.ts.map +1 -0
  302. package/dist/resolution/frameworks/cargo-workspace.js +225 -0
  303. package/dist/resolution/frameworks/cargo-workspace.js.map +1 -0
  304. package/dist/resolution/frameworks/csharp.d.ts +8 -0
  305. package/dist/resolution/frameworks/csharp.d.ts.map +1 -0
  306. package/dist/resolution/frameworks/csharp.js +241 -0
  307. package/dist/resolution/frameworks/csharp.js.map +1 -0
  308. package/dist/resolution/frameworks/drupal.d.ts +51 -0
  309. package/dist/resolution/frameworks/drupal.d.ts.map +1 -0
  310. package/dist/resolution/frameworks/drupal.js +367 -0
  311. package/dist/resolution/frameworks/drupal.js.map +1 -0
  312. package/dist/resolution/frameworks/expo-modules.d.ts +3 -0
  313. package/dist/resolution/frameworks/expo-modules.d.ts.map +1 -0
  314. package/dist/resolution/frameworks/expo-modules.js +143 -0
  315. package/dist/resolution/frameworks/expo-modules.js.map +1 -0
  316. package/dist/resolution/frameworks/express.d.ts +8 -0
  317. package/dist/resolution/frameworks/express.d.ts.map +1 -0
  318. package/dist/resolution/frameworks/express.js +308 -0
  319. package/dist/resolution/frameworks/express.js.map +1 -0
  320. package/dist/resolution/frameworks/fabric.d.ts +3 -0
  321. package/dist/resolution/frameworks/fabric.d.ts.map +1 -0
  322. package/dist/resolution/frameworks/fabric.js +354 -0
  323. package/dist/resolution/frameworks/fabric.js.map +1 -0
  324. package/dist/resolution/frameworks/go.d.ts +8 -0
  325. package/dist/resolution/frameworks/go.d.ts.map +1 -0
  326. package/dist/resolution/frameworks/go.js +161 -0
  327. package/dist/resolution/frameworks/go.js.map +1 -0
  328. package/dist/resolution/frameworks/index.d.ts +48 -0
  329. package/dist/resolution/frameworks/index.d.ts.map +1 -0
  330. package/dist/resolution/frameworks/index.js +161 -0
  331. package/dist/resolution/frameworks/index.js.map +1 -0
  332. package/dist/resolution/frameworks/java.d.ts +8 -0
  333. package/dist/resolution/frameworks/java.d.ts.map +1 -0
  334. package/dist/resolution/frameworks/java.js +504 -0
  335. package/dist/resolution/frameworks/java.js.map +1 -0
  336. package/dist/resolution/frameworks/laravel.d.ts +13 -0
  337. package/dist/resolution/frameworks/laravel.d.ts.map +1 -0
  338. package/dist/resolution/frameworks/laravel.js +257 -0
  339. package/dist/resolution/frameworks/laravel.js.map +1 -0
  340. package/dist/resolution/frameworks/nestjs.d.ts +26 -0
  341. package/dist/resolution/frameworks/nestjs.d.ts.map +1 -0
  342. package/dist/resolution/frameworks/nestjs.js +698 -0
  343. package/dist/resolution/frameworks/nestjs.js.map +1 -0
  344. package/dist/resolution/frameworks/play.d.ts +19 -0
  345. package/dist/resolution/frameworks/play.d.ts.map +1 -0
  346. package/dist/resolution/frameworks/play.js +111 -0
  347. package/dist/resolution/frameworks/play.js.map +1 -0
  348. package/dist/resolution/frameworks/python.d.ts +10 -0
  349. package/dist/resolution/frameworks/python.d.ts.map +1 -0
  350. package/dist/resolution/frameworks/python.js +396 -0
  351. package/dist/resolution/frameworks/python.js.map +1 -0
  352. package/dist/resolution/frameworks/react-native.d.ts +3 -0
  353. package/dist/resolution/frameworks/react-native.d.ts.map +1 -0
  354. package/dist/resolution/frameworks/react-native.js +360 -0
  355. package/dist/resolution/frameworks/react-native.js.map +1 -0
  356. package/dist/resolution/frameworks/react.d.ts +8 -0
  357. package/dist/resolution/frameworks/react.d.ts.map +1 -0
  358. package/dist/resolution/frameworks/react.js +365 -0
  359. package/dist/resolution/frameworks/react.js.map +1 -0
  360. package/dist/resolution/frameworks/ruby.d.ts +8 -0
  361. package/dist/resolution/frameworks/ruby.d.ts.map +1 -0
  362. package/dist/resolution/frameworks/ruby.js +302 -0
  363. package/dist/resolution/frameworks/ruby.js.map +1 -0
  364. package/dist/resolution/frameworks/rust.d.ts +8 -0
  365. package/dist/resolution/frameworks/rust.d.ts.map +1 -0
  366. package/dist/resolution/frameworks/rust.js +304 -0
  367. package/dist/resolution/frameworks/rust.js.map +1 -0
  368. package/dist/resolution/frameworks/svelte.d.ts +9 -0
  369. package/dist/resolution/frameworks/svelte.d.ts.map +1 -0
  370. package/dist/resolution/frameworks/svelte.js +249 -0
  371. package/dist/resolution/frameworks/svelte.js.map +1 -0
  372. package/dist/resolution/frameworks/swift-objc.d.ts +37 -0
  373. package/dist/resolution/frameworks/swift-objc.d.ts.map +1 -0
  374. package/dist/resolution/frameworks/swift-objc.js +252 -0
  375. package/dist/resolution/frameworks/swift-objc.js.map +1 -0
  376. package/dist/resolution/frameworks/swift.d.ts +10 -0
  377. package/dist/resolution/frameworks/swift.d.ts.map +1 -0
  378. package/dist/resolution/frameworks/swift.js +400 -0
  379. package/dist/resolution/frameworks/swift.js.map +1 -0
  380. package/dist/resolution/frameworks/vue.d.ts +9 -0
  381. package/dist/resolution/frameworks/vue.d.ts.map +1 -0
  382. package/dist/resolution/frameworks/vue.js +306 -0
  383. package/dist/resolution/frameworks/vue.js.map +1 -0
  384. package/dist/resolution/go-module.d.ts +26 -0
  385. package/dist/resolution/go-module.d.ts.map +1 -0
  386. package/dist/resolution/go-module.js +78 -0
  387. package/dist/resolution/go-module.js.map +1 -0
  388. package/dist/resolution/import-resolver.d.ts +68 -0
  389. package/dist/resolution/import-resolver.d.ts.map +1 -0
  390. package/dist/resolution/import-resolver.js +1231 -0
  391. package/dist/resolution/import-resolver.js.map +1 -0
  392. package/dist/resolution/index.d.ts +116 -0
  393. package/dist/resolution/index.d.ts.map +1 -0
  394. package/dist/resolution/index.js +878 -0
  395. package/dist/resolution/index.js.map +1 -0
  396. package/dist/resolution/lru-cache.d.ts +24 -0
  397. package/dist/resolution/lru-cache.d.ts.map +1 -0
  398. package/dist/resolution/lru-cache.js +62 -0
  399. package/dist/resolution/lru-cache.js.map +1 -0
  400. package/dist/resolution/name-matcher.d.ts +32 -0
  401. package/dist/resolution/name-matcher.d.ts.map +1 -0
  402. package/dist/resolution/name-matcher.js +596 -0
  403. package/dist/resolution/name-matcher.js.map +1 -0
  404. package/dist/resolution/path-aliases.d.ts +68 -0
  405. package/dist/resolution/path-aliases.d.ts.map +1 -0
  406. package/dist/resolution/path-aliases.js +238 -0
  407. package/dist/resolution/path-aliases.js.map +1 -0
  408. package/dist/resolution/strip-comments.d.ts +27 -0
  409. package/dist/resolution/strip-comments.d.ts.map +1 -0
  410. package/dist/resolution/strip-comments.js +441 -0
  411. package/dist/resolution/strip-comments.js.map +1 -0
  412. package/dist/resolution/swift-objc-bridge.d.ts +134 -0
  413. package/dist/resolution/swift-objc-bridge.d.ts.map +1 -0
  414. package/dist/resolution/swift-objc-bridge.js +256 -0
  415. package/dist/resolution/swift-objc-bridge.js.map +1 -0
  416. package/dist/resolution/types.d.ts +209 -0
  417. package/dist/resolution/types.d.ts.map +1 -0
  418. package/dist/resolution/types.js +8 -0
  419. package/dist/resolution/types.js.map +1 -0
  420. package/dist/search/query-parser.d.ts +57 -0
  421. package/dist/search/query-parser.d.ts.map +1 -0
  422. package/dist/search/query-parser.js +177 -0
  423. package/dist/search/query-parser.js.map +1 -0
  424. package/dist/search/query-utils.d.ts +53 -0
  425. package/dist/search/query-utils.d.ts.map +1 -0
  426. package/dist/search/query-utils.js +350 -0
  427. package/dist/search/query-utils.js.map +1 -0
  428. package/dist/sync/git-hooks.d.ts +45 -0
  429. package/dist/sync/git-hooks.d.ts.map +1 -0
  430. package/dist/sync/git-hooks.js +223 -0
  431. package/dist/sync/git-hooks.js.map +1 -0
  432. package/dist/sync/index.d.ts +19 -0
  433. package/dist/sync/index.d.ts.map +1 -0
  434. package/dist/sync/index.js +35 -0
  435. package/dist/sync/index.js.map +1 -0
  436. package/dist/sync/watch-policy.d.ts +48 -0
  437. package/dist/sync/watch-policy.d.ts.map +1 -0
  438. package/dist/sync/watch-policy.js +124 -0
  439. package/dist/sync/watch-policy.js.map +1 -0
  440. package/dist/sync/watcher.d.ts +191 -0
  441. package/dist/sync/watcher.d.ts.map +1 -0
  442. package/dist/sync/watcher.js +398 -0
  443. package/dist/sync/watcher.js.map +1 -0
  444. package/dist/sync/worktree.d.ts +54 -0
  445. package/dist/sync/worktree.d.ts.map +1 -0
  446. package/dist/sync/worktree.js +136 -0
  447. package/dist/sync/worktree.js.map +1 -0
  448. package/dist/types.d.ts +369 -0
  449. package/dist/types.d.ts.map +1 -0
  450. package/dist/types.js +78 -0
  451. package/dist/types.js.map +1 -0
  452. package/dist/ui/glyphs.d.ts +42 -0
  453. package/dist/ui/glyphs.d.ts.map +1 -0
  454. package/dist/ui/glyphs.js +78 -0
  455. package/dist/ui/glyphs.js.map +1 -0
  456. package/dist/ui/shimmer-progress.d.ts +11 -0
  457. package/dist/ui/shimmer-progress.d.ts.map +1 -0
  458. package/dist/ui/shimmer-progress.js +90 -0
  459. package/dist/ui/shimmer-progress.js.map +1 -0
  460. package/dist/ui/shimmer-worker.d.ts +2 -0
  461. package/dist/ui/shimmer-worker.d.ts.map +1 -0
  462. package/dist/ui/shimmer-worker.js +118 -0
  463. package/dist/ui/shimmer-worker.js.map +1 -0
  464. package/dist/ui/types.d.ts +17 -0
  465. package/dist/ui/types.d.ts.map +1 -0
  466. package/dist/ui/types.js +3 -0
  467. package/dist/ui/types.js.map +1 -0
  468. package/dist/utils.d.ts +205 -0
  469. package/dist/utils.d.ts.map +1 -0
  470. package/dist/utils.js +549 -0
  471. package/dist/utils.js.map +1 -0
  472. package/package.json +59 -0
  473. package/scripts/add-lang/bench.sh +60 -0
  474. package/scripts/add-lang/check-grammar.mjs +75 -0
  475. package/scripts/add-lang/dump-ast.mjs +103 -0
  476. package/scripts/add-lang/verify-extraction.mjs +70 -0
  477. package/scripts/agent-eval/arms-F.sh +21 -0
  478. package/scripts/agent-eval/arms-matrix.sh +37 -0
  479. package/scripts/agent-eval/audit.sh +68 -0
  480. package/scripts/agent-eval/bench-readme.sh +28 -0
  481. package/scripts/agent-eval/block-read-hook.sh +19 -0
  482. package/scripts/agent-eval/hook-settings.json +15 -0
  483. package/scripts/agent-eval/itrun.sh +107 -0
  484. package/scripts/agent-eval/parse-arms.mjs +116 -0
  485. package/scripts/agent-eval/parse-bench-readme.mjs +67 -0
  486. package/scripts/agent-eval/parse-run.mjs +45 -0
  487. package/scripts/agent-eval/parse-session.mjs +93 -0
  488. package/scripts/agent-eval/probe-context.mjs +21 -0
  489. package/scripts/agent-eval/probe-explore.mjs +40 -0
  490. package/scripts/agent-eval/probe-node.mjs +20 -0
  491. package/scripts/agent-eval/probe-trace.mjs +20 -0
  492. package/scripts/agent-eval/run-agent.sh +34 -0
  493. package/scripts/agent-eval/run-all.sh +67 -0
  494. package/scripts/agent-eval/run-arms.sh +56 -0
  495. package/scripts/agent-eval/seq-matrix.mjs +137 -0
  496. package/scripts/build-bundle.sh +118 -0
  497. package/scripts/extract-release-notes.mjs +130 -0
  498. package/scripts/local-install.sh +41 -0
  499. package/scripts/npm-shim.js +246 -0
  500. package/scripts/pack-npm.sh +95 -0
  501. package/scripts/prepare-release.mjs +270 -0
@@ -0,0 +1,35 @@
1
+ /**
2
+ * Cursor target.
3
+ *
4
+ * - MCP server entry to `~/.cursor/mcp.json` (global) or
5
+ * `./.cursor/mcp.json` (local). Same `{mcpServers: {...}}` shape
6
+ * as Claude.
7
+ * - Instructions to `./.cursor/rules/codegraph.mdc` (project-local
8
+ * ONLY). Cursor's rules system is a project-scoped surface;
9
+ * global cursor rules aren't a stable convention as of 2026-05.
10
+ * For `--location=global`, only mcp.json is written.
11
+ *
12
+ * ## Why we hardcode `--path` for Cursor
13
+ *
14
+ * Cursor launches MCP-server subprocesses with a working directory
15
+ * that ISN'T the workspace root AND doesn't pass `rootUri` /
16
+ * `workspaceFolders` in the MCP initialize call. The codegraph MCP
17
+ * server's `process.cwd()` fallback therefore misses the workspace's
18
+ * `.codegraph/` and reports "not initialized" on every tool call.
19
+ *
20
+ * So we inject `--path` into the args ourselves:
21
+ *
22
+ * - `local` install: absolute path (we know it at install time).
23
+ * - `global` install: `${workspaceFolder}` — Cursor expands this to
24
+ * the open workspace's root, giving us per-workspace behavior
25
+ * from a single global config.
26
+ *
27
+ * Codex and Claude do not need this — they launch MCP servers with
28
+ * `cwd = workspace` and pass `rootUri`, respectively.
29
+ *
30
+ * No permissions concept — Cursor doesn't have an auto-allow list
31
+ * the installer can populate. `autoAllow` is silently ignored.
32
+ */
33
+ import { AgentTarget } from './types';
34
+ export declare const cursorTarget: AgentTarget;
35
+ //# sourceMappingURL=cursor.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cursor.d.ts","sourceRoot":"","sources":["../../../src/installer/targets/cursor.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAKH,OAAO,EACL,WAAW,EAKZ,MAAM,SAAS,CAAC;AAuPjB,eAAO,MAAM,YAAY,EAAE,WAAgC,CAAC"}
@@ -0,0 +1,283 @@
1
+ "use strict";
2
+ /**
3
+ * Cursor target.
4
+ *
5
+ * - MCP server entry to `~/.cursor/mcp.json` (global) or
6
+ * `./.cursor/mcp.json` (local). Same `{mcpServers: {...}}` shape
7
+ * as Claude.
8
+ * - Instructions to `./.cursor/rules/codegraph.mdc` (project-local
9
+ * ONLY). Cursor's rules system is a project-scoped surface;
10
+ * global cursor rules aren't a stable convention as of 2026-05.
11
+ * For `--location=global`, only mcp.json is written.
12
+ *
13
+ * ## Why we hardcode `--path` for Cursor
14
+ *
15
+ * Cursor launches MCP-server subprocesses with a working directory
16
+ * that ISN'T the workspace root AND doesn't pass `rootUri` /
17
+ * `workspaceFolders` in the MCP initialize call. The codegraph MCP
18
+ * server's `process.cwd()` fallback therefore misses the workspace's
19
+ * `.codegraph/` and reports "not initialized" on every tool call.
20
+ *
21
+ * So we inject `--path` into the args ourselves:
22
+ *
23
+ * - `local` install: absolute path (we know it at install time).
24
+ * - `global` install: `${workspaceFolder}` — Cursor expands this to
25
+ * the open workspace's root, giving us per-workspace behavior
26
+ * from a single global config.
27
+ *
28
+ * Codex and Claude do not need this — they launch MCP servers with
29
+ * `cwd = workspace` and pass `rootUri`, respectively.
30
+ *
31
+ * No permissions concept — Cursor doesn't have an auto-allow list
32
+ * the installer can populate. `autoAllow` is silently ignored.
33
+ */
34
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
35
+ if (k2 === undefined) k2 = k;
36
+ var desc = Object.getOwnPropertyDescriptor(m, k);
37
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
38
+ desc = { enumerable: true, get: function() { return m[k]; } };
39
+ }
40
+ Object.defineProperty(o, k2, desc);
41
+ }) : (function(o, m, k, k2) {
42
+ if (k2 === undefined) k2 = k;
43
+ o[k2] = m[k];
44
+ }));
45
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
46
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
47
+ }) : function(o, v) {
48
+ o["default"] = v;
49
+ });
50
+ var __importStar = (this && this.__importStar) || (function () {
51
+ var ownKeys = function(o) {
52
+ ownKeys = Object.getOwnPropertyNames || function (o) {
53
+ var ar = [];
54
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
55
+ return ar;
56
+ };
57
+ return ownKeys(o);
58
+ };
59
+ return function (mod) {
60
+ if (mod && mod.__esModule) return mod;
61
+ var result = {};
62
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
63
+ __setModuleDefault(result, mod);
64
+ return result;
65
+ };
66
+ })();
67
+ Object.defineProperty(exports, "__esModule", { value: true });
68
+ exports.cursorTarget = void 0;
69
+ const fs = __importStar(require("fs"));
70
+ const path = __importStar(require("path"));
71
+ const os = __importStar(require("os"));
72
+ const shared_1 = require("./shared");
73
+ const instructions_template_1 = require("../instructions-template");
74
+ function mcpJsonPath(loc) {
75
+ return loc === 'global'
76
+ ? path.join(os.homedir(), '.cursor', 'mcp.json')
77
+ : path.join(process.cwd(), '.cursor', 'mcp.json');
78
+ }
79
+ /**
80
+ * Cursor "rules" file. Only meaningful for the project-local
81
+ * location — Cursor reads `.cursor/rules/*.mdc` from the workspace
82
+ * root. There is no global equivalent.
83
+ */
84
+ function rulesPath() {
85
+ return path.join(process.cwd(), '.cursor', 'rules', 'codegraph.mdc');
86
+ }
87
+ /**
88
+ * Cursor `.mdc` rules use YAML-ish frontmatter. `alwaysApply: true`
89
+ * makes the rule load on every conversation regardless of file
90
+ * patterns — appropriate for a tool-usage guide that's relevant
91
+ * whenever the user is asking the agent to navigate code.
92
+ */
93
+ const MDC_FRONTMATTER = [
94
+ '---',
95
+ 'description: CodeGraph MCP usage guide — when to use which tool',
96
+ 'alwaysApply: true',
97
+ '---',
98
+ '',
99
+ ].join('\n');
100
+ class CursorTarget {
101
+ id = 'cursor';
102
+ displayName = 'Cursor';
103
+ docsUrl = 'https://docs.cursor.com/context/model-context-protocol';
104
+ supportsLocation(_loc) {
105
+ // Both supported, but `local` writes more files (mcp.json + rules);
106
+ // `global` writes only mcp.json. The orchestrator surfaces the
107
+ // difference via describePaths.
108
+ return true;
109
+ }
110
+ detect(loc) {
111
+ const mcpPath = mcpJsonPath(loc);
112
+ const config = (0, shared_1.readJsonFile)(mcpPath);
113
+ const alreadyConfigured = !!config.mcpServers?.codegraph;
114
+ // "Installed" heuristic: does ~/.cursor exist (global) or has the
115
+ // user opted into a project-local cursor config dir?
116
+ const installed = loc === 'global'
117
+ ? fs.existsSync(path.join(os.homedir(), '.cursor'))
118
+ : fs.existsSync(path.join(process.cwd(), '.cursor'));
119
+ return { installed, alreadyConfigured, configPath: mcpPath };
120
+ }
121
+ install(loc, _opts) {
122
+ const files = [];
123
+ files.push(writeMcpEntry(loc));
124
+ if (loc === 'local') {
125
+ files.push(writeRulesEntry());
126
+ }
127
+ return {
128
+ files,
129
+ notes: ['Restart Cursor for MCP changes to take effect.'],
130
+ };
131
+ }
132
+ uninstall(loc) {
133
+ const files = [];
134
+ const mcpPath = mcpJsonPath(loc);
135
+ const config = (0, shared_1.readJsonFile)(mcpPath);
136
+ if (config.mcpServers?.codegraph) {
137
+ delete config.mcpServers.codegraph;
138
+ if (Object.keys(config.mcpServers).length === 0) {
139
+ delete config.mcpServers;
140
+ }
141
+ (0, shared_1.writeJsonFile)(mcpPath, config);
142
+ files.push({ path: mcpPath, action: 'removed' });
143
+ }
144
+ else {
145
+ files.push({ path: mcpPath, action: 'not-found' });
146
+ }
147
+ if (loc === 'local') {
148
+ files.push(removeRulesEntry());
149
+ }
150
+ return { files };
151
+ }
152
+ printConfig(loc) {
153
+ const target = mcpJsonPath(loc);
154
+ const snippet = JSON.stringify({ mcpServers: { codegraph: buildCursorMcpConfig(loc) } }, null, 2);
155
+ return `# Add to ${target}\n\n${snippet}\n`;
156
+ }
157
+ describePaths(loc) {
158
+ return loc === 'local'
159
+ ? [mcpJsonPath(loc), rulesPath()]
160
+ : [mcpJsonPath(loc)];
161
+ }
162
+ /**
163
+ * Write the project-local `.cursor/rules/codegraph.mdc` file. Used
164
+ * by `codegraph init` to bootstrap projects that have only the
165
+ * global `~/.cursor/mcp.json` — without the rules file, the Cursor
166
+ * agent has no signal to prefer codegraph over native grep.
167
+ */
168
+ wireProjectSurfaces() {
169
+ return { files: [writeRulesEntry()] };
170
+ }
171
+ }
172
+ /**
173
+ * Build the codegraph MCP-server config for Cursor at the given
174
+ * location. Inherits the shared shape ({type, command, args}) and
175
+ * appends `--path` so the spawned MCP server resolves the workspace
176
+ * correctly regardless of Cursor's launch cwd. See file header for
177
+ * the full rationale.
178
+ */
179
+ function buildCursorMcpConfig(loc) {
180
+ const base = (0, shared_1.getMcpServerConfig)();
181
+ const pathArg = loc === 'local' ? process.cwd() : '${workspaceFolder}';
182
+ return { ...base, args: [...base.args, '--path', pathArg] };
183
+ }
184
+ function writeMcpEntry(loc) {
185
+ const file = mcpJsonPath(loc);
186
+ const existing = (0, shared_1.readJsonFile)(file);
187
+ const before = existing.mcpServers?.codegraph;
188
+ const after = buildCursorMcpConfig(loc);
189
+ if ((0, shared_1.jsonDeepEqual)(before, after)) {
190
+ return { path: file, action: 'unchanged' };
191
+ }
192
+ const action = before ? 'updated' : (fs.existsSync(file) ? 'updated' : 'created');
193
+ if (!existing.mcpServers)
194
+ existing.mcpServers = {};
195
+ existing.mcpServers.codegraph = after;
196
+ (0, shared_1.writeJsonFile)(file, existing);
197
+ return { path: file, action };
198
+ }
199
+ function writeRulesEntry() {
200
+ const file = rulesPath();
201
+ const dir = path.dirname(file);
202
+ if (!fs.existsSync(dir))
203
+ fs.mkdirSync(dir, { recursive: true });
204
+ // Body is frontmatter + the shared instructions block. The
205
+ // marker-based replacement targets only the marker block, so the
206
+ // frontmatter is preserved across re-runs.
207
+ const body = MDC_FRONTMATTER + instructions_template_1.INSTRUCTIONS_TEMPLATE;
208
+ if (!fs.existsSync(file)) {
209
+ (0, shared_1.atomicWriteFileSync)(file, body + '\n');
210
+ return { path: file, action: 'created' };
211
+ }
212
+ // For .mdc files we own outright, do byte-equality first.
213
+ const existing = fs.readFileSync(file, 'utf-8');
214
+ const wantWithNL = body + '\n';
215
+ if (existing === wantWithNL) {
216
+ return { path: file, action: 'unchanged' };
217
+ }
218
+ // Otherwise, marker-based section swap (preserves any user-added
219
+ // content outside the markers).
220
+ const action = (0, shared_1.replaceOrAppendMarkedSection)(file, instructions_template_1.INSTRUCTIONS_TEMPLATE, instructions_template_1.CODEGRAPH_SECTION_START, instructions_template_1.CODEGRAPH_SECTION_END);
221
+ const mapped = action === 'created' ? 'created'
222
+ : action === 'unchanged' ? 'unchanged'
223
+ : 'updated';
224
+ return { path: file, action: mapped };
225
+ }
226
+ /**
227
+ * Remove the Cursor rules file on uninstall.
228
+ *
229
+ * Unlike the shared CLAUDE.md / AGENTS.md files (where codegraph owns
230
+ * only a marker-delimited section), `.cursor/rules/codegraph.mdc` is a
231
+ * file we create OUTRIGHT — the frontmatter is ours too. So a plain
232
+ * `removeMarkedSection` is wrong here: it would strip our instruction
233
+ * block but leave the orphaned `description: CodeGraph ...` frontmatter
234
+ * behind, so the file lingers and still "mentions" codegraph.
235
+ *
236
+ * Instead: strip our block, and if nothing but our own frontmatter
237
+ * remains, delete the whole file. Only when the user has added their
238
+ * own content outside our markers do we keep the file (minus our block).
239
+ */
240
+ function removeRulesEntry() {
241
+ const file = rulesPath();
242
+ if (!fs.existsSync(file))
243
+ return { path: file, action: 'not-found' };
244
+ let content;
245
+ try {
246
+ content = fs.readFileSync(file, 'utf-8');
247
+ }
248
+ catch {
249
+ return { path: file, action: 'not-found' };
250
+ }
251
+ const ourFrontmatter = MDC_FRONTMATTER.trim();
252
+ const startIdx = content.indexOf(instructions_template_1.CODEGRAPH_SECTION_START);
253
+ const endIdx = content.indexOf(instructions_template_1.CODEGRAPH_SECTION_END);
254
+ // Our marked block is present — strip it, then decide what's left.
255
+ if (startIdx !== -1 && endIdx > startIdx) {
256
+ const before = content.substring(0, startIdx).trimEnd();
257
+ const after = content.substring(endIdx + instructions_template_1.CODEGRAPH_SECTION_END.length).trimStart();
258
+ const remainder = (before + (before && after ? '\n\n' : '') + after).trim();
259
+ if (remainder === '' || remainder === ourFrontmatter) {
260
+ try {
261
+ fs.unlinkSync(file);
262
+ }
263
+ catch { /* ignore */ }
264
+ }
265
+ else {
266
+ (0, shared_1.atomicWriteFileSync)(file, remainder + '\n');
267
+ }
268
+ return { path: file, action: 'removed' };
269
+ }
270
+ // No block, but the file is still our pristine frontmatter-only file
271
+ // — it's ours, so remove it.
272
+ if (content.trim() === ourFrontmatter) {
273
+ try {
274
+ fs.unlinkSync(file);
275
+ }
276
+ catch { /* ignore */ }
277
+ return { path: file, action: 'removed' };
278
+ }
279
+ // Foreign content we don't recognize — leave it alone.
280
+ return { path: file, action: 'not-found' };
281
+ }
282
+ exports.cursorTarget = new CursorTarget();
283
+ //# sourceMappingURL=cursor.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"cursor.js","sourceRoot":"","sources":["../../../src/installer/targets/cursor.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2CAA6B;AAC7B,uCAAyB;AAQzB,qCAOkB;AAClB,oEAIkC;AAElC,SAAS,WAAW,CAAC,GAAa;IAChC,OAAO,GAAG,KAAK,QAAQ;QACrB,CAAC,CAAC,IAA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AAW,EAAE,CAAC;AAC7C,CAAC;AAEY,QAAA,YAAY,GAAgB,IAAI,YAAY,EAAE,CAAC"}
@@ -0,0 +1,26 @@
1
+ /**
2
+ * Gemini CLI target (also covers the rebranded "Antigravity CLI" —
3
+ * Google is in the middle of unifying its CLI tools under
4
+ * Antigravity, and the new CLI continues to read `~/.gemini/settings.json`
5
+ * + project-local `.gemini/settings.json`). Writes:
6
+ *
7
+ * - MCP server entry to `~/.gemini/settings.json` (global) or
8
+ * `./.gemini/settings.json` (local) under the standard
9
+ * `mcpServers.codegraph` key. Same shape as Claude / Cursor.
10
+ * - Instructions to `~/.gemini/GEMINI.md` (global) or `./GEMINI.md`
11
+ * (local — Gemini reads the project root file directly, not
12
+ * under `.gemini/`).
13
+ *
14
+ * No permissions concept — Gemini CLI gates tool invocations through
15
+ * the `trust` field per server, not an external allowlist. We leave
16
+ * `trust` unset so the user controls confirmation prompts.
17
+ *
18
+ * The Antigravity IDE shares `~/.gemini/GEMINI.md` for instructions
19
+ * but uses a separate MCP config file (`~/.gemini/antigravity/mcp_config.json`)
20
+ * — see `./antigravity.ts`. Both targets writing to GEMINI.md is
21
+ * safe: the marker-based section replacement makes the second write
22
+ * a byte-identical no-op.
23
+ */
24
+ import { AgentTarget } from './types';
25
+ export declare const geminiTarget: AgentTarget;
26
+ //# sourceMappingURL=gemini.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gemini.d.ts","sourceRoot":"","sources":["../../../src/installer/targets/gemini.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;AAKH,OAAO,EACL,WAAW,EAKZ,MAAM,SAAS,CAAC;AAqIjB,eAAO,MAAM,YAAY,EAAE,WAAgC,CAAC"}
@@ -0,0 +1,165 @@
1
+ "use strict";
2
+ /**
3
+ * Gemini CLI target (also covers the rebranded "Antigravity CLI" —
4
+ * Google is in the middle of unifying its CLI tools under
5
+ * Antigravity, and the new CLI continues to read `~/.gemini/settings.json`
6
+ * + project-local `.gemini/settings.json`). Writes:
7
+ *
8
+ * - MCP server entry to `~/.gemini/settings.json` (global) or
9
+ * `./.gemini/settings.json` (local) under the standard
10
+ * `mcpServers.codegraph` key. Same shape as Claude / Cursor.
11
+ * - Instructions to `~/.gemini/GEMINI.md` (global) or `./GEMINI.md`
12
+ * (local — Gemini reads the project root file directly, not
13
+ * under `.gemini/`).
14
+ *
15
+ * No permissions concept — Gemini CLI gates tool invocations through
16
+ * the `trust` field per server, not an external allowlist. We leave
17
+ * `trust` unset so the user controls confirmation prompts.
18
+ *
19
+ * The Antigravity IDE shares `~/.gemini/GEMINI.md` for instructions
20
+ * but uses a separate MCP config file (`~/.gemini/antigravity/mcp_config.json`)
21
+ * — see `./antigravity.ts`. Both targets writing to GEMINI.md is
22
+ * safe: the marker-based section replacement makes the second write
23
+ * a byte-identical no-op.
24
+ */
25
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
26
+ if (k2 === undefined) k2 = k;
27
+ var desc = Object.getOwnPropertyDescriptor(m, k);
28
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
29
+ desc = { enumerable: true, get: function() { return m[k]; } };
30
+ }
31
+ Object.defineProperty(o, k2, desc);
32
+ }) : (function(o, m, k, k2) {
33
+ if (k2 === undefined) k2 = k;
34
+ o[k2] = m[k];
35
+ }));
36
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
37
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
38
+ }) : function(o, v) {
39
+ o["default"] = v;
40
+ });
41
+ var __importStar = (this && this.__importStar) || (function () {
42
+ var ownKeys = function(o) {
43
+ ownKeys = Object.getOwnPropertyNames || function (o) {
44
+ var ar = [];
45
+ for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
46
+ return ar;
47
+ };
48
+ return ownKeys(o);
49
+ };
50
+ return function (mod) {
51
+ if (mod && mod.__esModule) return mod;
52
+ var result = {};
53
+ if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
54
+ __setModuleDefault(result, mod);
55
+ return result;
56
+ };
57
+ })();
58
+ Object.defineProperty(exports, "__esModule", { value: true });
59
+ exports.geminiTarget = void 0;
60
+ const fs = __importStar(require("fs"));
61
+ const path = __importStar(require("path"));
62
+ const os = __importStar(require("os"));
63
+ const shared_1 = require("./shared");
64
+ const instructions_template_1 = require("../instructions-template");
65
+ function configDir(loc) {
66
+ return loc === 'global'
67
+ ? path.join(os.homedir(), '.gemini')
68
+ : path.join(process.cwd(), '.gemini');
69
+ }
70
+ function settingsJsonPath(loc) {
71
+ return path.join(configDir(loc), 'settings.json');
72
+ }
73
+ function instructionsPath(loc) {
74
+ // Global GEMINI.md lives under ~/.gemini/; project-local GEMINI.md
75
+ // lives at the project root (NOT under .gemini/), matching how
76
+ // Gemini CLI's hierarchical context loader searches.
77
+ return loc === 'global'
78
+ ? path.join(configDir('global'), 'GEMINI.md')
79
+ : path.join(process.cwd(), 'GEMINI.md');
80
+ }
81
+ class GeminiTarget {
82
+ id = 'gemini';
83
+ displayName = 'Gemini CLI';
84
+ docsUrl = 'https://geminicli.com/docs/tools/mcp-server/';
85
+ supportsLocation(_loc) {
86
+ return true;
87
+ }
88
+ detect(loc) {
89
+ const file = settingsJsonPath(loc);
90
+ const config = (0, shared_1.readJsonFile)(file);
91
+ const alreadyConfigured = !!config.mcpServers?.codegraph;
92
+ const installed = loc === 'global'
93
+ ? fs.existsSync(configDir('global')) || fs.existsSync(file)
94
+ : fs.existsSync(file) || fs.existsSync(configDir('local'));
95
+ return { installed, alreadyConfigured, configPath: file };
96
+ }
97
+ install(loc, _opts) {
98
+ const files = [];
99
+ files.push(writeMcpEntry(loc));
100
+ files.push(writeInstructionsEntry(loc));
101
+ return { files };
102
+ }
103
+ uninstall(loc) {
104
+ const files = [];
105
+ const file = settingsJsonPath(loc);
106
+ const config = (0, shared_1.readJsonFile)(file);
107
+ if (config.mcpServers?.codegraph) {
108
+ delete config.mcpServers.codegraph;
109
+ if (Object.keys(config.mcpServers).length === 0) {
110
+ delete config.mcpServers;
111
+ }
112
+ // If the file is now an empty `{}` we still leave it — other
113
+ // (top-level) Gemini settings the user might add later can
114
+ // share the file; deleting it would be surprising.
115
+ (0, shared_1.writeJsonFile)(file, config);
116
+ files.push({ path: file, action: 'removed' });
117
+ }
118
+ else {
119
+ files.push({ path: file, action: 'not-found' });
120
+ }
121
+ const instr = instructionsPath(loc);
122
+ const action = (0, shared_1.removeMarkedSection)(instr, instructions_template_1.CODEGRAPH_SECTION_START, instructions_template_1.CODEGRAPH_SECTION_END);
123
+ files.push({ path: instr, action });
124
+ return { files };
125
+ }
126
+ printConfig(loc) {
127
+ const target = settingsJsonPath(loc);
128
+ const snippet = JSON.stringify({ mcpServers: { codegraph: (0, shared_1.getMcpServerConfig)() } }, null, 2);
129
+ return `# Add to ${target}\n\n${snippet}\n`;
130
+ }
131
+ describePaths(loc) {
132
+ return [settingsJsonPath(loc), instructionsPath(loc)];
133
+ }
134
+ }
135
+ function writeMcpEntry(loc) {
136
+ const file = settingsJsonPath(loc);
137
+ const dir = path.dirname(file);
138
+ if (!fs.existsSync(dir))
139
+ fs.mkdirSync(dir, { recursive: true });
140
+ const existing = (0, shared_1.readJsonFile)(file);
141
+ const before = existing.mcpServers?.codegraph;
142
+ const after = (0, shared_1.getMcpServerConfig)();
143
+ if ((0, shared_1.jsonDeepEqual)(before, after)) {
144
+ return { path: file, action: 'unchanged' };
145
+ }
146
+ const action = before ? 'updated' : (fs.existsSync(file) ? 'updated' : 'created');
147
+ if (!existing.mcpServers)
148
+ existing.mcpServers = {};
149
+ existing.mcpServers.codegraph = after;
150
+ (0, shared_1.writeJsonFile)(file, existing);
151
+ return { path: file, action };
152
+ }
153
+ function writeInstructionsEntry(loc) {
154
+ const file = instructionsPath(loc);
155
+ const dir = path.dirname(file);
156
+ if (!fs.existsSync(dir))
157
+ fs.mkdirSync(dir, { recursive: true });
158
+ const action = (0, shared_1.replaceOrAppendMarkedSection)(file, instructions_template_1.INSTRUCTIONS_TEMPLATE, instructions_template_1.CODEGRAPH_SECTION_START, instructions_template_1.CODEGRAPH_SECTION_END);
159
+ const mapped = action === 'created' ? 'created'
160
+ : action === 'unchanged' ? 'unchanged'
161
+ : 'updated';
162
+ return { path: file, action: mapped };
163
+ }
164
+ exports.geminiTarget = new GeminiTarget();
165
+ //# sourceMappingURL=gemini.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"gemini.js","sourceRoot":"","sources":["../../../src/installer/targets/gemini.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;;;;;;;;GAsBG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEH,uCAAyB;AACzB,2CAA6B;AAC7B,uCAAyB;AAQzB,qCAOkB;AAClB,oEAIkC;AAElC,SAAS,SAAS,CAAC,GAAa;IAC9B,OAAO,GAAG,KAAK,QAAQ;QACrB,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,OAAO,EAAE,EAAE,SAAS,CAAC;QACpC,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,SAAS,CAAC,CAAC;AAC1C,CAAC;AACD,SAAS,gBAAgB,CAAC,GAAa;IACrC,OAAO,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,EAAE,eAAe,CAAC,CAAC;AACpD,CAAC;AACD,SAAS,gBAAgB,CAAC,GAAa;IACrC,mEAAmE;IACnE,+DAA+D;IAC/D,qDAAqD;IACrD,OAAO,GAAG,KAAK,QAAQ;QACrB,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,SAAS,CAAC,QAAQ,CAAC,EAAE,WAAW,CAAC;QAC7C,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,GAAG,EAAE,EAAE,WAAW,CAAC,CAAC;AAC5C,CAAC;AAED,MAAM,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CAAC,EAAE,CAAC,UAAU,CAAC,GAAG,CAAC;QAAE,EAAE,CAAC,SAAS,CAAC,GAAG,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,CAAC,CAAC;IAEhE,MAAM,MAAM,GAAG,IAAA,qCAA4B,EACzC,IAAI,EACJ,6CAAqB,EACrB,+CAAuB,EACvB,6CAAqB,CACtB,CAAC;IACF,MAAM,MAAM,GACV,MAAM,KAAK,SAAS,CAAC,CAAC,CAAC,SAAS;QAC9B,CAAC,CAAC,MAAM,KAAK,WAAW,CAAC,CAAC,CAAC,WAAW;YACpC,CAAC,CAAC,SAAS,CAAC;IAClB,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,MAAM,EAAE,CAAC;AACxC,CAAC;AAEY,QAAA,YAAY,GAAgB,IAAI,YAAY,EAAE,CAAC"}
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Hermes Agent target.
3
+ *
4
+ * Hermes reads MCP servers from `$HERMES_HOME/config.yaml` under the
5
+ * top-level `mcp_servers` key, and exposes discovered MCP tools through
6
+ * dynamic toolsets named `mcp-<server>`. We add:
7
+ *
8
+ * mcp_servers.codegraph -> `codegraph serve --mcp`
9
+ * platform_toolsets.cli -> `mcp-codegraph`
10
+ *
11
+ * The second entry matters because Hermes CLI profiles often enable an
12
+ * explicit `platform_toolsets.cli` list. Without `mcp-codegraph` in that
13
+ * list, the MCP server can be configured and connected but its tools may
14
+ * still be filtered out of normal CLI sessions.
15
+ */
16
+ import { AgentTarget } from './types';
17
+ export declare const hermesTarget: AgentTarget;
18
+ //# sourceMappingURL=hermes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"hermes.d.ts","sourceRoot":"","sources":["../../../src/installer/targets/hermes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAKH,OAAO,EACL,WAAW,EAKZ,MAAM,SAAS,CAAC;AA0UjB,eAAO,MAAM,YAAY,EAAE,WAAgC,CAAC"}