gsd-pi 2.34.0-dev.ed0bfbf → 2.35.0-dev.30eec3f

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 (334) hide show
  1. package/dist/cli.js +7 -2
  2. package/dist/resource-loader.d.ts +1 -1
  3. package/dist/resource-loader.js +13 -1
  4. package/dist/resources/extensions/async-jobs/await-tool.js +0 -2
  5. package/dist/resources/extensions/async-jobs/job-manager.js +0 -6
  6. package/dist/resources/extensions/bg-shell/output-formatter.js +1 -19
  7. package/dist/resources/extensions/bg-shell/process-manager.js +0 -4
  8. package/dist/resources/extensions/bg-shell/types.js +0 -2
  9. package/dist/resources/extensions/context7/index.js +5 -0
  10. package/dist/resources/extensions/get-secrets-from-user.js +2 -30
  11. package/dist/resources/extensions/google-search/index.js +5 -0
  12. package/dist/resources/extensions/gsd/auto-dispatch.js +43 -1
  13. package/dist/resources/extensions/gsd/auto-loop.js +10 -1
  14. package/dist/resources/extensions/gsd/auto-recovery.js +35 -0
  15. package/dist/resources/extensions/gsd/auto-start.js +35 -2
  16. package/dist/resources/extensions/gsd/auto.js +59 -4
  17. package/dist/resources/extensions/gsd/changelog.js +162 -0
  18. package/dist/resources/extensions/gsd/commands-bootstrap.js +1 -0
  19. package/dist/resources/extensions/gsd/commands-handlers.js +2 -2
  20. package/dist/resources/extensions/gsd/commands-inspect.js +10 -3
  21. package/dist/resources/extensions/gsd/commands-prefs-wizard.js +5 -1
  22. package/dist/resources/extensions/gsd/commands.js +8 -1
  23. package/dist/resources/extensions/gsd/docs/preferences-reference.md +10 -0
  24. package/dist/resources/extensions/gsd/doctor-checks.js +113 -5
  25. package/dist/resources/extensions/gsd/doctor-environment.js +26 -17
  26. package/dist/resources/extensions/gsd/doctor-proactive.js +22 -0
  27. package/dist/resources/extensions/gsd/doctor.js +36 -0
  28. package/dist/resources/extensions/gsd/files.js +11 -2
  29. package/dist/resources/extensions/gsd/gitignore.js +54 -7
  30. package/dist/resources/extensions/gsd/guided-flow.js +5 -3
  31. package/dist/resources/extensions/gsd/health-widget-core.js +96 -0
  32. package/dist/resources/extensions/gsd/health-widget.js +97 -46
  33. package/dist/resources/extensions/gsd/index.js +10 -1
  34. package/dist/resources/extensions/gsd/migrate-external.js +55 -2
  35. package/dist/resources/extensions/gsd/paths.js +74 -7
  36. package/dist/resources/extensions/gsd/post-unit-hooks.js +4 -1
  37. package/dist/resources/extensions/gsd/preferences-validation.js +54 -1
  38. package/dist/resources/extensions/gsd/preferences.js +2 -0
  39. package/dist/resources/extensions/gsd/prompts/complete-milestone.md +2 -0
  40. package/dist/resources/extensions/gsd/prompts/validate-milestone.md +2 -0
  41. package/dist/resources/extensions/gsd/roadmap-mutations.js +55 -0
  42. package/dist/resources/extensions/gsd/session-lock.js +26 -2
  43. package/dist/resources/extensions/gsd/templates/plan.md +8 -0
  44. package/dist/resources/extensions/gsd/worktree-resolver.js +12 -0
  45. package/dist/resources/extensions/remote-questions/remote-command.js +2 -22
  46. package/dist/resources/extensions/shared/mod.js +1 -1
  47. package/dist/resources/extensions/shared/sanitize.js +30 -0
  48. package/dist/resources/extensions/subagent/index.js +6 -14
  49. package/dist/resources/skills/create-gsd-extension/references/events-reference.md +4 -4
  50. package/package.json +2 -1
  51. package/packages/pi-agent-core/dist/agent-loop.d.ts +14 -0
  52. package/packages/pi-agent-core/dist/agent-loop.d.ts.map +1 -1
  53. package/packages/pi-agent-core/dist/agent-loop.js +24 -27
  54. package/packages/pi-agent-core/dist/agent-loop.js.map +1 -1
  55. package/packages/pi-agent-core/dist/agent.d.ts +1 -0
  56. package/packages/pi-agent-core/dist/agent.d.ts.map +1 -1
  57. package/packages/pi-agent-core/dist/agent.js +11 -22
  58. package/packages/pi-agent-core/dist/agent.js.map +1 -1
  59. package/packages/pi-agent-core/dist/proxy.d.ts.map +1 -1
  60. package/packages/pi-agent-core/dist/proxy.js +2 -8
  61. package/packages/pi-agent-core/dist/proxy.js.map +1 -1
  62. package/packages/pi-agent-core/src/agent-loop.ts +30 -27
  63. package/packages/pi-agent-core/src/agent.ts +12 -23
  64. package/packages/pi-agent-core/src/proxy.ts +2 -8
  65. package/packages/pi-ai/dist/providers/azure-openai-responses.d.ts.map +1 -1
  66. package/packages/pi-ai/dist/providers/azure-openai-responses.js +5 -41
  67. package/packages/pi-ai/dist/providers/azure-openai-responses.js.map +1 -1
  68. package/packages/pi-ai/dist/providers/openai-completions.d.ts.map +1 -1
  69. package/packages/pi-ai/dist/providers/openai-completions.js +10 -73
  70. package/packages/pi-ai/dist/providers/openai-completions.js.map +1 -1
  71. package/packages/pi-ai/dist/providers/openai-responses.d.ts.map +1 -1
  72. package/packages/pi-ai/dist/providers/openai-responses.js +9 -80
  73. package/packages/pi-ai/dist/providers/openai-responses.js.map +1 -1
  74. package/packages/pi-ai/dist/providers/openai-shared.d.ts +65 -0
  75. package/packages/pi-ai/dist/providers/openai-shared.d.ts.map +1 -0
  76. package/packages/pi-ai/dist/providers/openai-shared.js +146 -0
  77. package/packages/pi-ai/dist/providers/openai-shared.js.map +1 -0
  78. package/packages/pi-ai/dist/utils/oauth/google-antigravity.d.ts.map +1 -1
  79. package/packages/pi-ai/dist/utils/oauth/google-antigravity.js +7 -135
  80. package/packages/pi-ai/dist/utils/oauth/google-antigravity.js.map +1 -1
  81. package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.d.ts.map +1 -1
  82. package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.js +7 -135
  83. package/packages/pi-ai/dist/utils/oauth/google-gemini-cli.js.map +1 -1
  84. package/packages/pi-ai/dist/utils/oauth/google-oauth-utils.d.ts +46 -0
  85. package/packages/pi-ai/dist/utils/oauth/google-oauth-utils.d.ts.map +1 -0
  86. package/packages/pi-ai/dist/utils/oauth/google-oauth-utils.js +160 -0
  87. package/packages/pi-ai/dist/utils/oauth/google-oauth-utils.js.map +1 -0
  88. package/packages/pi-ai/src/providers/azure-openai-responses.ts +11 -45
  89. package/packages/pi-ai/src/providers/openai-completions.ts +16 -86
  90. package/packages/pi-ai/src/providers/openai-responses.ts +16 -96
  91. package/packages/pi-ai/src/providers/openai-shared.ts +193 -0
  92. package/packages/pi-ai/src/utils/oauth/google-antigravity.ts +14 -162
  93. package/packages/pi-ai/src/utils/oauth/google-gemini-cli.ts +13 -161
  94. package/packages/pi-ai/src/utils/oauth/google-oauth-utils.ts +201 -0
  95. package/packages/pi-coding-agent/dist/core/agent-session.d.ts +16 -63
  96. package/packages/pi-coding-agent/dist/core/agent-session.d.ts.map +1 -1
  97. package/packages/pi-coding-agent/dist/core/agent-session.js +104 -641
  98. package/packages/pi-coding-agent/dist/core/agent-session.js.map +1 -1
  99. package/packages/pi-coding-agent/dist/core/auth-storage.d.ts +0 -1
  100. package/packages/pi-coding-agent/dist/core/auth-storage.d.ts.map +1 -1
  101. package/packages/pi-coding-agent/dist/core/auth-storage.js +4 -35
  102. package/packages/pi-coding-agent/dist/core/auth-storage.js.map +1 -1
  103. package/packages/pi-coding-agent/dist/core/compaction/branch-summarization.d.ts.map +1 -1
  104. package/packages/pi-coding-agent/dist/core/compaction/branch-summarization.js +5 -43
  105. package/packages/pi-coding-agent/dist/core/compaction/branch-summarization.js.map +1 -1
  106. package/packages/pi-coding-agent/dist/core/compaction/compaction.d.ts.map +1 -1
  107. package/packages/pi-coding-agent/dist/core/compaction/compaction.js +11 -69
  108. package/packages/pi-coding-agent/dist/core/compaction/compaction.js.map +1 -1
  109. package/packages/pi-coding-agent/dist/core/compaction/utils.d.ts +40 -0
  110. package/packages/pi-coding-agent/dist/core/compaction/utils.d.ts.map +1 -1
  111. package/packages/pi-coding-agent/dist/core/compaction/utils.js +78 -0
  112. package/packages/pi-coding-agent/dist/core/compaction/utils.js.map +1 -1
  113. package/packages/pi-coding-agent/dist/core/compaction-orchestrator.d.ts +77 -0
  114. package/packages/pi-coding-agent/dist/core/compaction-orchestrator.d.ts.map +1 -0
  115. package/packages/pi-coding-agent/dist/core/compaction-orchestrator.js +331 -0
  116. package/packages/pi-coding-agent/dist/core/compaction-orchestrator.js.map +1 -0
  117. package/packages/pi-coding-agent/dist/core/extensions/index.d.ts +2 -2
  118. package/packages/pi-coding-agent/dist/core/extensions/index.d.ts.map +1 -1
  119. package/packages/pi-coding-agent/dist/core/extensions/index.js +1 -1
  120. package/packages/pi-coding-agent/dist/core/extensions/index.js.map +1 -1
  121. package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts +15 -0
  122. package/packages/pi-coding-agent/dist/core/extensions/runner.d.ts.map +1 -1
  123. package/packages/pi-coding-agent/dist/core/extensions/runner.js +129 -243
  124. package/packages/pi-coding-agent/dist/core/extensions/runner.js.map +1 -1
  125. package/packages/pi-coding-agent/dist/core/extensions/types.d.ts +49 -42
  126. package/packages/pi-coding-agent/dist/core/extensions/types.d.ts.map +1 -1
  127. package/packages/pi-coding-agent/dist/core/extensions/types.js +2 -21
  128. package/packages/pi-coding-agent/dist/core/extensions/types.js.map +1 -1
  129. package/packages/pi-coding-agent/dist/core/lock-utils.d.ts +39 -0
  130. package/packages/pi-coding-agent/dist/core/lock-utils.d.ts.map +1 -0
  131. package/packages/pi-coding-agent/dist/core/lock-utils.js +89 -0
  132. package/packages/pi-coding-agent/dist/core/lock-utils.js.map +1 -0
  133. package/packages/pi-coding-agent/dist/core/lsp/config.d.ts +2 -0
  134. package/packages/pi-coding-agent/dist/core/lsp/config.d.ts.map +1 -1
  135. package/packages/pi-coding-agent/dist/core/lsp/config.js +4 -1
  136. package/packages/pi-coding-agent/dist/core/lsp/config.js.map +1 -1
  137. package/packages/pi-coding-agent/dist/core/lsp/index.d.ts.map +1 -1
  138. package/packages/pi-coding-agent/dist/core/lsp/index.js +52 -107
  139. package/packages/pi-coding-agent/dist/core/lsp/index.js.map +1 -1
  140. package/packages/pi-coding-agent/dist/core/lsp/lspmux.d.ts.map +1 -1
  141. package/packages/pi-coding-agent/dist/core/lsp/lspmux.js +2 -21
  142. package/packages/pi-coding-agent/dist/core/lsp/lspmux.js.map +1 -1
  143. package/packages/pi-coding-agent/dist/core/lsp/types.d.ts +0 -1
  144. package/packages/pi-coding-agent/dist/core/lsp/types.d.ts.map +1 -1
  145. package/packages/pi-coding-agent/dist/core/lsp/types.js +0 -28
  146. package/packages/pi-coding-agent/dist/core/lsp/types.js.map +1 -1
  147. package/packages/pi-coding-agent/dist/core/package-manager.d.ts.map +1 -1
  148. package/packages/pi-coding-agent/dist/core/package-manager.js +2 -4
  149. package/packages/pi-coding-agent/dist/core/package-manager.js.map +1 -1
  150. package/packages/pi-coding-agent/dist/core/resource-loader.d.ts +2 -4
  151. package/packages/pi-coding-agent/dist/core/resource-loader.d.ts.map +1 -1
  152. package/packages/pi-coding-agent/dist/core/resource-loader.js +46 -60
  153. package/packages/pi-coding-agent/dist/core/resource-loader.js.map +1 -1
  154. package/packages/pi-coding-agent/dist/core/retry-handler.d.ts +87 -0
  155. package/packages/pi-coding-agent/dist/core/retry-handler.d.ts.map +1 -0
  156. package/packages/pi-coding-agent/dist/core/retry-handler.js +295 -0
  157. package/packages/pi-coding-agent/dist/core/retry-handler.js.map +1 -0
  158. package/packages/pi-coding-agent/dist/core/session-manager.d.ts +0 -1
  159. package/packages/pi-coding-agent/dist/core/session-manager.d.ts.map +1 -1
  160. package/packages/pi-coding-agent/dist/core/session-manager.js +3 -28
  161. package/packages/pi-coding-agent/dist/core/session-manager.js.map +1 -1
  162. package/packages/pi-coding-agent/dist/core/settings-manager.d.ts +8 -0
  163. package/packages/pi-coding-agent/dist/core/settings-manager.d.ts.map +1 -1
  164. package/packages/pi-coding-agent/dist/core/settings-manager.js +76 -166
  165. package/packages/pi-coding-agent/dist/core/settings-manager.js.map +1 -1
  166. package/packages/pi-coding-agent/dist/core/skills.d.ts.map +1 -1
  167. package/packages/pi-coding-agent/dist/core/skills.js +1 -3
  168. package/packages/pi-coding-agent/dist/core/skills.js.map +1 -1
  169. package/packages/pi-coding-agent/dist/index.d.ts +1 -1
  170. package/packages/pi-coding-agent/dist/index.d.ts.map +1 -1
  171. package/packages/pi-coding-agent/dist/index.js +1 -1
  172. package/packages/pi-coding-agent/dist/index.js.map +1 -1
  173. package/packages/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts +1 -1
  174. package/packages/pi-coding-agent/dist/modes/interactive/components/session-selector.d.ts.map +1 -1
  175. package/packages/pi-coding-agent/dist/modes/interactive/components/session-selector.js +9 -26
  176. package/packages/pi-coding-agent/dist/modes/interactive/components/session-selector.js.map +1 -1
  177. package/packages/pi-coding-agent/dist/modes/interactive/components/tool-execution.d.ts.map +1 -1
  178. package/packages/pi-coding-agent/dist/modes/interactive/components/tool-execution.js +1 -13
  179. package/packages/pi-coding-agent/dist/modes/interactive/components/tool-execution.js.map +1 -1
  180. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-render-utils.d.ts +44 -0
  181. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-render-utils.d.ts.map +1 -0
  182. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-render-utils.js +61 -0
  183. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-render-utils.js.map +1 -0
  184. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-selector.d.ts.map +1 -1
  185. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-selector.js +6 -9
  186. package/packages/pi-coding-agent/dist/modes/interactive/components/tree-selector.js.map +1 -1
  187. package/packages/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts +65 -0
  188. package/packages/pi-coding-agent/dist/modes/interactive/theme/theme.d.ts.map +1 -1
  189. package/packages/pi-coding-agent/dist/modes/interactive/theme/theme.js +6 -16
  190. package/packages/pi-coding-agent/dist/modes/interactive/theme/theme.js.map +1 -1
  191. package/packages/pi-coding-agent/dist/modes/interactive/theme/themes.d.ts +12 -0
  192. package/packages/pi-coding-agent/dist/modes/interactive/theme/themes.d.ts.map +1 -0
  193. package/packages/pi-coding-agent/dist/modes/interactive/theme/themes.js +175 -0
  194. package/packages/pi-coding-agent/dist/modes/interactive/theme/themes.js.map +1 -0
  195. package/packages/pi-coding-agent/dist/modes/interactive/utils/shorten-path.d.ts +6 -0
  196. package/packages/pi-coding-agent/dist/modes/interactive/utils/shorten-path.d.ts.map +1 -0
  197. package/packages/pi-coding-agent/dist/modes/interactive/utils/shorten-path.js +15 -0
  198. package/packages/pi-coding-agent/dist/modes/interactive/utils/shorten-path.js.map +1 -0
  199. package/packages/pi-coding-agent/dist/modes/print-mode.d.ts.map +1 -1
  200. package/packages/pi-coding-agent/dist/modes/print-mode.js +2 -30
  201. package/packages/pi-coding-agent/dist/modes/print-mode.js.map +1 -1
  202. package/packages/pi-coding-agent/dist/modes/rpc/rpc-mode.d.ts.map +1 -1
  203. package/packages/pi-coding-agent/dist/modes/rpc/rpc-mode.js +2 -28
  204. package/packages/pi-coding-agent/dist/modes/rpc/rpc-mode.js.map +1 -1
  205. package/packages/pi-coding-agent/dist/modes/shared/command-context-actions.d.ts +19 -0
  206. package/packages/pi-coding-agent/dist/modes/shared/command-context-actions.d.ts.map +1 -0
  207. package/packages/pi-coding-agent/dist/modes/shared/command-context-actions.js +45 -0
  208. package/packages/pi-coding-agent/dist/modes/shared/command-context-actions.js.map +1 -0
  209. package/packages/pi-coding-agent/dist/utils/error.d.ts +5 -0
  210. package/packages/pi-coding-agent/dist/utils/error.d.ts.map +1 -0
  211. package/packages/pi-coding-agent/dist/utils/error.js +7 -0
  212. package/packages/pi-coding-agent/dist/utils/error.js.map +1 -0
  213. package/packages/pi-coding-agent/package.json +1 -1
  214. package/packages/pi-coding-agent/src/core/agent-session.ts +117 -745
  215. package/packages/pi-coding-agent/src/core/auth-storage.ts +4 -38
  216. package/packages/pi-coding-agent/src/core/compaction/branch-summarization.ts +7 -53
  217. package/packages/pi-coding-agent/src/core/compaction/compaction.ts +14 -74
  218. package/packages/pi-coding-agent/src/core/compaction/utils.ts +100 -0
  219. package/packages/pi-coding-agent/src/core/compaction-orchestrator.ts +424 -0
  220. package/packages/pi-coding-agent/src/core/extensions/index.ts +1 -21
  221. package/packages/pi-coding-agent/src/core/extensions/runner.ts +119 -243
  222. package/packages/pi-coding-agent/src/core/extensions/types.ts +50 -69
  223. package/packages/pi-coding-agent/src/core/lock-utils.ts +113 -0
  224. package/packages/pi-coding-agent/src/core/lsp/config.ts +4 -1
  225. package/packages/pi-coding-agent/src/core/lsp/index.ts +83 -152
  226. package/packages/pi-coding-agent/src/core/lsp/lspmux.ts +2 -22
  227. package/packages/pi-coding-agent/src/core/lsp/types.ts +0 -29
  228. package/packages/pi-coding-agent/src/core/package-manager.ts +1 -4
  229. package/packages/pi-coding-agent/src/core/resource-loader.ts +56 -69
  230. package/packages/pi-coding-agent/src/core/retry-handler.ts +359 -0
  231. package/packages/pi-coding-agent/src/core/session-manager.ts +3 -30
  232. package/packages/pi-coding-agent/src/core/settings-manager.ts +85 -164
  233. package/packages/pi-coding-agent/src/core/skills.ts +1 -4
  234. package/packages/pi-coding-agent/src/index.ts +1 -7
  235. package/packages/pi-coding-agent/src/modes/interactive/components/session-selector.ts +17 -29
  236. package/packages/pi-coding-agent/src/modes/interactive/components/tool-execution.ts +1 -13
  237. package/packages/pi-coding-agent/src/modes/interactive/components/tree-render-utils.ts +81 -0
  238. package/packages/pi-coding-agent/src/modes/interactive/components/tree-selector.ts +14 -19
  239. package/packages/pi-coding-agent/src/modes/interactive/theme/theme.ts +7 -18
  240. package/packages/pi-coding-agent/src/modes/interactive/theme/themes.ts +196 -0
  241. package/packages/pi-coding-agent/src/modes/interactive/utils/shorten-path.ts +14 -0
  242. package/packages/pi-coding-agent/src/modes/print-mode.ts +2 -30
  243. package/packages/pi-coding-agent/src/modes/rpc/rpc-mode.ts +2 -28
  244. package/packages/pi-coding-agent/src/modes/shared/command-context-actions.ts +53 -0
  245. package/packages/pi-coding-agent/src/utils/error.ts +6 -0
  246. package/packages/pi-tui/dist/components/markdown.d.ts +5 -0
  247. package/packages/pi-tui/dist/components/markdown.d.ts.map +1 -1
  248. package/packages/pi-tui/dist/components/markdown.js +25 -31
  249. package/packages/pi-tui/dist/components/markdown.js.map +1 -1
  250. package/packages/pi-tui/dist/keys.d.ts +0 -4
  251. package/packages/pi-tui/dist/keys.d.ts.map +1 -1
  252. package/packages/pi-tui/dist/keys.js +94 -162
  253. package/packages/pi-tui/dist/keys.js.map +1 -1
  254. package/packages/pi-tui/src/components/markdown.ts +25 -29
  255. package/packages/pi-tui/src/keys.ts +94 -173
  256. package/pkg/dist/modes/interactive/theme/theme.d.ts +65 -0
  257. package/pkg/dist/modes/interactive/theme/theme.d.ts.map +1 -1
  258. package/pkg/dist/modes/interactive/theme/theme.js +6 -16
  259. package/pkg/dist/modes/interactive/theme/theme.js.map +1 -1
  260. package/pkg/dist/modes/interactive/theme/themes.d.ts +12 -0
  261. package/pkg/dist/modes/interactive/theme/themes.d.ts.map +1 -0
  262. package/pkg/dist/modes/interactive/theme/themes.js +175 -0
  263. package/pkg/dist/modes/interactive/theme/themes.js.map +1 -0
  264. package/pkg/package.json +1 -1
  265. package/src/resources/extensions/async-jobs/await-tool.ts +0 -2
  266. package/src/resources/extensions/async-jobs/job-manager.ts +0 -7
  267. package/src/resources/extensions/bg-shell/output-formatter.ts +0 -17
  268. package/src/resources/extensions/bg-shell/process-manager.ts +0 -4
  269. package/src/resources/extensions/bg-shell/types.ts +0 -12
  270. package/src/resources/extensions/context7/index.ts +7 -0
  271. package/src/resources/extensions/get-secrets-from-user.ts +2 -35
  272. package/src/resources/extensions/google-search/index.ts +7 -0
  273. package/src/resources/extensions/gsd/auto-dispatch.ts +49 -1
  274. package/src/resources/extensions/gsd/auto-loop.ts +11 -1
  275. package/src/resources/extensions/gsd/auto-recovery.ts +39 -0
  276. package/src/resources/extensions/gsd/auto-start.ts +42 -2
  277. package/src/resources/extensions/gsd/auto.ts +61 -3
  278. package/src/resources/extensions/gsd/changelog.ts +213 -0
  279. package/src/resources/extensions/gsd/commands-bootstrap.ts +1 -0
  280. package/src/resources/extensions/gsd/commands-handlers.ts +2 -2
  281. package/src/resources/extensions/gsd/commands-inspect.ts +10 -3
  282. package/src/resources/extensions/gsd/commands-prefs-wizard.ts +5 -1
  283. package/src/resources/extensions/gsd/commands.ts +9 -1
  284. package/src/resources/extensions/gsd/docs/preferences-reference.md +10 -0
  285. package/src/resources/extensions/gsd/doctor-checks.ts +107 -5
  286. package/src/resources/extensions/gsd/doctor-environment.ts +26 -16
  287. package/src/resources/extensions/gsd/doctor-proactive.ts +24 -0
  288. package/src/resources/extensions/gsd/doctor-types.ts +9 -1
  289. package/src/resources/extensions/gsd/doctor.ts +35 -0
  290. package/src/resources/extensions/gsd/files.ts +12 -2
  291. package/src/resources/extensions/gsd/gitignore.ts +54 -7
  292. package/src/resources/extensions/gsd/guided-flow.ts +5 -3
  293. package/src/resources/extensions/gsd/health-widget-core.ts +129 -0
  294. package/src/resources/extensions/gsd/health-widget.ts +103 -59
  295. package/src/resources/extensions/gsd/index.ts +10 -1
  296. package/src/resources/extensions/gsd/migrate-external.ts +47 -2
  297. package/src/resources/extensions/gsd/paths.ts +73 -7
  298. package/src/resources/extensions/gsd/post-unit-hooks.ts +5 -1
  299. package/src/resources/extensions/gsd/preferences-validation.ts +54 -1
  300. package/src/resources/extensions/gsd/preferences.ts +2 -0
  301. package/src/resources/extensions/gsd/prompts/complete-milestone.md +2 -0
  302. package/src/resources/extensions/gsd/prompts/validate-milestone.md +2 -0
  303. package/src/resources/extensions/gsd/roadmap-mutations.ts +66 -0
  304. package/src/resources/extensions/gsd/session-lock.ts +29 -2
  305. package/src/resources/extensions/gsd/templates/plan.md +8 -0
  306. package/src/resources/extensions/gsd/tests/commands-inspect-open-db.test.ts +46 -0
  307. package/src/resources/extensions/gsd/tests/doctor-git.test.ts +98 -2
  308. package/src/resources/extensions/gsd/tests/doctor-runtime.test.ts +59 -3
  309. package/src/resources/extensions/gsd/tests/files-loadfile-eisdir.test.ts +20 -0
  310. package/src/resources/extensions/gsd/tests/gitignore-tracked-gsd.test.ts +214 -0
  311. package/src/resources/extensions/gsd/tests/health-widget.test.ts +158 -0
  312. package/src/resources/extensions/gsd/tests/paths.test.ts +113 -0
  313. package/src/resources/extensions/gsd/tests/preferences.test.ts +40 -2
  314. package/src/resources/extensions/gsd/tests/test-utils.ts +165 -0
  315. package/src/resources/extensions/gsd/tests/validate-directory.test.ts +15 -0
  316. package/src/resources/extensions/gsd/tests/validate-milestone.test.ts +2 -0
  317. package/src/resources/extensions/gsd/tests/worktree-sync-milestones.test.ts +32 -0
  318. package/src/resources/extensions/gsd/worktree-resolver.ts +11 -0
  319. package/src/resources/extensions/remote-questions/remote-command.ts +2 -23
  320. package/src/resources/extensions/shared/mod.ts +1 -1
  321. package/src/resources/extensions/shared/sanitize.ts +36 -0
  322. package/src/resources/extensions/subagent/index.ts +6 -12
  323. package/src/resources/skills/create-gsd-extension/references/events-reference.md +4 -4
  324. package/dist/resources/extensions/shared/wizard-ui.js +0 -478
  325. package/packages/pi-coding-agent/dist/modes/interactive/theme/dark.json +0 -85
  326. package/packages/pi-coding-agent/dist/modes/interactive/theme/light.json +0 -84
  327. package/packages/pi-coding-agent/dist/modes/interactive/theme/theme-schema.json +0 -335
  328. package/packages/pi-coding-agent/src/modes/interactive/theme/dark.json +0 -85
  329. package/packages/pi-coding-agent/src/modes/interactive/theme/light.json +0 -84
  330. package/packages/pi-coding-agent/src/modes/interactive/theme/theme-schema.json +0 -335
  331. package/pkg/dist/modes/interactive/theme/dark.json +0 -85
  332. package/pkg/dist/modes/interactive/theme/light.json +0 -84
  333. package/pkg/dist/modes/interactive/theme/theme-schema.json +0 -335
  334. package/src/resources/extensions/shared/wizard-ui.ts +0 -551
@@ -0,0 +1,113 @@
1
+ /**
2
+ * Shared file-locking utilities built on `proper-lockfile`.
3
+ *
4
+ * Centralises the synchronous retry-loop and async lock/release patterns
5
+ * that were previously duplicated across auth-storage, session-manager,
6
+ * settings-manager, and models-json-writer.
7
+ */
8
+
9
+ import lockfile from "proper-lockfile";
10
+
11
+ const DEFAULT_MAX_ATTEMPTS = 10;
12
+ const DEFAULT_DELAY_MS = 20;
13
+
14
+ /**
15
+ * Acquire a synchronous file lock with retry.
16
+ *
17
+ * Retries up to `maxAttempts` times when the lock is held by another process
18
+ * (ELOCKED), using a busy-wait between attempts.
19
+ *
20
+ * @returns A release function to unlock.
21
+ * @throws On non-ELOCKED errors or when all attempts are exhausted.
22
+ */
23
+ export function acquireLockSyncWithRetry(
24
+ lockPath: string,
25
+ maxAttempts: number = DEFAULT_MAX_ATTEMPTS,
26
+ delayMs: number = DEFAULT_DELAY_MS,
27
+ ): () => void {
28
+ let lastError: unknown;
29
+
30
+ for (let attempt = 1; attempt <= maxAttempts; attempt++) {
31
+ try {
32
+ return lockfile.lockSync(lockPath, { realpath: false });
33
+ } catch (error) {
34
+ const code =
35
+ typeof error === "object" && error !== null && "code" in error
36
+ ? String((error as { code?: unknown }).code)
37
+ : undefined;
38
+ if (code !== "ELOCKED" || attempt === maxAttempts) {
39
+ throw error;
40
+ }
41
+ lastError = error;
42
+ const start = Date.now();
43
+ while (Date.now() - start < delayMs) {
44
+ // Busy-wait to avoid changing callers to async.
45
+ }
46
+ }
47
+ }
48
+
49
+ throw (lastError as Error) ?? new Error("Failed to acquire file lock");
50
+ }
51
+
52
+ /**
53
+ * Non-throwing variant of {@link acquireLockSyncWithRetry}.
54
+ *
55
+ * Returns `undefined` instead of throwing when the lock cannot be acquired,
56
+ * allowing callers to proceed without the lock rather than losing data.
57
+ */
58
+ export function tryAcquireLockSync(
59
+ lockPath: string,
60
+ maxAttempts: number = DEFAULT_MAX_ATTEMPTS,
61
+ delayMs: number = DEFAULT_DELAY_MS,
62
+ ): (() => void) | undefined {
63
+ for (let attempt = 1; attempt <= maxAttempts; attempt++) {
64
+ try {
65
+ return lockfile.lockSync(lockPath, { realpath: false });
66
+ } catch (error) {
67
+ const code =
68
+ typeof error === "object" && error !== null && "code" in error
69
+ ? String((error as { code?: unknown }).code)
70
+ : undefined;
71
+ if (code !== "ELOCKED" || attempt === maxAttempts) {
72
+ // Non-fatal: proceed without lock rather than losing data
73
+ return undefined;
74
+ }
75
+ const start = Date.now();
76
+ while (Date.now() - start < delayMs) {
77
+ // Busy-wait to avoid changing callers to async.
78
+ }
79
+ }
80
+ }
81
+ return undefined;
82
+ }
83
+
84
+ export interface AsyncLockOptions {
85
+ /** Maximum staleness in ms before the lock is considered stale. */
86
+ staleMs?: number;
87
+ /** Called if the lock is compromised while held. */
88
+ onCompromised?: (err: Error) => void;
89
+ }
90
+
91
+ /**
92
+ * Acquire an async file lock with retries and optional staleness detection.
93
+ *
94
+ * Uses `proper-lockfile`'s async API with exponential-backoff retries.
95
+ *
96
+ * @returns A release function (async) to unlock.
97
+ */
98
+ export async function acquireLockAsync(
99
+ lockPath: string,
100
+ options?: AsyncLockOptions,
101
+ ): Promise<() => Promise<void>> {
102
+ return lockfile.lock(lockPath, {
103
+ retries: {
104
+ retries: 10,
105
+ factor: 2,
106
+ minTimeout: 100,
107
+ maxTimeout: 10000,
108
+ randomize: true,
109
+ },
110
+ stale: options?.staleMs,
111
+ onCompromised: options?.onCompromised,
112
+ });
113
+ }
@@ -176,7 +176,7 @@ const LOCAL_BIN_PATHS: Array<{ markers: string[]; binDir: string }> = [
176
176
  { markers: ["go.mod", "go.sum"], binDir: "bin" },
177
177
  ];
178
178
 
179
- function which(command: string): string | null {
179
+ export function which(command: string): string | null {
180
180
  // On Windows, prefer `where.exe` over `which` — MSYS/Git Bash's `which`
181
181
  // returns POSIX paths (/c/Users/...) that Node's spawn() can't execute.
182
182
  // `where.exe` returns native Windows paths (C:\Users\...).
@@ -319,3 +319,6 @@ export function getServersForFile(config: LspConfig, filePath: string): Array<[s
319
319
  });
320
320
  }
321
321
 
322
+ export function getServerForFile(config: LspConfig, filePath: string): [string, ServerConfig] | null {
323
+ return getServersForFile(config, filePath)[0] ?? null;
324
+ }
@@ -14,7 +14,7 @@ import {
14
14
  setIdleTimeout,
15
15
  WARMUP_TIMEOUT_MS,
16
16
  } from "./client.js";
17
- import { getServersForFile, type LspConfig, loadConfig, hasRootMarkers, resolveCommand } from "./config.js";
17
+ import { getServerForFile, getServersForFile, type LspConfig, loadConfig, hasRootMarkers, resolveCommand } from "./config.js";
18
18
  import { applyTextEdits, applyWorkspaceEdit } from "./edits.js";
19
19
  import { ToolAbortError, clampTimeout, throwIfAborted } from "./helpers.js";
20
20
  import { detectLspmux } from "./lspmux.js";
@@ -144,15 +144,6 @@ function getLspServers(config: LspConfig): Array<[string, ServerConfig]> {
144
144
  return Object.entries(config.servers) as Array<[string, ServerConfig]>;
145
145
  }
146
146
 
147
- function getLspServersForFile(config: LspConfig, filePath: string): Array<[string, ServerConfig]> {
148
- return getServersForFile(config, filePath);
149
- }
150
-
151
- function getLspServerForFile(config: LspConfig, filePath: string): [string, ServerConfig] | null {
152
- const servers = getLspServersForFile(config, filePath);
153
- return servers.length > 0 ? servers[0] : null;
154
- }
155
-
156
147
  const DIAGNOSTIC_MESSAGE_LIMIT = 50;
157
148
  const SINGLE_DIAGNOSTICS_WAIT_TIMEOUT_MS = 3000;
158
149
  const BATCH_DIAGNOSTICS_WAIT_TIMEOUT_MS = 400;
@@ -197,6 +188,73 @@ async function formatLocationWithContext(location: Location, cwd: string): Promi
197
188
  return `${header}\n${context.map(lineText => ` ${lineText}`).join("\n")}`;
198
189
  }
199
190
 
191
+ async function formatLocationResults(
192
+ result: Location | Location[] | LocationLink | LocationLink[] | null,
193
+ label: string,
194
+ cwd: string,
195
+ ): Promise<string> {
196
+ const locations = normalizeLocationResult(result);
197
+ if (locations.length === 0) {
198
+ return `No ${label} found`;
199
+ }
200
+ const lines = await Promise.all(locations.map(location => formatLocationWithContext(location, cwd)));
201
+ return `Found ${locations.length} ${label}(s):\n${lines.join("\n")}`;
202
+ }
203
+
204
+ async function formatCallHierarchyResults(
205
+ client: LspClient,
206
+ position: { line: number; character: number },
207
+ uri: string,
208
+ direction: "incoming" | "outgoing",
209
+ cwd: string,
210
+ signal?: AbortSignal,
211
+ ): Promise<string> {
212
+ const prepareResult = (await sendRequest(
213
+ client,
214
+ "textDocument/prepareCallHierarchy",
215
+ { textDocument: { uri }, position },
216
+ signal,
217
+ )) as CallHierarchyItem[] | null;
218
+
219
+ if (!prepareResult || prepareResult.length === 0) {
220
+ return "No call hierarchy item found at this position";
221
+ }
222
+
223
+ const method = direction === "incoming" ? "callHierarchy/incomingCalls" : "callHierarchy/outgoingCalls";
224
+ const callResult = (await sendRequest(client, method, { item: prepareResult[0] }, signal)) as
225
+ | CallHierarchyIncomingCall[]
226
+ | CallHierarchyOutgoingCall[]
227
+ | null;
228
+
229
+ if (!callResult || callResult.length === 0) {
230
+ const verb = direction === "incoming" ? "incoming calls" : "outgoing calls";
231
+ const prep = direction === "incoming" ? "for" : "from";
232
+ return `No ${verb} found ${prep} ${prepareResult[0].name}`;
233
+ }
234
+
235
+ const lines: string[] = [];
236
+ const limited = callResult.slice(0, REFERENCE_CONTEXT_LIMIT);
237
+ for (const call of limited) {
238
+ const item = "from" in call ? call.from : call.to;
239
+ const header = formatCallHierarchyItem(item, cwd);
240
+ const filePath = uriToFile(item.uri);
241
+ const callLine = ("from" in call ? call.fromRanges[0]?.start.line : undefined) ?? item.selectionRange.start.line;
242
+ const context = await readLocationContext(filePath, callLine + 1, LOCATION_CONTEXT_LINES);
243
+ if (context.length > 0) {
244
+ lines.push(` ${header}\n${context.map(l => ` ${l}`).join("\n")}`);
245
+ } else {
246
+ lines.push(` ${header}`);
247
+ }
248
+ }
249
+
250
+ const noun = direction === "incoming" ? "caller" : "callee";
251
+ const prep = direction === "incoming" ? "of" : "from";
252
+ const truncation = callResult.length > REFERENCE_CONTEXT_LIMIT
253
+ ? `\n ... ${callResult.length - REFERENCE_CONTEXT_LIMIT} additional ${noun}(s) omitted`
254
+ : "";
255
+ return `${callResult.length} ${noun}(s) ${prep} ${prepareResult[0].name}:\n${lines.join("\n")}${truncation}`;
256
+ }
257
+
200
258
  async function reloadServer(client: LspClient, serverName: string, signal?: AbortSignal): Promise<string> {
201
259
  let output = `Restarted ${serverName}`;
202
260
  const reloadMethods = ["rust-analyzer/reloadWorkspace", "workspace/didChangeConfiguration"];
@@ -647,7 +705,7 @@ export function createLspTool(cwd: string): AgentTool<typeof lspSchema, LspToolD
647
705
  }
648
706
 
649
707
  // File-specific actions
650
- const serverInfo = resolvedFile ? getLspServerForFile(config, resolvedFile) : null;
708
+ const serverInfo = resolvedFile ? getServerForFile(config, resolvedFile) : null;
651
709
  if (!serverInfo) {
652
710
  return {
653
711
  content: [{ type: "text", text: "No language server found for this action" }],
@@ -676,74 +734,35 @@ export function createLspTool(cwd: string): AgentTool<typeof lspSchema, LspToolD
676
734
 
677
735
  switch (action) {
678
736
  case "definition": {
679
- const result = (await sendRequest(
737
+ const result = await sendRequest(
680
738
  client,
681
739
  "textDocument/definition",
682
- {
683
- textDocument: { uri },
684
- position,
685
- },
740
+ { textDocument: { uri }, position },
686
741
  signal,
687
- )) as Location | Location[] | LocationLink | LocationLink[] | null;
688
-
689
- const locations = normalizeLocationResult(result);
690
-
691
- if (locations.length === 0) {
692
- output = "No definition found";
693
- } else {
694
- const lines = await Promise.all(
695
- locations.map(location => formatLocationWithContext(location, cwd)),
696
- );
697
- output = `Found ${locations.length} definition(s):\n${lines.join("\n")}`;
698
- }
742
+ );
743
+ output = await formatLocationResults(result as Location | Location[] | LocationLink | LocationLink[] | null, "definition", cwd);
699
744
  break;
700
745
  }
701
746
 
702
747
  case "type_definition": {
703
- const result = (await sendRequest(
748
+ const result = await sendRequest(
704
749
  client,
705
750
  "textDocument/typeDefinition",
706
- {
707
- textDocument: { uri },
708
- position,
709
- },
751
+ { textDocument: { uri }, position },
710
752
  signal,
711
- )) as Location | Location[] | LocationLink | LocationLink[] | null;
712
-
713
- const locations = normalizeLocationResult(result);
714
-
715
- if (locations.length === 0) {
716
- output = "No type definition found";
717
- } else {
718
- const lines = await Promise.all(
719
- locations.map(location => formatLocationWithContext(location, cwd)),
720
- );
721
- output = `Found ${locations.length} type definition(s):\n${lines.join("\n")}`;
722
- }
753
+ );
754
+ output = await formatLocationResults(result as Location | Location[] | LocationLink | LocationLink[] | null, "type definition", cwd);
723
755
  break;
724
756
  }
725
757
 
726
758
  case "implementation": {
727
- const result = (await sendRequest(
759
+ const result = await sendRequest(
728
760
  client,
729
761
  "textDocument/implementation",
730
- {
731
- textDocument: { uri },
732
- position,
733
- },
762
+ { textDocument: { uri }, position },
734
763
  signal,
735
- )) as Location | Location[] | LocationLink | LocationLink[] | null;
736
-
737
- const locations = normalizeLocationResult(result);
738
-
739
- if (locations.length === 0) {
740
- output = "No implementation found";
741
- } else {
742
- const lines = await Promise.all(
743
- locations.map(location => formatLocationWithContext(location, cwd)),
744
- );
745
- output = `Found ${locations.length} implementation(s):\n${lines.join("\n")}`;
746
- }
764
+ );
765
+ output = await formatLocationResults(result as Location | Location[] | LocationLink | LocationLink[] | null, "implementation", cwd);
747
766
  break;
748
767
  }
749
768
 
@@ -917,100 +936,12 @@ export function createLspTool(cwd: string): AgentTool<typeof lspSchema, LspToolD
917
936
  }
918
937
 
919
938
  case "incoming_calls": {
920
- const prepareResult = (await sendRequest(
921
- client,
922
- "textDocument/prepareCallHierarchy",
923
- {
924
- textDocument: { uri },
925
- position,
926
- },
927
- signal,
928
- )) as CallHierarchyItem[] | null;
929
-
930
- if (!prepareResult || prepareResult.length === 0) {
931
- output = "No call hierarchy item found at this position";
932
- break;
933
- }
934
-
935
- const incomingResult = (await sendRequest(
936
- client,
937
- "callHierarchy/incomingCalls",
938
- { item: prepareResult[0] },
939
- signal,
940
- )) as CallHierarchyIncomingCall[] | null;
941
-
942
- if (!incomingResult || incomingResult.length === 0) {
943
- output = `No incoming calls found for ${prepareResult[0].name}`;
944
- break;
945
- }
946
-
947
- const incomingLines: string[] = [];
948
- const limitedIncoming = incomingResult.slice(0, REFERENCE_CONTEXT_LIMIT);
949
- for (const call of limitedIncoming) {
950
- const header = formatCallHierarchyItem(call.from, cwd);
951
- const filePath = uriToFile(call.from.uri);
952
- const callLine = call.fromRanges[0]?.start.line ?? call.from.selectionRange.start.line;
953
- const context = await readLocationContext(filePath, callLine + 1, LOCATION_CONTEXT_LINES);
954
- if (context.length > 0) {
955
- incomingLines.push(` ${header}\n${context.map(l => ` ${l}`).join("\n")}`);
956
- } else {
957
- incomingLines.push(` ${header}`);
958
- }
959
- }
960
-
961
- const truncation = incomingResult.length > REFERENCE_CONTEXT_LIMIT
962
- ? `\n ... ${incomingResult.length - REFERENCE_CONTEXT_LIMIT} additional caller(s) omitted`
963
- : "";
964
- output = `${incomingResult.length} caller(s) of ${prepareResult[0].name}:\n${incomingLines.join("\n")}${truncation}`;
939
+ output = await formatCallHierarchyResults(client, position, uri, "incoming", cwd, signal);
965
940
  break;
966
941
  }
967
942
 
968
943
  case "outgoing_calls": {
969
- const prepareResult = (await sendRequest(
970
- client,
971
- "textDocument/prepareCallHierarchy",
972
- {
973
- textDocument: { uri },
974
- position,
975
- },
976
- signal,
977
- )) as CallHierarchyItem[] | null;
978
-
979
- if (!prepareResult || prepareResult.length === 0) {
980
- output = "No call hierarchy item found at this position";
981
- break;
982
- }
983
-
984
- const outgoingResult = (await sendRequest(
985
- client,
986
- "callHierarchy/outgoingCalls",
987
- { item: prepareResult[0] },
988
- signal,
989
- )) as CallHierarchyOutgoingCall[] | null;
990
-
991
- if (!outgoingResult || outgoingResult.length === 0) {
992
- output = `No outgoing calls found from ${prepareResult[0].name}`;
993
- break;
994
- }
995
-
996
- const outgoingLines: string[] = [];
997
- const limitedOutgoing = outgoingResult.slice(0, REFERENCE_CONTEXT_LIMIT);
998
- for (const call of limitedOutgoing) {
999
- const header = formatCallHierarchyItem(call.to, cwd);
1000
- const filePath = uriToFile(call.to.uri);
1001
- const callLine = call.to.selectionRange.start.line;
1002
- const context = await readLocationContext(filePath, callLine + 1, LOCATION_CONTEXT_LINES);
1003
- if (context.length > 0) {
1004
- outgoingLines.push(` ${header}\n${context.map(l => ` ${l}`).join("\n")}`);
1005
- } else {
1006
- outgoingLines.push(` ${header}`);
1007
- }
1008
- }
1009
-
1010
- const outTruncation = outgoingResult.length > REFERENCE_CONTEXT_LIMIT
1011
- ? `\n ... ${outgoingResult.length - REFERENCE_CONTEXT_LIMIT} additional callee(s) omitted`
1012
- : "";
1013
- output = `${outgoingResult.length} callee(s) from ${prepareResult[0].name}:\n${outgoingLines.join("\n")}${outTruncation}`;
944
+ output = await formatCallHierarchyResults(client, position, uri, "outgoing", cwd, signal);
1014
945
  break;
1015
946
  }
1016
947
 
@@ -1,8 +1,9 @@
1
- import { execSync, spawn } from "node:child_process";
1
+ import { spawn } from "node:child_process";
2
2
  import * as fsPromises from "node:fs/promises";
3
3
  import * as os from "node:os";
4
4
  import * as path from "node:path";
5
5
  import { LSP_LIVENESS_TIMEOUT_MS, LSP_STATE_CACHE_TTL_MS } from "../constants.js";
6
+ import { which } from "./config.js";
6
7
 
7
8
  /**
8
9
  * lspmux integration for LSP server multiplexing.
@@ -43,27 +44,6 @@ const DEFAULT_SUPPORTED_SERVERS = new Set([
43
44
  ]);
44
45
 
45
46
 
46
- // =============================================================================
47
- // Helpers
48
- // =============================================================================
49
-
50
- function which(command: string): string | null {
51
- try {
52
- // On Windows, prefer `where.exe` over `which` — MSYS/Git Bash's `which`
53
- // returns POSIX paths (/c/Users/...) that Node's spawn() can't execute (#1121).
54
- const isWindows = process.platform === "win32";
55
- const cmd = isWindows ? "where.exe" : "which";
56
- const result = isWindows
57
- ? execSync(`${cmd} ${command}`, { encoding: "utf-8" })
58
- : execSync(`which ${command}`, { encoding: "utf-8" });
59
- // `where.exe` may return multiple lines — take the first
60
- const resolved = result.trim().split(/\r?\n/)[0]?.trim();
61
- return resolved || null;
62
- } catch {
63
- return null;
64
- }
65
- }
66
-
67
47
  // =============================================================================
68
48
  // Config Path
69
49
  // =============================================================================
@@ -256,35 +256,6 @@ export type SymbolKind =
256
256
  | 25 // Operator
257
257
  | 26; // TypeParameter
258
258
 
259
- export const SYMBOL_KIND_NAMES: Record<SymbolKind, string> = {
260
- 1: "File",
261
- 2: "Module",
262
- 3: "Namespace",
263
- 4: "Package",
264
- 5: "Class",
265
- 6: "Method",
266
- 7: "Property",
267
- 8: "Field",
268
- 9: "Constructor",
269
- 10: "Enum",
270
- 11: "Interface",
271
- 12: "Function",
272
- 13: "Variable",
273
- 14: "Constant",
274
- 15: "String",
275
- 16: "Number",
276
- 17: "Boolean",
277
- 18: "Array",
278
- 19: "Object",
279
- 20: "Key",
280
- 21: "Null",
281
- 22: "EnumMember",
282
- 23: "Struct",
283
- 24: "Event",
284
- 25: "Operator",
285
- 26: "TypeParameter",
286
- };
287
-
288
259
  export interface DocumentSymbol {
289
260
  name: string;
290
261
  detail?: string;
@@ -7,6 +7,7 @@ import ignore from "ignore";
7
7
  import { minimatch } from "minimatch";
8
8
  import { CONFIG_DIR_NAME } from "../config.js";
9
9
  import { type GitSource, parseGitUrl } from "../utils/git.js";
10
+ import { toPosixPath } from "../utils/path-display.js";
10
11
  import type { PackageSource, SettingsManager } from "./settings-manager.js";
11
12
 
12
13
  const NETWORK_TIMEOUT_MS = 10000;
@@ -121,10 +122,6 @@ const IGNORE_FILE_NAMES = [".gitignore", ".ignore", ".fdignore"];
121
122
 
122
123
  type IgnoreMatcher = ReturnType<typeof ignore>;
123
124
 
124
- function toPosixPath(p: string): string {
125
- return p.split(sep).join("/");
126
- }
127
-
128
125
  function prefixIgnorePattern(line: string, prefix: string): string | null {
129
126
  const trimmed = line.trim();
130
127
  if (!trimmed) return null;