plexus-agent-config 0.0.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 (351) hide show
  1. package/dist/bin.d.ts +3 -0
  2. package/dist/bin.d.ts.map +1 -0
  3. package/dist/bin.js +175 -0
  4. package/dist/bin.js.map +1 -0
  5. package/node_modules/plexus-agent-config-core/dist/agents/adapters/base.d.ts +38 -0
  6. package/node_modules/plexus-agent-config-core/dist/agents/adapters/base.d.ts.map +1 -0
  7. package/node_modules/plexus-agent-config-core/dist/agents/adapters/base.js +125 -0
  8. package/node_modules/plexus-agent-config-core/dist/agents/adapters/base.js.map +1 -0
  9. package/node_modules/plexus-agent-config-core/dist/agents/adapters/codex.d.ts +9 -0
  10. package/node_modules/plexus-agent-config-core/dist/agents/adapters/codex.d.ts.map +1 -0
  11. package/node_modules/plexus-agent-config-core/dist/agents/adapters/codex.js +96 -0
  12. package/node_modules/plexus-agent-config-core/dist/agents/adapters/codex.js.map +1 -0
  13. package/node_modules/plexus-agent-config-core/dist/agents/adapters/index.d.ts +8 -0
  14. package/node_modules/plexus-agent-config-core/dist/agents/adapters/index.d.ts.map +1 -0
  15. package/node_modules/plexus-agent-config-core/dist/agents/adapters/index.js +12 -0
  16. package/node_modules/plexus-agent-config-core/dist/agents/adapters/index.js.map +1 -0
  17. package/node_modules/plexus-agent-config-core/dist/agents/adapters/json-mcp.d.ts +25 -0
  18. package/node_modules/plexus-agent-config-core/dist/agents/adapters/json-mcp.d.ts.map +1 -0
  19. package/node_modules/plexus-agent-config-core/dist/agents/adapters/json-mcp.js +182 -0
  20. package/node_modules/plexus-agent-config-core/dist/agents/adapters/json-mcp.js.map +1 -0
  21. package/node_modules/plexus-agent-config-core/dist/agents/catalog.d.ts +15 -0
  22. package/node_modules/plexus-agent-config-core/dist/agents/catalog.d.ts.map +1 -0
  23. package/node_modules/plexus-agent-config-core/dist/agents/catalog.js +153 -0
  24. package/node_modules/plexus-agent-config-core/dist/agents/catalog.js.map +1 -0
  25. package/node_modules/plexus-agent-config-core/dist/agents/detect.d.ts +14 -0
  26. package/node_modules/plexus-agent-config-core/dist/agents/detect.d.ts.map +1 -0
  27. package/node_modules/plexus-agent-config-core/dist/agents/detect.js +92 -0
  28. package/node_modules/plexus-agent-config-core/dist/agents/detect.js.map +1 -0
  29. package/node_modules/plexus-agent-config-core/dist/agents/index.d.ts +5 -0
  30. package/node_modules/plexus-agent-config-core/dist/agents/index.d.ts.map +1 -0
  31. package/node_modules/plexus-agent-config-core/dist/agents/index.js +5 -0
  32. package/node_modules/plexus-agent-config-core/dist/agents/index.js.map +1 -0
  33. package/node_modules/plexus-agent-config-core/dist/agents/inspect.d.ts +74 -0
  34. package/node_modules/plexus-agent-config-core/dist/agents/inspect.d.ts.map +1 -0
  35. package/node_modules/plexus-agent-config-core/dist/agents/inspect.js +169 -0
  36. package/node_modules/plexus-agent-config-core/dist/agents/inspect.js.map +1 -0
  37. package/node_modules/plexus-agent-config-core/dist/backup/index.d.ts +70 -0
  38. package/node_modules/plexus-agent-config-core/dist/backup/index.d.ts.map +1 -0
  39. package/node_modules/plexus-agent-config-core/dist/backup/index.js +258 -0
  40. package/node_modules/plexus-agent-config-core/dist/backup/index.js.map +1 -0
  41. package/node_modules/plexus-agent-config-core/dist/debug/index.d.ts +71 -0
  42. package/node_modules/plexus-agent-config-core/dist/debug/index.d.ts.map +1 -0
  43. package/node_modules/plexus-agent-config-core/dist/debug/index.js +263 -0
  44. package/node_modules/plexus-agent-config-core/dist/debug/index.js.map +1 -0
  45. package/node_modules/plexus-agent-config-core/dist/effective/index.d.ts +65 -0
  46. package/node_modules/plexus-agent-config-core/dist/effective/index.d.ts.map +1 -0
  47. package/node_modules/plexus-agent-config-core/dist/effective/index.js +227 -0
  48. package/node_modules/plexus-agent-config-core/dist/effective/index.js.map +1 -0
  49. package/node_modules/plexus-agent-config-core/dist/import/from-agents.d.ts +59 -0
  50. package/node_modules/plexus-agent-config-core/dist/import/from-agents.d.ts.map +1 -0
  51. package/node_modules/plexus-agent-config-core/dist/import/from-agents.js +212 -0
  52. package/node_modules/plexus-agent-config-core/dist/import/from-agents.js.map +1 -0
  53. package/node_modules/plexus-agent-config-core/dist/import/index.d.ts +26 -0
  54. package/node_modules/plexus-agent-config-core/dist/import/index.d.ts.map +1 -0
  55. package/node_modules/plexus-agent-config-core/dist/import/index.js +100 -0
  56. package/node_modules/plexus-agent-config-core/dist/import/index.js.map +1 -0
  57. package/node_modules/plexus-agent-config-core/dist/index.d.ts +12 -0
  58. package/node_modules/plexus-agent-config-core/dist/index.d.ts.map +1 -0
  59. package/node_modules/plexus-agent-config-core/dist/index.js +12 -0
  60. package/node_modules/plexus-agent-config-core/dist/index.js.map +1 -0
  61. package/node_modules/plexus-agent-config-core/dist/rules/index.d.ts +6 -0
  62. package/node_modules/plexus-agent-config-core/dist/rules/index.d.ts.map +1 -0
  63. package/node_modules/plexus-agent-config-core/dist/rules/index.js +292 -0
  64. package/node_modules/plexus-agent-config-core/dist/rules/index.js.map +1 -0
  65. package/node_modules/plexus-agent-config-core/dist/spread/index.d.ts +38 -0
  66. package/node_modules/plexus-agent-config-core/dist/spread/index.d.ts.map +1 -0
  67. package/node_modules/plexus-agent-config-core/dist/spread/index.js +190 -0
  68. package/node_modules/plexus-agent-config-core/dist/spread/index.js.map +1 -0
  69. package/node_modules/plexus-agent-config-core/dist/store/config.d.ts +5 -0
  70. package/node_modules/plexus-agent-config-core/dist/store/config.d.ts.map +1 -0
  71. package/node_modules/plexus-agent-config-core/dist/store/config.js +62 -0
  72. package/node_modules/plexus-agent-config-core/dist/store/config.js.map +1 -0
  73. package/node_modules/plexus-agent-config-core/dist/store/custom-agents.d.ts +45 -0
  74. package/node_modules/plexus-agent-config-core/dist/store/custom-agents.d.ts.map +1 -0
  75. package/node_modules/plexus-agent-config-core/dist/store/custom-agents.js +103 -0
  76. package/node_modules/plexus-agent-config-core/dist/store/custom-agents.js.map +1 -0
  77. package/node_modules/plexus-agent-config-core/dist/store/fs-utils.d.ts +16 -0
  78. package/node_modules/plexus-agent-config-core/dist/store/fs-utils.d.ts.map +1 -0
  79. package/node_modules/plexus-agent-config-core/dist/store/fs-utils.js +45 -0
  80. package/node_modules/plexus-agent-config-core/dist/store/fs-utils.js.map +1 -0
  81. package/node_modules/plexus-agent-config-core/dist/store/index.d.ts +9 -0
  82. package/node_modules/plexus-agent-config-core/dist/store/index.d.ts.map +1 -0
  83. package/node_modules/plexus-agent-config-core/dist/store/index.js +9 -0
  84. package/node_modules/plexus-agent-config-core/dist/store/index.js.map +1 -0
  85. package/node_modules/plexus-agent-config-core/dist/store/mcp.d.ts +5 -0
  86. package/node_modules/plexus-agent-config-core/dist/store/mcp.d.ts.map +1 -0
  87. package/node_modules/plexus-agent-config-core/dist/store/mcp.js +30 -0
  88. package/node_modules/plexus-agent-config-core/dist/store/mcp.js.map +1 -0
  89. package/node_modules/plexus-agent-config-core/dist/store/merge.d.ts +15 -0
  90. package/node_modules/plexus-agent-config-core/dist/store/merge.d.ts.map +1 -0
  91. package/node_modules/plexus-agent-config-core/dist/store/merge.js +28 -0
  92. package/node_modules/plexus-agent-config-core/dist/store/merge.js.map +1 -0
  93. package/node_modules/plexus-agent-config-core/dist/store/paths.d.ts +22 -0
  94. package/node_modules/plexus-agent-config-core/dist/store/paths.d.ts.map +1 -0
  95. package/node_modules/plexus-agent-config-core/dist/store/paths.js +107 -0
  96. package/node_modules/plexus-agent-config-core/dist/store/paths.js.map +1 -0
  97. package/node_modules/plexus-agent-config-core/dist/store/rules.d.ts +12 -0
  98. package/node_modules/plexus-agent-config-core/dist/store/rules.d.ts.map +1 -0
  99. package/node_modules/plexus-agent-config-core/dist/store/rules.js +32 -0
  100. package/node_modules/plexus-agent-config-core/dist/store/rules.js.map +1 -0
  101. package/node_modules/plexus-agent-config-core/dist/store/scaffolding.d.ts +11 -0
  102. package/node_modules/plexus-agent-config-core/dist/store/scaffolding.d.ts.map +1 -0
  103. package/node_modules/plexus-agent-config-core/dist/store/scaffolding.js +32 -0
  104. package/node_modules/plexus-agent-config-core/dist/store/scaffolding.js.map +1 -0
  105. package/node_modules/plexus-agent-config-core/dist/store/skills.d.ts +13 -0
  106. package/node_modules/plexus-agent-config-core/dist/store/skills.d.ts.map +1 -0
  107. package/node_modules/plexus-agent-config-core/dist/store/skills.js +84 -0
  108. package/node_modules/plexus-agent-config-core/dist/store/skills.js.map +1 -0
  109. package/node_modules/plexus-agent-config-core/dist/sync/index.d.ts +89 -0
  110. package/node_modules/plexus-agent-config-core/dist/sync/index.d.ts.map +1 -0
  111. package/node_modules/plexus-agent-config-core/dist/sync/index.js +423 -0
  112. package/node_modules/plexus-agent-config-core/dist/sync/index.js.map +1 -0
  113. package/node_modules/plexus-agent-config-core/dist/team/git.d.ts +23 -0
  114. package/node_modules/plexus-agent-config-core/dist/team/git.d.ts.map +1 -0
  115. package/node_modules/plexus-agent-config-core/dist/team/git.js +132 -0
  116. package/node_modules/plexus-agent-config-core/dist/team/git.js.map +1 -0
  117. package/node_modules/plexus-agent-config-core/dist/team/index.d.ts +2 -0
  118. package/node_modules/plexus-agent-config-core/dist/team/index.d.ts.map +1 -0
  119. package/node_modules/plexus-agent-config-core/dist/team/index.js +2 -0
  120. package/node_modules/plexus-agent-config-core/dist/team/index.js.map +1 -0
  121. package/node_modules/plexus-agent-config-core/dist/types.d.ts +142 -0
  122. package/node_modules/plexus-agent-config-core/dist/types.d.ts.map +1 -0
  123. package/node_modules/plexus-agent-config-core/dist/types.js +13 -0
  124. package/node_modules/plexus-agent-config-core/dist/types.js.map +1 -0
  125. package/node_modules/plexus-agent-config-core/package.json +29 -0
  126. package/node_modules/plexus-agent-config-web/.next/BUILD_ID +1 -0
  127. package/node_modules/plexus-agent-config-web/.next/app-path-routes-manifest.json +39 -0
  128. package/node_modules/plexus-agent-config-web/.next/build-manifest.json +20 -0
  129. package/node_modules/plexus-agent-config-web/.next/export-marker.json +6 -0
  130. package/node_modules/plexus-agent-config-web/.next/images-manifest.json +68 -0
  131. package/node_modules/plexus-agent-config-web/.next/next-minimal-server.js.nft.json +1 -0
  132. package/node_modules/plexus-agent-config-web/.next/next-server.js.nft.json +1 -0
  133. package/node_modules/plexus-agent-config-web/.next/package.json +1 -0
  134. package/node_modules/plexus-agent-config-web/.next/prerender-manifest.json +36 -0
  135. package/node_modules/plexus-agent-config-web/.next/react-loadable-manifest.json +1 -0
  136. package/node_modules/plexus-agent-config-web/.next/required-server-files.js +337 -0
  137. package/node_modules/plexus-agent-config-web/.next/required-server-files.json +337 -0
  138. package/node_modules/plexus-agent-config-web/.next/routes-manifest.json +286 -0
  139. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error/page.js +32 -0
  140. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error/page.js.nft.json +1 -0
  141. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error/page_client-reference-manifest.js +1 -0
  142. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.html +1 -0
  143. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.meta +16 -0
  144. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.rsc +14 -0
  145. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_full.segment.rsc +14 -0
  146. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_global-error/__PAGE__.segment.rsc +5 -0
  147. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_global-error.segment.rsc +5 -0
  148. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_head.segment.rsc +5 -0
  149. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_index.segment.rsc +5 -0
  150. package/node_modules/plexus-agent-config-web/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -0
  151. package/node_modules/plexus-agent-config-web/.next/server/app/_not-found/page.js +2 -0
  152. package/node_modules/plexus-agent-config-web/.next/server/app/_not-found/page.js.nft.json +1 -0
  153. package/node_modules/plexus-agent-config-web/.next/server/app/_not-found/page_client-reference-manifest.js +1 -0
  154. package/node_modules/plexus-agent-config-web/.next/server/app/about/page.js +2 -0
  155. package/node_modules/plexus-agent-config-web/.next/server/app/about/page.js.nft.json +1 -0
  156. package/node_modules/plexus-agent-config-web/.next/server/app/about/page_client-reference-manifest.js +1 -0
  157. package/node_modules/plexus-agent-config-web/.next/server/app/agents/[id]/page.js +2 -0
  158. package/node_modules/plexus-agent-config-web/.next/server/app/agents/[id]/page.js.nft.json +1 -0
  159. package/node_modules/plexus-agent-config-web/.next/server/app/agents/[id]/page_client-reference-manifest.js +1 -0
  160. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/file/route.js +1 -0
  161. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/file/route.js.nft.json +1 -0
  162. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/file/route_client-reference-manifest.js +1 -0
  163. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/route.js +1 -0
  164. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/route.js.nft.json +1 -0
  165. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent/[id]/route_client-reference-manifest.js +1 -0
  166. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent-catalog/route.js +1 -0
  167. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent-catalog/route.js.nft.json +1 -0
  168. package/node_modules/plexus-agent-config-web/.next/server/app/api/agent-catalog/route_client-reference-manifest.js +1 -0
  169. package/node_modules/plexus-agent-config-web/.next/server/app/api/agents/route.js +1 -0
  170. package/node_modules/plexus-agent-config-web/.next/server/app/api/agents/route.js.nft.json +1 -0
  171. package/node_modules/plexus-agent-config-web/.next/server/app/api/agents/route_client-reference-manifest.js +1 -0
  172. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/[id]/restore/route.js +1 -0
  173. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/[id]/restore/route.js.nft.json +1 -0
  174. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/[id]/restore/route_client-reference-manifest.js +1 -0
  175. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/route.js +1 -0
  176. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/route.js.nft.json +1 -0
  177. package/node_modules/plexus-agent-config-web/.next/server/app/api/backups/route_client-reference-manifest.js +1 -0
  178. package/node_modules/plexus-agent-config-web/.next/server/app/api/config/route.js +1 -0
  179. package/node_modules/plexus-agent-config-web/.next/server/app/api/config/route.js.nft.json +1 -0
  180. package/node_modules/plexus-agent-config-web/.next/server/app/api/config/route_client-reference-manifest.js +1 -0
  181. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/file/route.js +1 -0
  182. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/file/route.js.nft.json +1 -0
  183. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/file/route_client-reference-manifest.js +1 -0
  184. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/route.js +1 -0
  185. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/route.js.nft.json +1 -0
  186. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/[id]/route_client-reference-manifest.js +1 -0
  187. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/route.js +1 -0
  188. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/route.js.nft.json +1 -0
  189. package/node_modules/plexus-agent-config-web/.next/server/app/api/custom-agents/route_client-reference-manifest.js +1 -0
  190. package/node_modules/plexus-agent-config-web/.next/server/app/api/debug/route.js +1 -0
  191. package/node_modules/plexus-agent-config-web/.next/server/app/api/debug/route.js.nft.json +1 -0
  192. package/node_modules/plexus-agent-config-web/.next/server/app/api/debug/route_client-reference-manifest.js +1 -0
  193. package/node_modules/plexus-agent-config-web/.next/server/app/api/import/route.js +1 -0
  194. package/node_modules/plexus-agent-config-web/.next/server/app/api/import/route.js.nft.json +1 -0
  195. package/node_modules/plexus-agent-config-web/.next/server/app/api/import/route_client-reference-manifest.js +1 -0
  196. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/[id]/toggle/route.js +1 -0
  197. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/[id]/toggle/route.js.nft.json +1 -0
  198. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/[id]/toggle/route_client-reference-manifest.js +1 -0
  199. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/effective/route.js +1 -0
  200. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/effective/route.js.nft.json +1 -0
  201. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/effective/route_client-reference-manifest.js +1 -0
  202. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/route.js +1 -0
  203. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/route.js.nft.json +1 -0
  204. package/node_modules/plexus-agent-config-web/.next/server/app/api/mcp/route_client-reference-manifest.js +1 -0
  205. package/node_modules/plexus-agent-config-web/.next/server/app/api/rules/route.js +1 -0
  206. package/node_modules/plexus-agent-config-web/.next/server/app/api/rules/route.js.nft.json +1 -0
  207. package/node_modules/plexus-agent-config-web/.next/server/app/api/rules/route_client-reference-manifest.js +1 -0
  208. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/route.js +1 -0
  209. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/route.js.nft.json +1 -0
  210. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/route_client-reference-manifest.js +1 -0
  211. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/toggle/route.js +1 -0
  212. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/toggle/route.js.nft.json +1 -0
  213. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/[id]/toggle/route_client-reference-manifest.js +1 -0
  214. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/effective/route.js +1 -0
  215. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/effective/route.js.nft.json +1 -0
  216. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/effective/route_client-reference-manifest.js +1 -0
  217. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/route.js +1 -0
  218. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/route.js.nft.json +1 -0
  219. package/node_modules/plexus-agent-config-web/.next/server/app/api/skills/route_client-reference-manifest.js +1 -0
  220. package/node_modules/plexus-agent-config-web/.next/server/app/api/spread/route.js +1 -0
  221. package/node_modules/plexus-agent-config-web/.next/server/app/api/spread/route.js.nft.json +1 -0
  222. package/node_modules/plexus-agent-config-web/.next/server/app/api/spread/route_client-reference-manifest.js +1 -0
  223. package/node_modules/plexus-agent-config-web/.next/server/app/api/sync/route.js +1 -0
  224. package/node_modules/plexus-agent-config-web/.next/server/app/api/sync/route.js.nft.json +1 -0
  225. package/node_modules/plexus-agent-config-web/.next/server/app/api/sync/route_client-reference-manifest.js +1 -0
  226. package/node_modules/plexus-agent-config-web/.next/server/app/api/team/route.js +1 -0
  227. package/node_modules/plexus-agent-config-web/.next/server/app/api/team/route.js.nft.json +1 -0
  228. package/node_modules/plexus-agent-config-web/.next/server/app/api/team/route_client-reference-manifest.js +1 -0
  229. package/node_modules/plexus-agent-config-web/.next/server/app/backups/page.js +4 -0
  230. package/node_modules/plexus-agent-config-web/.next/server/app/backups/page.js.nft.json +1 -0
  231. package/node_modules/plexus-agent-config-web/.next/server/app/backups/page_client-reference-manifest.js +1 -0
  232. package/node_modules/plexus-agent-config-web/.next/server/app/debug/page.js +2 -0
  233. package/node_modules/plexus-agent-config-web/.next/server/app/debug/page.js.nft.json +1 -0
  234. package/node_modules/plexus-agent-config-web/.next/server/app/debug/page_client-reference-manifest.js +1 -0
  235. package/node_modules/plexus-agent-config-web/.next/server/app/mcp/page.js +2 -0
  236. package/node_modules/plexus-agent-config-web/.next/server/app/mcp/page.js.nft.json +1 -0
  237. package/node_modules/plexus-agent-config-web/.next/server/app/mcp/page_client-reference-manifest.js +1 -0
  238. package/node_modules/plexus-agent-config-web/.next/server/app/mirror/page.js +2 -0
  239. package/node_modules/plexus-agent-config-web/.next/server/app/mirror/page.js.nft.json +1 -0
  240. package/node_modules/plexus-agent-config-web/.next/server/app/mirror/page_client-reference-manifest.js +1 -0
  241. package/node_modules/plexus-agent-config-web/.next/server/app/page.js +2 -0
  242. package/node_modules/plexus-agent-config-web/.next/server/app/page.js.nft.json +1 -0
  243. package/node_modules/plexus-agent-config-web/.next/server/app/page_client-reference-manifest.js +1 -0
  244. package/node_modules/plexus-agent-config-web/.next/server/app/rules/page.js +10 -0
  245. package/node_modules/plexus-agent-config-web/.next/server/app/rules/page.js.nft.json +1 -0
  246. package/node_modules/plexus-agent-config-web/.next/server/app/rules/page_client-reference-manifest.js +1 -0
  247. package/node_modules/plexus-agent-config-web/.next/server/app/settings/page.js +2 -0
  248. package/node_modules/plexus-agent-config-web/.next/server/app/settings/page.js.nft.json +1 -0
  249. package/node_modules/plexus-agent-config-web/.next/server/app/settings/page_client-reference-manifest.js +1 -0
  250. package/node_modules/plexus-agent-config-web/.next/server/app/skills/page.js +2 -0
  251. package/node_modules/plexus-agent-config-web/.next/server/app/skills/page.js.nft.json +1 -0
  252. package/node_modules/plexus-agent-config-web/.next/server/app/skills/page_client-reference-manifest.js +1 -0
  253. package/node_modules/plexus-agent-config-web/.next/server/app/spread/page.js +2 -0
  254. package/node_modules/plexus-agent-config-web/.next/server/app/spread/page.js.nft.json +1 -0
  255. package/node_modules/plexus-agent-config-web/.next/server/app/spread/page_client-reference-manifest.js +1 -0
  256. package/node_modules/plexus-agent-config-web/.next/server/app/team/page.js +2 -0
  257. package/node_modules/plexus-agent-config-web/.next/server/app/team/page.js.nft.json +1 -0
  258. package/node_modules/plexus-agent-config-web/.next/server/app/team/page_client-reference-manifest.js +1 -0
  259. package/node_modules/plexus-agent-config-web/.next/server/app-paths-manifest.json +39 -0
  260. package/node_modules/plexus-agent-config-web/.next/server/chunks/103.js +18 -0
  261. package/node_modules/plexus-agent-config-web/.next/server/chunks/174.js +1 -0
  262. package/node_modules/plexus-agent-config-web/.next/server/chunks/380.js +1 -0
  263. package/node_modules/plexus-agent-config-web/.next/server/chunks/397.js +26 -0
  264. package/node_modules/plexus-agent-config-web/.next/server/chunks/479.js +45 -0
  265. package/node_modules/plexus-agent-config-web/.next/server/chunks/620.js +1 -0
  266. package/node_modules/plexus-agent-config-web/.next/server/chunks/750.js +1 -0
  267. package/node_modules/plexus-agent-config-web/.next/server/chunks/921.js +5 -0
  268. package/node_modules/plexus-agent-config-web/.next/server/functions-config-manifest.json +4 -0
  269. package/node_modules/plexus-agent-config-web/.next/server/interception-route-rewrite-manifest.js +1 -0
  270. package/node_modules/plexus-agent-config-web/.next/server/middleware-build-manifest.js +1 -0
  271. package/node_modules/plexus-agent-config-web/.next/server/middleware-manifest.json +6 -0
  272. package/node_modules/plexus-agent-config-web/.next/server/middleware-react-loadable-manifest.js +1 -0
  273. package/node_modules/plexus-agent-config-web/.next/server/next-font-manifest.js +1 -0
  274. package/node_modules/plexus-agent-config-web/.next/server/next-font-manifest.json +1 -0
  275. package/node_modules/plexus-agent-config-web/.next/server/pages/500.html +1 -0
  276. package/node_modules/plexus-agent-config-web/.next/server/pages-manifest.json +3 -0
  277. package/node_modules/plexus-agent-config-web/.next/server/prefetch-hints.json +1 -0
  278. package/node_modules/plexus-agent-config-web/.next/server/server-reference-manifest.js +1 -0
  279. package/node_modules/plexus-agent-config-web/.next/server/server-reference-manifest.json +1 -0
  280. package/node_modules/plexus-agent-config-web/.next/server/webpack-runtime.js +1 -0
  281. package/node_modules/plexus-agent-config-web/.next/static/chunks/1968-9d19293a29f03646.js +32 -0
  282. package/node_modules/plexus-agent-config-web/.next/static/chunks/3051-5eb2f5784474c658.js +1 -0
  283. package/node_modules/plexus-agent-config-web/.next/static/chunks/3090-3702701c503793f0.js +1 -0
  284. package/node_modules/plexus-agent-config-web/.next/static/chunks/4399-7cc367307a2c52a6.js +1 -0
  285. package/node_modules/plexus-agent-config-web/.next/static/chunks/5587-933f3258279c6072.js +1 -0
  286. package/node_modules/plexus-agent-config-web/.next/static/chunks/626-7ea78ce012c8d471.js +1 -0
  287. package/node_modules/plexus-agent-config-web/.next/static/chunks/7814-1bc9d30b9724b70c.js +1 -0
  288. package/node_modules/plexus-agent-config-web/.next/static/chunks/87c73c54-64138e17754e338c.js +1 -0
  289. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/_global-error/page-fe6298e28540d3d8.js +1 -0
  290. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/_not-found/page-303a3bb713044693.js +1 -0
  291. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/about/page-64a1ee41b87ea86c.js +1 -0
  292. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/agents/[id]/page-c3c89d8ae72c75c2.js +1 -0
  293. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/agent/[id]/file/route-fe6298e28540d3d8.js +1 -0
  294. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/agent/[id]/route-fe6298e28540d3d8.js +1 -0
  295. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/agent-catalog/route-fe6298e28540d3d8.js +1 -0
  296. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/agents/route-fe6298e28540d3d8.js +1 -0
  297. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/backups/[id]/restore/route-fe6298e28540d3d8.js +1 -0
  298. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/backups/route-fe6298e28540d3d8.js +1 -0
  299. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/config/route-fe6298e28540d3d8.js +1 -0
  300. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/custom-agents/[id]/file/route-fe6298e28540d3d8.js +1 -0
  301. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/custom-agents/[id]/route-fe6298e28540d3d8.js +1 -0
  302. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/custom-agents/route-fe6298e28540d3d8.js +1 -0
  303. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/debug/route-fe6298e28540d3d8.js +1 -0
  304. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/import/route-fe6298e28540d3d8.js +1 -0
  305. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/mcp/[id]/toggle/route-fe6298e28540d3d8.js +1 -0
  306. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/mcp/effective/route-fe6298e28540d3d8.js +1 -0
  307. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/mcp/route-fe6298e28540d3d8.js +1 -0
  308. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/rules/route-fe6298e28540d3d8.js +1 -0
  309. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/skills/[id]/route-fe6298e28540d3d8.js +1 -0
  310. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/skills/[id]/toggle/route-fe6298e28540d3d8.js +1 -0
  311. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/skills/effective/route-fe6298e28540d3d8.js +1 -0
  312. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/skills/route-fe6298e28540d3d8.js +1 -0
  313. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/spread/route-fe6298e28540d3d8.js +1 -0
  314. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/sync/route-fe6298e28540d3d8.js +1 -0
  315. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/api/team/route-fe6298e28540d3d8.js +1 -0
  316. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/backups/page-6842a663db4fab47.js +3 -0
  317. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/debug/page-19e534df1d13eb98.js +1 -0
  318. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/layout-798b3b697994c5bf.js +1 -0
  319. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/mcp/page-d0d518965db961f1.js +1 -0
  320. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/mirror/page-e88f348e1a12487a.js +1 -0
  321. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/page-039dbbfad47ff659.js +1 -0
  322. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/rules/page-5bb663fc0ee9960b.js +9 -0
  323. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/settings/page-8164e1d1a8a08038.js +1 -0
  324. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/skills/page-6067058898aa6e10.js +1 -0
  325. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/spread/page-fe6298e28540d3d8.js +1 -0
  326. package/node_modules/plexus-agent-config-web/.next/static/chunks/app/team/page-edd7f54640e60e94.js +1 -0
  327. package/node_modules/plexus-agent-config-web/.next/static/chunks/framework-2c03ddc44b9f482b.js +1 -0
  328. package/node_modules/plexus-agent-config-web/.next/static/chunks/main-488dba80110e3bfb.js +5 -0
  329. package/node_modules/plexus-agent-config-web/.next/static/chunks/main-app-4c4bad3c22a66283.js +1 -0
  330. package/node_modules/plexus-agent-config-web/.next/static/chunks/next/dist/client/components/builtin/app-error-fe6298e28540d3d8.js +1 -0
  331. package/node_modules/plexus-agent-config-web/.next/static/chunks/next/dist/client/components/builtin/forbidden-fe6298e28540d3d8.js +1 -0
  332. package/node_modules/plexus-agent-config-web/.next/static/chunks/next/dist/client/components/builtin/global-error-821a044f296e83b5.js +1 -0
  333. package/node_modules/plexus-agent-config-web/.next/static/chunks/next/dist/client/components/builtin/not-found-fe6298e28540d3d8.js +1 -0
  334. package/node_modules/plexus-agent-config-web/.next/static/chunks/next/dist/client/components/builtin/unauthorized-fe6298e28540d3d8.js +1 -0
  335. package/node_modules/plexus-agent-config-web/.next/static/chunks/polyfills-42372ed130431b0a.js +1 -0
  336. package/node_modules/plexus-agent-config-web/.next/static/chunks/webpack-dd4b9bd51624284c.js +1 -0
  337. package/node_modules/plexus-agent-config-web/.next/static/css/eba3657411e6e6cd.css +5 -0
  338. package/node_modules/plexus-agent-config-web/.next/static/media/19cfc7226ec3afaa-s.woff2 +0 -0
  339. package/node_modules/plexus-agent-config-web/.next/static/media/21350d82a1f187e9-s.woff2 +0 -0
  340. package/node_modules/plexus-agent-config-web/.next/static/media/8e9860b6e62d6359-s.woff2 +0 -0
  341. package/node_modules/plexus-agent-config-web/.next/static/media/ba9851c3c22cd980-s.woff2 +0 -0
  342. package/node_modules/plexus-agent-config-web/.next/static/media/c5fe6dc8356a8c31-s.woff2 +0 -0
  343. package/node_modules/plexus-agent-config-web/.next/static/media/df0a9ae256c0569c-s.woff2 +0 -0
  344. package/node_modules/plexus-agent-config-web/.next/static/media/e4af272ccee01ff0-s.p.woff2 +0 -0
  345. package/node_modules/plexus-agent-config-web/.next/static/mvb1RnSdmeAxbYF-SjSfa/_buildManifest.js +1 -0
  346. package/node_modules/plexus-agent-config-web/.next/static/mvb1RnSdmeAxbYF-SjSfa/_ssgManifest.js +1 -0
  347. package/node_modules/plexus-agent-config-web/next.config.mjs +17 -0
  348. package/node_modules/plexus-agent-config-web/package.json +40 -0
  349. package/node_modules/plexus-agent-config-web/public/architecture/config-sharing-map.html +887 -0
  350. package/node_modules/plexus-agent-config-web/public/favicon.svg +5 -0
  351. package/package.json +64 -0
package/dist/bin.d.ts ADDED
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=bin.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"bin.d.ts","sourceRoot":"","sources":["../src/bin.ts"],"names":[],"mappings":""}
package/dist/bin.js ADDED
@@ -0,0 +1,175 @@
1
+ #!/usr/bin/env node
2
+ import { spawn } from "node:child_process";
3
+ import { existsSync } from "node:fs";
4
+ import { createRequire } from "node:module";
5
+ import path from "node:path";
6
+ import { fileURLToPath } from "node:url";
7
+ import kleur from "kleur";
8
+ import { ALL_AGENTS, detectAgents, ensureStoreScaffolding, joinTeam, pullTeam, runShareAll, teamStatus, } from "plexus-agent-config-core";
9
+ const __filename = fileURLToPath(import.meta.url);
10
+ const __dirname = path.dirname(__filename);
11
+ const require = createRequire(import.meta.url);
12
+ function help() {
13
+ console.log(`
14
+ ${kleur.bold("Plexus")} – team-shared AI agent config
15
+
16
+ ${kleur.bold("Usage:")}
17
+ plexus start the local dashboard (default)
18
+ plexus start [-p <port>]
19
+ plexus detect list detected AI agents on this machine
20
+ plexus join <git-url> subscribe to a team config repo
21
+ plexus pull refresh the team layer from upstream
22
+ plexus sync [--prefer <agent>] import, share, and apply config to all enabled agents
23
+ plexus status show subscription / sync status
24
+ plexus help show this help
25
+ `);
26
+ }
27
+ async function cmdDetect() {
28
+ const agents = detectAgents();
29
+ for (const a of agents) {
30
+ const tag = a.installed ? kleur.green("installed") : kleur.gray("missing ");
31
+ console.log(` ${tag} ${a.displayName.padEnd(16)} ${kleur.dim(a.rootDir)}`);
32
+ }
33
+ }
34
+ const AGENTS = new Set(ALL_AGENTS);
35
+ function preferredAgentFromArgs(args) {
36
+ const idx = args.findIndex((arg) => arg === "--prefer" || arg === "--primary");
37
+ if (idx < 0)
38
+ return undefined;
39
+ const value = args[idx + 1];
40
+ if (!AGENTS.has(value ?? "")) {
41
+ console.error(kleur.red(`Usage: plexus sync --prefer <${ALL_AGENTS.join("|")}>`));
42
+ process.exit(1);
43
+ }
44
+ return value;
45
+ }
46
+ async function cmdSync(args) {
47
+ await ensureStoreScaffolding();
48
+ const preferredAgent = preferredAgentFromArgs(args);
49
+ console.log(kleur.cyan("→ sharing config across all enabled agents..."));
50
+ const report = await runShareAll({ preferredAgent });
51
+ if (report.preferredAgent && report.conflictsResolved > 0) {
52
+ console.log(` ${kleur.green("✓")} resolved ${report.conflictsResolved} conflict(s) with ${report.preferredAgent}`);
53
+ }
54
+ console.log(` ${kleur.green("✓")} imported ${report.imported.mcpWritten + report.imported.mcpExtended} MCP and ${report.imported.skillsWritten + report.imported.skillsExtended} skills`);
55
+ console.log(` ${kleur.green("✓")} enabled ${report.shared.mcp} MCP and ${report.shared.skills} skills`);
56
+ if (report.rules.skipped) {
57
+ console.log(` ${kleur.yellow("warn")} ${report.rules.skipped}`);
58
+ }
59
+ else {
60
+ console.log(` ${kleur.green("✓")} applied rules to ${report.rules.applied.filter((r) => r.applied).length} agent files`);
61
+ }
62
+ for (const r of report.results) {
63
+ const ok = r.errors.length === 0;
64
+ const head = ok ? kleur.green("✓") : kleur.red("✗");
65
+ console.log(` ${head} ${r.agent.padEnd(16)} mcp=${r.applied.mcp} skills=${r.applied.skills}`);
66
+ for (const w of r.warnings)
67
+ console.log(` ${kleur.yellow("warn")} ${w}`);
68
+ for (const e of r.errors)
69
+ console.log(` ${kleur.red("err ")} ${e}`);
70
+ }
71
+ }
72
+ async function cmdStatus() {
73
+ const ts = await teamStatus();
74
+ if (ts.subscribed) {
75
+ console.log(`Team: ${kleur.cyan(ts.repoUrl ?? "")}`);
76
+ if (ts.hasUpstreamUpdate) {
77
+ console.log(` ${kleur.yellow(`⟳ ${ts.behind} update(s) available – run 'plexus pull'`)}`);
78
+ }
79
+ else {
80
+ console.log(` ${kleur.green("up-to-date")}`);
81
+ }
82
+ }
83
+ else {
84
+ console.log(`Team: ${kleur.gray("not subscribed")} (run 'plexus join <git-url>')`);
85
+ }
86
+ await cmdDetect();
87
+ }
88
+ function findWebDir() {
89
+ const installedWebDir = (() => {
90
+ try {
91
+ return path.dirname(require.resolve("plexus-agent-config-web/package.json"));
92
+ }
93
+ catch {
94
+ return null;
95
+ }
96
+ })();
97
+ const candidates = [
98
+ installedWebDir,
99
+ // Monorepo development / npm link paths.
100
+ path.resolve(__dirname, "../../../apps/web"),
101
+ path.resolve(__dirname, "../../apps/web"),
102
+ path.resolve(process.cwd(), "apps/web"),
103
+ ].filter((candidate) => Boolean(candidate));
104
+ for (const c of candidates) {
105
+ if (existsSync(path.join(c, "package.json")))
106
+ return c;
107
+ }
108
+ return null;
109
+ }
110
+ async function cmdStart(port) {
111
+ await ensureStoreScaffolding();
112
+ const webDir = findWebDir();
113
+ if (!webDir) {
114
+ console.error(kleur.red("Could not locate apps/web. If you cloned the monorepo, run from the repo root."));
115
+ process.exit(1);
116
+ }
117
+ const env = { ...process.env, PORT: String(port), PLEXUS_PORT: String(port) };
118
+ const isProdBuild = existsSync(path.join(webDir, ".next"));
119
+ const args = isProdBuild ? ["run", "start"] : ["run", "dev"];
120
+ console.log(kleur.cyan(`→ Starting Plexus dashboard on http://localhost:${port}`));
121
+ console.log(kleur.dim(` (mode: ${isProdBuild ? "production" : "development"})`));
122
+ const child = spawn("npm", [...args, "--", "-p", String(port)], {
123
+ cwd: webDir,
124
+ env,
125
+ stdio: "inherit",
126
+ });
127
+ child.on("exit", (code) => process.exit(code ?? 0));
128
+ }
129
+ async function main() {
130
+ const [, , cmd = "start", ...rest] = process.argv;
131
+ switch (cmd) {
132
+ case "help":
133
+ case "--help":
134
+ case "-h":
135
+ help();
136
+ return;
137
+ case "detect":
138
+ await cmdDetect();
139
+ return;
140
+ case "sync":
141
+ await cmdSync(rest);
142
+ return;
143
+ case "status":
144
+ await cmdStatus();
145
+ return;
146
+ case "join": {
147
+ const url = rest[0];
148
+ if (!url) {
149
+ console.error(kleur.red("Usage: plexus join <git-url>"));
150
+ process.exit(1);
151
+ }
152
+ const r = await joinTeam(url);
153
+ console.log(r.ok ? kleur.green(r.message) : kleur.red(r.message));
154
+ process.exit(r.ok ? 0 : 1);
155
+ return;
156
+ }
157
+ case "pull": {
158
+ const r = await pullTeam();
159
+ console.log(r.ok ? kleur.green(r.message) : kleur.red(r.message));
160
+ process.exit(r.ok ? 0 : 1);
161
+ return;
162
+ }
163
+ default: {
164
+ const portFlagIdx = rest.findIndex((a) => a === "-p" || a === "--port");
165
+ const port = portFlagIdx >= 0 ? Number.parseInt(rest[portFlagIdx + 1] ?? "7777", 10) : 7777;
166
+ await cmdStart(port);
167
+ return;
168
+ }
169
+ }
170
+ }
171
+ main().catch((err) => {
172
+ console.error(kleur.red("Fatal:"), err);
173
+ process.exit(1);
174
+ });
175
+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W,GAAG,CAAC,CAAC,IAAI,MAAM,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;YAC5F,MAAM,QAAQ,CAAC,IAAI,CAAC,CAAC;YACrB,OAAO;QACT,CAAC;IACH,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,CAAC,GAAG,EAAE,EAAE;IACnB,OAAO,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,GAAG,CAAC,CAAC;IACxC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC;AAClB,CAAC,CAAC,CAAC"}
@@ -0,0 +1,38 @@
1
+ import type { AgentId, MCPServerDef, SkillDef, SyncResult } from "../../types.js";
2
+ export interface ApplyContext {
3
+ agentId: AgentId;
4
+ mcp: MCPServerDef[];
5
+ skills: SkillDef[];
6
+ /** Where merged skills live on disk; adapters can symlink to these. */
7
+ skillSourcePaths: Map<string, string>;
8
+ syncStrategy: "symlink" | "copy";
9
+ }
10
+ export interface AgentAdapter {
11
+ id: AgentId;
12
+ apply(ctx: ApplyContext): Promise<SyncResult>;
13
+ }
14
+ export declare function ensureDir(dir: string): Promise<void>;
15
+ export declare function pathExists(p: string): Promise<boolean>;
16
+ export declare function isSymlink(p: string): Promise<boolean>;
17
+ /**
18
+ * Place `target` at `linkPath` either as a symlink (preferred) or copy fallback.
19
+ *
20
+ * If the destination is an existing real file/dir we evict it into the
21
+ * central Plexus backups area (~/.config/plexus/backups/_collisions/<ts>/...)
22
+ * BEFORE placing the new symlink. Older inline `.plexus-backup-<ts>` residue
23
+ * in agent directories is no longer created by this function.
24
+ */
25
+ export declare function placeLinkOrCopy(target: string, linkPath: string, strategy: "symlink" | "copy"): Promise<{
26
+ via: "symlink" | "copy";
27
+ backedUp?: string;
28
+ }>;
29
+ export declare function emptyResult(agentId: AgentId): SyncResult;
30
+ /**
31
+ * Replace a regular file at `linkPath` with a symlink pointing at `target`.
32
+ * If symlink isn't supported (Windows without privilege), falls back to a copy.
33
+ *
34
+ * Caller is responsible for invoking the backup module BEFORE calling this —
35
+ * we do not silently overwrite without a snapshot existing somewhere.
36
+ */
37
+ export declare function placeFileSymlink(target: string, linkPath: string, strategy: "symlink" | "copy"): Promise<"symlink" | "copy">;
38
+ //# sourceMappingURL=base.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/base.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAElF,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,OAAO,CAAC;IACjB,GAAG,EAAE,YAAY,EAAE,CAAC;IACpB,MAAM,EAAE,QAAQ,EAAE,CAAC;IACnB,uEAAuE;IACvE,gBAAgB,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACtC,YAAY,EAAE,SAAS,GAAG,MAAM,CAAC;CAClC;AAED,MAAM,WAAW,YAAY;IAC3B,EAAE,EAAE,OAAO,CAAC;IACZ,KAAK,CAAC,GAAG,EAAE,YAAY,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;CAC/C;AAED,wBAAsB,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC,CAE1D;AAED,wBAAsB,UAAU,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAO5D;AAED,wBAAsB,SAAS,CAAC,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC,CAO3D;AAED;;;;;;;GAOG;AACH,wBAAsB,eAAe,CACnC,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,SAAS,GAAG,MAAM,GAC3B,OAAO,CAAC;IAAE,GAAG,EAAE,SAAS,GAAG,MAAM,CAAC;IAAC,QAAQ,CAAC,EAAE,MAAM,CAAA;CAAE,CAAC,CAmCzD;AAED,wBAAgB,WAAW,CAAC,OAAO,EAAE,OAAO,GAAG,UAAU,CAOxD;AAED;;;;;;GAMG;AACH,wBAAsB,gBAAgB,CACpC,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM,EAChB,QAAQ,EAAE,SAAS,GAAG,MAAM,GAC3B,OAAO,CAAC,SAAS,GAAG,MAAM,CAAC,CAwC7B"}
@@ -0,0 +1,125 @@
1
+ import fs from "node:fs/promises";
2
+ import path from "node:path";
3
+ export async function ensureDir(dir) {
4
+ await fs.mkdir(dir, { recursive: true });
5
+ }
6
+ export async function pathExists(p) {
7
+ try {
8
+ await fs.access(p);
9
+ return true;
10
+ }
11
+ catch {
12
+ return false;
13
+ }
14
+ }
15
+ export async function isSymlink(p) {
16
+ try {
17
+ const s = await fs.lstat(p);
18
+ return s.isSymbolicLink();
19
+ }
20
+ catch {
21
+ return false;
22
+ }
23
+ }
24
+ /**
25
+ * Place `target` at `linkPath` either as a symlink (preferred) or copy fallback.
26
+ *
27
+ * If the destination is an existing real file/dir we evict it into the
28
+ * central Plexus backups area (~/.config/plexus/backups/_collisions/<ts>/...)
29
+ * BEFORE placing the new symlink. Older inline `.plexus-backup-<ts>` residue
30
+ * in agent directories is no longer created by this function.
31
+ */
32
+ export async function placeLinkOrCopy(target, linkPath, strategy) {
33
+ await ensureDir(path.dirname(linkPath));
34
+ let backedUp;
35
+ if (await pathExists(linkPath)) {
36
+ if (await isSymlink(linkPath)) {
37
+ await fs.unlink(linkPath);
38
+ }
39
+ else {
40
+ const { quarantineCollision } = await import("../../backup/index.js");
41
+ const dest = await quarantineCollision({ agent: "unknown", sourcePath: linkPath });
42
+ if (dest)
43
+ backedUp = dest;
44
+ // After quarantineCollision the original path is gone; fall through to placement.
45
+ }
46
+ }
47
+ if (strategy === "symlink") {
48
+ try {
49
+ const stat = await fs.lstat(target);
50
+ const type = stat.isDirectory() ? "dir" : "file";
51
+ await fs.symlink(target, linkPath, type);
52
+ return { via: "symlink", backedUp };
53
+ }
54
+ catch {
55
+ // Fallback to copy if symlink not supported (e.g. Windows without privilege).
56
+ }
57
+ }
58
+ // copy fallback
59
+ const stat = await fs.lstat(target);
60
+ if (stat.isDirectory()) {
61
+ await fs.cp(target, linkPath, { recursive: true });
62
+ }
63
+ else {
64
+ await fs.copyFile(target, linkPath);
65
+ }
66
+ return { via: "copy", backedUp };
67
+ }
68
+ export function emptyResult(agentId) {
69
+ return {
70
+ agent: agentId,
71
+ applied: { mcp: 0, skills: 0 },
72
+ warnings: [],
73
+ errors: [],
74
+ };
75
+ }
76
+ /**
77
+ * Replace a regular file at `linkPath` with a symlink pointing at `target`.
78
+ * If symlink isn't supported (Windows without privilege), falls back to a copy.
79
+ *
80
+ * Caller is responsible for invoking the backup module BEFORE calling this —
81
+ * we do not silently overwrite without a snapshot existing somewhere.
82
+ */
83
+ export async function placeFileSymlink(target, linkPath, strategy) {
84
+ await ensureDir(path.dirname(linkPath));
85
+ let lst = null;
86
+ try {
87
+ lst = await fs.lstat(linkPath);
88
+ }
89
+ catch {
90
+ // not present yet — fine
91
+ }
92
+ if (lst) {
93
+ if (lst.isSymbolicLink()) {
94
+ try {
95
+ const current = await fs.readlink(linkPath);
96
+ const resolved = path.isAbsolute(current)
97
+ ? current
98
+ : path.resolve(path.dirname(linkPath), current);
99
+ if (resolved === path.resolve(target)) {
100
+ return "symlink"; // already correct
101
+ }
102
+ }
103
+ catch {
104
+ // fall through
105
+ }
106
+ await fs.unlink(linkPath);
107
+ }
108
+ else {
109
+ // Regular file — remove (caller already snapshotted).
110
+ await fs.unlink(linkPath);
111
+ }
112
+ }
113
+ if (strategy === "symlink") {
114
+ try {
115
+ await fs.symlink(target, linkPath, "file");
116
+ return "symlink";
117
+ }
118
+ catch {
119
+ // fall through to copy
120
+ }
121
+ }
122
+ await fs.copyFile(target, linkPath);
123
+ return "copy";
124
+ }
125
+ //# sourceMappingURL=base.js.map
@@ -0,0 +1 @@
1
+ {"version":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3C,OAAO,SAAS,CAAC;QACnB,CAAC;QAAC,MAAM,CAAC;YACP,uBAAuB;QACzB,CAAC;IACH,CAAC;IACD,MAAM,EAAE,CAAC,QAAQ,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IACpC,OAAO,MAAM,CAAC;AAChB,CAAC"}
@@ -0,0 +1,9 @@
1
+ import { type AgentAdapter } from "./base.js";
2
+ /**
3
+ * Codex adapter.
4
+ *
5
+ * Codex stores MCP servers in TOML at ~/.codex/config.toml under
6
+ * `[mcp_servers.<id>]` tables. Skills go under ~/.codex/skills.
7
+ */
8
+ export declare const codexAdapter: AgentAdapter;
9
+ //# sourceMappingURL=codex.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codex.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/codex.ts"],"names":[],"mappings":"AAKA,OAAO,EACL,KAAK,YAAY,EAKlB,MAAM,WAAW,CAAC;AAEnB;;;;;GAKG;AACH,eAAO,MAAM,YAAY,EAAE,YAoF1B,CAAC"}
@@ -0,0 +1,96 @@
1
+ import fs from "node:fs/promises";
2
+ import path from "node:path";
3
+ import TOML from "@iarna/toml";
4
+ import { AGENT_PATHS } from "../../store/paths.js";
5
+ import { emptyResult, ensureDir, placeLinkOrCopy, } from "./base.js";
6
+ /**
7
+ * Codex adapter.
8
+ *
9
+ * Codex stores MCP servers in TOML at ~/.codex/config.toml under
10
+ * `[mcp_servers.<id>]` tables. Skills go under ~/.codex/skills.
11
+ */
12
+ export const codexAdapter = {
13
+ id: "codex",
14
+ async apply(ctx) {
15
+ const result = emptyResult("codex");
16
+ const caps = AGENT_PATHS.codex;
17
+ // ── MCP (JSON → TOML) ─────────────────────────────────
18
+ try {
19
+ await ensureDir(path.dirname(caps.mcpPath));
20
+ const enabledForAgent = ctx.mcp.filter((s) => s.enabledAgents.includes("codex"));
21
+ const enabledIds = new Set(enabledForAgent.map((s) => s.id));
22
+ const disabledManagedIds = new Set(ctx.mcp.filter((s) => !s.enabledAgents.includes("codex")).map((s) => s.id));
23
+ let existing = {};
24
+ try {
25
+ const raw = await fs.readFile(caps.mcpPath, "utf8");
26
+ existing = TOML.parse(raw);
27
+ }
28
+ catch {
29
+ // first write
30
+ }
31
+ const existingServers = (existing.mcp_servers ?? {});
32
+ const preserved = {};
33
+ for (const [k, v] of Object.entries(existingServers)) {
34
+ if (disabledManagedIds.has(k))
35
+ continue;
36
+ if (enabledIds.has(k))
37
+ continue; // will be replaced below
38
+ preserved[k] = v;
39
+ }
40
+ const nextServers = { ...preserved };
41
+ for (const s of enabledForAgent) {
42
+ nextServers[s.id] = {
43
+ command: s.command,
44
+ ...(s.args ? { args: s.args } : {}),
45
+ ...(s.env ? { env: s.env } : {}),
46
+ };
47
+ }
48
+ existing.mcp_servers = nextServers;
49
+ await fs.writeFile(caps.mcpPath, TOML.stringify(existing), "utf8");
50
+ result.applied.mcp = enabledForAgent.length;
51
+ }
52
+ catch (err) {
53
+ result.errors.push(`Codex MCP write failed: ${err.message}`);
54
+ }
55
+ // ── Skills ────────────────────────────────────────────
56
+ try {
57
+ await ensureDir(caps.skillsDir);
58
+ const filtered = ctx.skills.filter((s) => s.enabledAgents.includes("codex"));
59
+ const disabledManagedSkillIds = new Set(ctx.skills.filter((s) => !s.enabledAgents.includes("codex")).map((s) => s.id));
60
+ for (const id of disabledManagedSkillIds) {
61
+ const dir = path.join(caps.skillsDir, id);
62
+ try {
63
+ // Symlink-safe removal: lstat first, unlink for symlinks, rm for real dirs.
64
+ const lst = await fs.lstat(dir);
65
+ if (lst.isSymbolicLink()) {
66
+ await fs.unlink(dir);
67
+ }
68
+ else {
69
+ await fs.rm(dir, { recursive: true, force: true });
70
+ }
71
+ }
72
+ catch {
73
+ // best effort cleanup
74
+ }
75
+ }
76
+ for (const skill of filtered) {
77
+ const sourcePath = ctx.skillSourcePaths.get(skill.id);
78
+ if (!sourcePath)
79
+ continue;
80
+ const destDir = path.join(caps.skillsDir, skill.id);
81
+ try {
82
+ await placeLinkOrCopy(sourcePath, destDir, ctx.syncStrategy);
83
+ result.applied.skills += 1;
84
+ }
85
+ catch (err) {
86
+ result.errors.push(`Skill ${skill.id} sync failed: ${err.message}`);
87
+ }
88
+ }
89
+ }
90
+ catch (err) {
91
+ result.errors.push(`Codex skills sync failed: ${err.message}`);
92
+ }
93
+ return result;
94
+ },
95
+ };
96
+ //# sourceMappingURL=codex.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codex.js","sourceRoot":"","sources":["../../../src/agents/adapters/codex.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAClC,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,IAAI,MAAM,aAAa,CAAC;AAC/B,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AAEnD,OAAO,EAGL,WAAW,EACX,SAAS,EACT,eAAe,GAChB,MAAM,WAAW,CAAC;AAEnB;;;;;GAKG;AACH,MAAM,CAAC,MAAM,YAAY,GAAiB;IACxC,EAAE,EAAE,OAAO;IACX,KAAK,CAAC,KAAK,CAAC,GAAiB;QAC3B,MAAM,MAAM,GAAG,WAAW,CAAC,OAAO,CAAC,CAAC;QACpC,MAAM,IAAI,GAAG,WAAW,CAAC,KAAK,CAAC;QAE/B,yDAAyD;QACzD,IAAI,CAAC;YACH,MAAM,SAAS,CAAC,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC,CAAC;YAE5C,MAAM,eAAe,GAAG,GAAG,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,aAAa,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC;YACjF,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC;YAC7D,MAAM,kBAAkB,GAAG,IAAI,GAAG,CAChC,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base.js";
3
+ import { codexAdapter } from "./codex.js";
4
+ import { makeJsonMcpAdapter } from "./json-mcp.js";
5
+ export declare const adapters: Record<AgentId, AgentAdapter>;
6
+ export { codexAdapter, makeJsonMcpAdapter };
7
+ export type { AgentAdapter, ApplyContext } from "./base.js";
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD,eAAO,MAAM,QAAQ,EAAE,MAAM,CAAC,OAAO,EAAE,YAAY,CAOlD,CAAC;AAEF,OAAO,EAAE,YAAY,EAAE,kBAAkB,EAAE,CAAC;AAC5C,YAAY,EAAE,YAAY,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { codexAdapter } from "./codex.js";
2
+ import { makeJsonMcpAdapter } from "./json-mcp.js";
3
+ export const adapters = {
4
+ "claude-code": makeJsonMcpAdapter("claude-code"),
5
+ cursor: makeJsonMcpAdapter("cursor"),
6
+ codex: codexAdapter,
7
+ "gemini-cli": makeJsonMcpAdapter("gemini-cli"),
8
+ "qwen-code": makeJsonMcpAdapter("qwen-code"),
9
+ "factory-droid": makeJsonMcpAdapter("factory-droid"),
10
+ };
11
+ export { codexAdapter, makeJsonMcpAdapter };
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/agents/adapters/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAC1C,OAAO,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAEnD,MAAM,CAAC,MAAM,QAAQ,GAAkC;IACrD,aAAa,EAAE,kBAAkB,CAAC,aAAa,CAAC;IAChD,MAAM,EAAE,kBAAkB,CAAC,QAAQ,CAAC;IACpC,KAAK,EAAE,YAAY;IACnB,YAAY,EAAE,kBAAkB,CAAC,YAAY,CAAC;IAC9C,WAAW,EAAE,kBAAkB,CAAC,WAAW,CAAC;IAC5C,eAAe,EAAE,kBAAkB,CAAC,eAAe,CAAC;CACrD,CAAC;AAEF,OAAO,EAAE,YAAY,EAAE,kBAAkB,EAAE,CAAC"}
@@ -0,0 +1,25 @@
1
+ import type { AgentId } from "../../types.js";
2
+ import { type AgentAdapter } from "./base.js";
3
+ /**
4
+ * Generic JSON-MCP + skill-directory adapter.
5
+ *
6
+ * Used by Claude Code, Cursor, Gemini CLI, Qwen Code, Factory Droid (and any future agent that
7
+ * stores MCP as `{ "mcpServers": {...} }` JSON and skills as a directory).
8
+ *
9
+ * Two MCP write modes (chosen by AGENT_PATHS[agent].mcpFileMode):
10
+ *
11
+ * - "exclusive": Plexus owns the agent's MCP file. We render a canonical
12
+ * JSON to ~/.config/plexus/.cache/mcp/<agent>.json and symlink the
13
+ * agent's path to that cache. Editing the agent's path is editing the
14
+ * same Plexus-owned file. This is appropriate for agents whose MCP
15
+ * file holds nothing else (Cursor, Factory Droid).
16
+ *
17
+ * - "shared" (default): the agent's file holds many other unrelated keys
18
+ * (for example Claude Code's ~/.claude.json carries auth/history/settings). We
19
+ * partial-write only the `mcpServers` section in place and never replace
20
+ * the whole file.
21
+ *
22
+ * Skills are always symlink-first via placeLinkOrCopy.
23
+ */
24
+ export declare function makeJsonMcpAdapter(agentId: AgentId): AgentAdapter;
25
+ //# sourceMappingURL=json-mcp.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"json-mcp.d.ts","sourceRoot":"","sources":["../../../src/agents/adapters/json-mcp.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,OAAO,EAA4B,MAAM,gBAAgB,CAAC;AACxE,OAAO,EACL,KAAK,YAAY,EAMlB,MAAM,WAAW,CAAC;AAEnB;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,kBAAkB,CAAC,OAAO,EAAE,OAAO,GAAG,YAAY,CA8DjE"}