@sentry/warden 0.0.0 → 0.1.0

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 (546) hide show
  1. package/.github/workflows/ci.yml +1 -1
  2. package/.github/workflows/release.yml +6 -1
  3. package/.github/workflows/warden.yml +1 -1
  4. package/dist/action/159.index.js +523 -0
  5. package/dist/action/159.index.js.map +1 -0
  6. package/dist/action/action/index.d.ts +2 -0
  7. package/dist/action/action/index.d.ts.map +1 -0
  8. package/dist/action/action/main.d.ts +2 -0
  9. package/dist/action/action/main.d.ts.map +1 -0
  10. package/dist/action/cli/args.d.ts +74 -0
  11. package/dist/action/cli/args.d.ts.map +1 -0
  12. package/dist/action/cli/args.test.d.ts +2 -0
  13. package/dist/action/cli/args.test.d.ts.map +1 -0
  14. package/dist/action/cli/commands/add.d.ts +7 -0
  15. package/dist/action/cli/commands/add.d.ts.map +1 -0
  16. package/dist/action/cli/commands/init.d.ts +10 -0
  17. package/dist/action/cli/commands/init.d.ts.map +1 -0
  18. package/dist/action/cli/commands/init.test.d.ts +2 -0
  19. package/dist/action/cli/commands/init.test.d.ts.map +1 -0
  20. package/dist/action/cli/commands/setup-app/browser.d.ts +9 -0
  21. package/dist/action/cli/commands/setup-app/browser.d.ts.map +1 -0
  22. package/dist/action/cli/commands/setup-app/credentials.d.ts +15 -0
  23. package/dist/action/cli/commands/setup-app/credentials.d.ts.map +1 -0
  24. package/dist/action/cli/commands/setup-app/manifest.d.ts +24 -0
  25. package/dist/action/cli/commands/setup-app/manifest.d.ts.map +1 -0
  26. package/dist/action/cli/commands/setup-app/server.d.ts +28 -0
  27. package/dist/action/cli/commands/setup-app/server.d.ts.map +1 -0
  28. package/dist/action/cli/commands/setup-app.d.ts +11 -0
  29. package/dist/action/cli/commands/setup-app.d.ts.map +1 -0
  30. package/dist/action/cli/commands/sync.d.ts +9 -0
  31. package/dist/action/cli/commands/sync.d.ts.map +1 -0
  32. package/dist/action/cli/context.d.ts +27 -0
  33. package/dist/action/cli/context.d.ts.map +1 -0
  34. package/dist/action/cli/files.d.ts +22 -0
  35. package/dist/action/cli/files.d.ts.map +1 -0
  36. package/dist/action/cli/files.test.d.ts +2 -0
  37. package/dist/action/cli/files.test.d.ts.map +1 -0
  38. package/dist/action/cli/fix.d.ts +41 -0
  39. package/dist/action/cli/fix.d.ts.map +1 -0
  40. package/dist/action/cli/fix.test.d.ts +2 -0
  41. package/dist/action/cli/fix.test.d.ts.map +1 -0
  42. package/dist/action/cli/git.d.ts +73 -0
  43. package/dist/action/cli/git.d.ts.map +1 -0
  44. package/dist/action/cli/git.test.d.ts +2 -0
  45. package/dist/action/cli/git.test.d.ts.map +1 -0
  46. package/dist/action/cli/index.d.ts +3 -0
  47. package/dist/action/cli/index.d.ts.map +1 -0
  48. package/dist/action/cli/main.d.ts +7 -0
  49. package/dist/action/cli/main.d.ts.map +1 -0
  50. package/dist/action/cli/output/box.d.ts +75 -0
  51. package/dist/action/cli/output/box.d.ts.map +1 -0
  52. package/dist/action/cli/output/formatters.d.ts +90 -0
  53. package/dist/action/cli/output/formatters.d.ts.map +1 -0
  54. package/dist/action/cli/output/formatters.test.d.ts +2 -0
  55. package/dist/action/cli/output/formatters.test.d.ts.map +1 -0
  56. package/dist/action/cli/output/icons.d.ts +11 -0
  57. package/dist/action/cli/output/icons.d.ts.map +1 -0
  58. package/dist/action/cli/output/index.d.ts +10 -0
  59. package/dist/action/cli/output/index.d.ts.map +1 -0
  60. package/dist/action/cli/output/ink-runner.d.ts +9 -0
  61. package/dist/action/cli/output/ink-runner.d.ts.map +1 -0
  62. package/dist/action/cli/output/jsonl.d.ts +43 -0
  63. package/dist/action/cli/output/jsonl.d.ts.map +1 -0
  64. package/dist/action/cli/output/jsonl.test.d.ts +2 -0
  65. package/dist/action/cli/output/jsonl.test.d.ts.map +1 -0
  66. package/dist/action/cli/output/reporter.d.ts +108 -0
  67. package/dist/action/cli/output/reporter.d.ts.map +1 -0
  68. package/dist/action/cli/output/tasks.d.ts +89 -0
  69. package/dist/action/cli/output/tasks.d.ts.map +1 -0
  70. package/dist/action/cli/output/tty.d.ts +21 -0
  71. package/dist/action/cli/output/tty.d.ts.map +1 -0
  72. package/dist/action/cli/output/tty.test.d.ts +2 -0
  73. package/dist/action/cli/output/tty.test.d.ts.map +1 -0
  74. package/dist/action/cli/output/verbosity.d.ts +20 -0
  75. package/dist/action/cli/output/verbosity.d.ts.map +1 -0
  76. package/dist/action/cli/output/verbosity.test.d.ts +2 -0
  77. package/dist/action/cli/output/verbosity.test.d.ts.map +1 -0
  78. package/dist/action/cli/terminal.d.ts +19 -0
  79. package/dist/action/cli/terminal.d.ts.map +1 -0
  80. package/dist/action/cli/terminal.test.d.ts +2 -0
  81. package/dist/action/cli/terminal.test.d.ts.map +1 -0
  82. package/dist/action/config/index.d.ts +4 -0
  83. package/dist/action/config/index.d.ts.map +1 -0
  84. package/dist/action/config/loader.d.ts +27 -0
  85. package/dist/action/config/loader.d.ts.map +1 -0
  86. package/dist/action/config/loader.test.d.ts +2 -0
  87. package/dist/action/config/loader.test.d.ts.map +1 -0
  88. package/dist/action/config/schema.d.ts +318 -0
  89. package/dist/action/config/schema.d.ts.map +1 -0
  90. package/dist/action/config/writer.d.ts +11 -0
  91. package/dist/action/config/writer.d.ts.map +1 -0
  92. package/dist/action/config/writer.test.d.ts +2 -0
  93. package/dist/action/config/writer.test.d.ts.map +1 -0
  94. package/dist/action/diff/classify.d.ts +29 -0
  95. package/dist/action/diff/classify.d.ts.map +1 -0
  96. package/dist/action/diff/classify.test.d.ts +2 -0
  97. package/dist/action/diff/classify.test.d.ts.map +1 -0
  98. package/dist/action/diff/coalesce.d.ts +42 -0
  99. package/dist/action/diff/coalesce.d.ts.map +1 -0
  100. package/dist/action/diff/coalesce.test.d.ts +2 -0
  101. package/dist/action/diff/coalesce.test.d.ts.map +1 -0
  102. package/dist/action/diff/context.d.ts +30 -0
  103. package/dist/action/diff/context.d.ts.map +1 -0
  104. package/dist/action/diff/context.test.d.ts +2 -0
  105. package/dist/action/diff/context.test.d.ts.map +1 -0
  106. package/dist/action/diff/index.d.ts +5 -0
  107. package/dist/action/diff/index.d.ts.map +1 -0
  108. package/dist/action/diff/parser.d.ts +52 -0
  109. package/dist/action/diff/parser.d.ts.map +1 -0
  110. package/dist/action/diff/parser.test.d.ts +2 -0
  111. package/dist/action/diff/parser.test.d.ts.map +1 -0
  112. package/dist/action/event/context.d.ts +9 -0
  113. package/dist/action/event/context.d.ts.map +1 -0
  114. package/dist/action/event/index.d.ts +3 -0
  115. package/dist/action/event/index.d.ts.map +1 -0
  116. package/dist/action/event/schedule-context.d.ts +30 -0
  117. package/dist/action/event/schedule-context.d.ts.map +1 -0
  118. package/dist/action/examples/examples.integration.test.d.ts +2 -0
  119. package/dist/action/examples/examples.integration.test.d.ts.map +1 -0
  120. package/dist/action/examples/index.d.ts +50 -0
  121. package/dist/action/examples/index.d.ts.map +1 -0
  122. package/dist/action/examples/index.test.d.ts +2 -0
  123. package/dist/action/examples/index.test.d.ts.map +1 -0
  124. package/dist/action/examples/setup.d.ts +2 -0
  125. package/dist/action/examples/setup.d.ts.map +1 -0
  126. package/dist/action/index.d.ts +11 -0
  127. package/dist/action/index.d.ts.map +1 -0
  128. package/dist/action/index.js +38231 -0
  129. package/dist/action/index.js.map +1 -0
  130. package/dist/action/licenses.txt +992 -0
  131. package/dist/action/main.d.ts +2 -0
  132. package/dist/action/main.d.ts.map +1 -0
  133. package/dist/action/main.js +707 -0
  134. package/dist/action/main.js.map +1 -0
  135. package/dist/action/output/dedup.d.ts +153 -0
  136. package/dist/action/output/dedup.d.ts.map +1 -0
  137. package/dist/action/output/dedup.test.d.ts +2 -0
  138. package/dist/action/output/dedup.test.d.ts.map +1 -0
  139. package/dist/action/output/github-checks.d.ts +106 -0
  140. package/dist/action/output/github-checks.d.ts.map +1 -0
  141. package/dist/action/output/github-checks.test.d.ts +2 -0
  142. package/dist/action/output/github-checks.test.d.ts.map +1 -0
  143. package/dist/action/output/github-issues.d.ts +35 -0
  144. package/dist/action/output/github-issues.d.ts.map +1 -0
  145. package/dist/action/output/index.d.ts +6 -0
  146. package/dist/action/output/index.d.ts.map +1 -0
  147. package/dist/action/output/issue-renderer.d.ts +20 -0
  148. package/dist/action/output/issue-renderer.d.ts.map +1 -0
  149. package/dist/action/output/renderer.d.ts +4 -0
  150. package/dist/action/output/renderer.d.ts.map +1 -0
  151. package/dist/action/output/renderer.test.d.ts +2 -0
  152. package/dist/action/output/renderer.test.d.ts.map +1 -0
  153. package/dist/action/output/stale.d.ts +31 -0
  154. package/dist/action/output/stale.d.ts.map +1 -0
  155. package/dist/action/output/stale.test.d.ts +2 -0
  156. package/dist/action/output/stale.test.d.ts.map +1 -0
  157. package/dist/action/output/types.d.ts +31 -0
  158. package/dist/action/output/types.d.ts.map +1 -0
  159. package/dist/action/package.json +3 -0
  160. package/dist/action/sdk/index.d.ts +2 -0
  161. package/dist/action/sdk/index.d.ts.map +1 -0
  162. package/dist/action/sdk/runner.d.ts +202 -0
  163. package/dist/action/sdk/runner.d.ts.map +1 -0
  164. package/dist/action/sdk/runner.test.d.ts +2 -0
  165. package/dist/action/sdk/runner.test.d.ts.map +1 -0
  166. package/dist/action/skills/index.d.ts +5 -0
  167. package/dist/action/skills/index.d.ts.map +1 -0
  168. package/dist/action/skills/loader.d.ts +111 -0
  169. package/dist/action/skills/loader.d.ts.map +1 -0
  170. package/dist/action/skills/loader.test.d.ts +2 -0
  171. package/dist/action/skills/loader.test.d.ts.map +1 -0
  172. package/dist/action/skills/remote.d.ts +117 -0
  173. package/dist/action/skills/remote.d.ts.map +1 -0
  174. package/dist/action/skills/remote.test.d.ts +2 -0
  175. package/dist/action/skills/remote.test.d.ts.map +1 -0
  176. package/dist/action/sourcemap-register.cjs +1 -0
  177. package/dist/action/triggers/matcher.d.ts +30 -0
  178. package/dist/action/triggers/matcher.d.ts.map +1 -0
  179. package/dist/action/triggers/matcher.test.d.ts +2 -0
  180. package/dist/action/triggers/matcher.test.d.ts.map +1 -0
  181. package/dist/action/types/index.d.ts +269 -0
  182. package/dist/action/types/index.d.ts.map +1 -0
  183. package/dist/action/utils/async.d.ts +5 -0
  184. package/dist/action/utils/async.d.ts.map +1 -0
  185. package/dist/action/utils/index.d.ts +16 -0
  186. package/dist/action/utils/index.d.ts.map +1 -0
  187. package/dist/action/utils/index.test.d.ts +2 -0
  188. package/dist/action/utils/index.test.d.ts.map +1 -0
  189. package/dist/action/utils/version.d.ts +3 -0
  190. package/dist/action/utils/version.d.ts.map +1 -0
  191. package/dist/cli/args.d.ts +74 -0
  192. package/dist/cli/args.d.ts.map +1 -0
  193. package/dist/cli/args.js +359 -0
  194. package/dist/cli/args.js.map +1 -0
  195. package/dist/cli/args.test.d.ts +2 -0
  196. package/dist/cli/args.test.d.ts.map +1 -0
  197. package/dist/cli/args.test.js +392 -0
  198. package/dist/cli/args.test.js.map +1 -0
  199. package/dist/cli/commands/add.d.ts +7 -0
  200. package/dist/cli/commands/add.d.ts.map +1 -0
  201. package/dist/cli/commands/add.js +380 -0
  202. package/dist/cli/commands/add.js.map +1 -0
  203. package/dist/cli/commands/init.d.ts +10 -0
  204. package/dist/cli/commands/init.d.ts.map +1 -0
  205. package/dist/cli/commands/init.js +113 -0
  206. package/dist/cli/commands/init.js.map +1 -0
  207. package/dist/cli/commands/init.test.d.ts +2 -0
  208. package/dist/cli/commands/init.test.d.ts.map +1 -0
  209. package/dist/cli/commands/init.test.js +117 -0
  210. package/dist/cli/commands/init.test.js.map +1 -0
  211. package/dist/cli/commands/setup-app/browser.d.ts +9 -0
  212. package/dist/cli/commands/setup-app/browser.d.ts.map +1 -0
  213. package/dist/cli/commands/setup-app/browser.js +36 -0
  214. package/dist/cli/commands/setup-app/browser.js.map +1 -0
  215. package/dist/cli/commands/setup-app/credentials.d.ts +15 -0
  216. package/dist/cli/commands/setup-app/credentials.d.ts.map +1 -0
  217. package/dist/cli/commands/setup-app/credentials.js +29 -0
  218. package/dist/cli/commands/setup-app/credentials.js.map +1 -0
  219. package/dist/cli/commands/setup-app/manifest.d.ts +24 -0
  220. package/dist/cli/commands/setup-app/manifest.d.ts.map +1 -0
  221. package/dist/cli/commands/setup-app/manifest.js +29 -0
  222. package/dist/cli/commands/setup-app/manifest.js.map +1 -0
  223. package/dist/cli/commands/setup-app/server.d.ts +28 -0
  224. package/dist/cli/commands/setup-app/server.d.ts.map +1 -0
  225. package/dist/cli/commands/setup-app/server.js +136 -0
  226. package/dist/cli/commands/setup-app/server.js.map +1 -0
  227. package/dist/cli/commands/setup-app.d.ts +11 -0
  228. package/dist/cli/commands/setup-app.d.ts.map +1 -0
  229. package/dist/cli/commands/setup-app.js +139 -0
  230. package/dist/cli/commands/setup-app.js.map +1 -0
  231. package/dist/cli/commands/sync.d.ts +9 -0
  232. package/dist/cli/commands/sync.d.ts.map +1 -0
  233. package/dist/cli/commands/sync.js +96 -0
  234. package/dist/cli/commands/sync.js.map +1 -0
  235. package/dist/cli/context.d.ts +27 -0
  236. package/dist/cli/context.d.ts.map +1 -0
  237. package/dist/cli/context.js +101 -0
  238. package/dist/cli/context.js.map +1 -0
  239. package/dist/cli/files.d.ts +22 -0
  240. package/dist/cli/files.d.ts.map +1 -0
  241. package/dist/cli/files.js +66 -0
  242. package/dist/cli/files.js.map +1 -0
  243. package/dist/cli/files.test.d.ts +2 -0
  244. package/dist/cli/files.test.d.ts.map +1 -0
  245. package/dist/cli/files.test.js +117 -0
  246. package/dist/cli/files.test.js.map +1 -0
  247. package/dist/cli/fix.d.ts +41 -0
  248. package/dist/cli/fix.d.ts.map +1 -0
  249. package/dist/cli/fix.js +320 -0
  250. package/dist/cli/fix.js.map +1 -0
  251. package/dist/cli/fix.test.d.ts +2 -0
  252. package/dist/cli/fix.test.d.ts.map +1 -0
  253. package/dist/cli/fix.test.js +251 -0
  254. package/dist/cli/fix.test.js.map +1 -0
  255. package/dist/cli/git.d.ts +73 -0
  256. package/dist/cli/git.d.ts.map +1 -0
  257. package/dist/cli/git.js +267 -0
  258. package/dist/cli/git.js.map +1 -0
  259. package/dist/cli/git.test.d.ts +2 -0
  260. package/dist/cli/git.test.d.ts.map +1 -0
  261. package/dist/cli/git.test.js +96 -0
  262. package/dist/cli/git.test.js.map +1 -0
  263. package/dist/cli/index.d.ts +3 -0
  264. package/dist/cli/index.d.ts.map +1 -0
  265. package/dist/cli/index.js +13 -0
  266. package/dist/cli/index.js.map +1 -0
  267. package/dist/cli/main.d.ts +7 -0
  268. package/dist/cli/main.d.ts.map +1 -0
  269. package/dist/cli/main.js +560 -0
  270. package/dist/cli/main.js.map +1 -0
  271. package/dist/cli/output/box.d.ts +75 -0
  272. package/dist/cli/output/box.d.ts.map +1 -0
  273. package/dist/cli/output/box.js +191 -0
  274. package/dist/cli/output/box.js.map +1 -0
  275. package/dist/cli/output/formatters.d.ts +90 -0
  276. package/dist/cli/output/formatters.d.ts.map +1 -0
  277. package/dist/cli/output/formatters.js +248 -0
  278. package/dist/cli/output/formatters.js.map +1 -0
  279. package/dist/cli/output/formatters.test.d.ts +2 -0
  280. package/dist/cli/output/formatters.test.d.ts.map +1 -0
  281. package/dist/cli/output/formatters.test.js +152 -0
  282. package/dist/cli/output/formatters.test.js.map +1 -0
  283. package/dist/cli/output/icons.d.ts +11 -0
  284. package/dist/cli/output/icons.d.ts.map +1 -0
  285. package/dist/cli/output/icons.js +11 -0
  286. package/dist/cli/output/icons.js.map +1 -0
  287. package/dist/cli/output/index.d.ts +10 -0
  288. package/dist/cli/output/index.d.ts.map +1 -0
  289. package/dist/cli/output/index.js +10 -0
  290. package/dist/cli/output/index.js.map +1 -0
  291. package/dist/cli/output/ink-runner.d.ts +9 -0
  292. package/dist/cli/output/ink-runner.d.ts.map +1 -0
  293. package/dist/cli/output/ink-runner.js +207 -0
  294. package/dist/cli/output/ink-runner.js.map +1 -0
  295. package/dist/cli/output/jsonl.d.ts +43 -0
  296. package/dist/cli/output/jsonl.d.ts.map +1 -0
  297. package/dist/cli/output/jsonl.js +89 -0
  298. package/dist/cli/output/jsonl.js.map +1 -0
  299. package/dist/cli/output/jsonl.test.d.ts +2 -0
  300. package/dist/cli/output/jsonl.test.d.ts.map +1 -0
  301. package/dist/cli/output/jsonl.test.js +284 -0
  302. package/dist/cli/output/jsonl.test.js.map +1 -0
  303. package/dist/cli/output/reporter.d.ts +108 -0
  304. package/dist/cli/output/reporter.d.ts.map +1 -0
  305. package/dist/cli/output/reporter.js +378 -0
  306. package/dist/cli/output/reporter.js.map +1 -0
  307. package/dist/cli/output/tasks.d.ts +89 -0
  308. package/dist/cli/output/tasks.d.ts.map +1 -0
  309. package/dist/cli/output/tasks.js +251 -0
  310. package/dist/cli/output/tasks.js.map +1 -0
  311. package/dist/cli/output/tty.d.ts +21 -0
  312. package/dist/cli/output/tty.d.ts.map +1 -0
  313. package/dist/cli/output/tty.js +44 -0
  314. package/dist/cli/output/tty.js.map +1 -0
  315. package/dist/cli/output/tty.test.d.ts +2 -0
  316. package/dist/cli/output/tty.test.d.ts.map +1 -0
  317. package/dist/cli/output/tty.test.js +105 -0
  318. package/dist/cli/output/tty.test.js.map +1 -0
  319. package/dist/cli/output/verbosity.d.ts +20 -0
  320. package/dist/cli/output/verbosity.d.ts.map +1 -0
  321. package/dist/cli/output/verbosity.js +32 -0
  322. package/dist/cli/output/verbosity.js.map +1 -0
  323. package/dist/cli/output/verbosity.test.d.ts +2 -0
  324. package/dist/cli/output/verbosity.test.d.ts.map +1 -0
  325. package/dist/cli/output/verbosity.test.js +35 -0
  326. package/dist/cli/output/verbosity.test.js.map +1 -0
  327. package/dist/cli/terminal.d.ts +19 -0
  328. package/dist/cli/terminal.d.ts.map +1 -0
  329. package/dist/cli/terminal.js +247 -0
  330. package/dist/cli/terminal.js.map +1 -0
  331. package/dist/cli/terminal.test.d.ts +2 -0
  332. package/dist/cli/terminal.test.d.ts.map +1 -0
  333. package/dist/cli/terminal.test.js +123 -0
  334. package/dist/cli/terminal.test.js.map +1 -0
  335. package/dist/config/index.d.ts +4 -0
  336. package/dist/config/index.d.ts.map +1 -0
  337. package/dist/config/index.js +4 -0
  338. package/dist/config/index.js.map +1 -0
  339. package/dist/config/loader.d.ts +27 -0
  340. package/dist/config/loader.d.ts.map +1 -0
  341. package/dist/config/loader.js +77 -0
  342. package/dist/config/loader.js.map +1 -0
  343. package/dist/config/loader.test.d.ts +2 -0
  344. package/dist/config/loader.test.d.ts.map +1 -0
  345. package/dist/config/loader.test.js +263 -0
  346. package/dist/config/loader.test.js.map +1 -0
  347. package/dist/config/schema.d.ts +318 -0
  348. package/dist/config/schema.d.ts.map +1 -0
  349. package/dist/config/schema.js +137 -0
  350. package/dist/config/schema.js.map +1 -0
  351. package/dist/config/writer.d.ts +11 -0
  352. package/dist/config/writer.d.ts.map +1 -0
  353. package/dist/config/writer.js +74 -0
  354. package/dist/config/writer.js.map +1 -0
  355. package/dist/config/writer.test.d.ts +2 -0
  356. package/dist/config/writer.test.d.ts.map +1 -0
  357. package/dist/config/writer.test.js +98 -0
  358. package/dist/config/writer.test.js.map +1 -0
  359. package/dist/diff/classify.d.ts +29 -0
  360. package/dist/diff/classify.d.ts.map +1 -0
  361. package/dist/diff/classify.js +74 -0
  362. package/dist/diff/classify.js.map +1 -0
  363. package/dist/diff/classify.test.d.ts +2 -0
  364. package/dist/diff/classify.test.d.ts.map +1 -0
  365. package/dist/diff/classify.test.js +140 -0
  366. package/dist/diff/classify.test.js.map +1 -0
  367. package/dist/diff/coalesce.d.ts +42 -0
  368. package/dist/diff/coalesce.d.ts.map +1 -0
  369. package/dist/diff/coalesce.js +104 -0
  370. package/dist/diff/coalesce.js.map +1 -0
  371. package/dist/diff/coalesce.test.d.ts +2 -0
  372. package/dist/diff/coalesce.test.d.ts.map +1 -0
  373. package/dist/diff/coalesce.test.js +159 -0
  374. package/dist/diff/coalesce.test.js.map +1 -0
  375. package/dist/diff/context.d.ts +30 -0
  376. package/dist/diff/context.d.ts.map +1 -0
  377. package/dist/diff/context.js +144 -0
  378. package/dist/diff/context.js.map +1 -0
  379. package/dist/diff/context.test.d.ts +2 -0
  380. package/dist/diff/context.test.d.ts.map +1 -0
  381. package/dist/diff/context.test.js +190 -0
  382. package/dist/diff/context.test.js.map +1 -0
  383. package/dist/diff/index.d.ts +5 -0
  384. package/dist/diff/index.d.ts.map +1 -0
  385. package/dist/diff/index.js +5 -0
  386. package/dist/diff/index.js.map +1 -0
  387. package/dist/diff/parser.d.ts +52 -0
  388. package/dist/diff/parser.d.ts.map +1 -0
  389. package/dist/diff/parser.js +95 -0
  390. package/dist/diff/parser.js.map +1 -0
  391. package/dist/diff/parser.test.d.ts +2 -0
  392. package/dist/diff/parser.test.d.ts.map +1 -0
  393. package/dist/diff/parser.test.js +178 -0
  394. package/dist/diff/parser.test.js.map +1 -0
  395. package/dist/event/context.d.ts +9 -0
  396. package/dist/event/context.d.ts.map +1 -0
  397. package/dist/event/context.js +94 -0
  398. package/dist/event/context.js.map +1 -0
  399. package/dist/event/index.d.ts +3 -0
  400. package/dist/event/index.d.ts.map +1 -0
  401. package/dist/event/index.js +3 -0
  402. package/dist/event/index.js.map +1 -0
  403. package/dist/event/schedule-context.d.ts +30 -0
  404. package/dist/event/schedule-context.d.ts.map +1 -0
  405. package/dist/event/schedule-context.js +57 -0
  406. package/dist/event/schedule-context.js.map +1 -0
  407. package/dist/examples/examples.integration.test.d.ts +2 -0
  408. package/dist/examples/examples.integration.test.d.ts.map +1 -0
  409. package/dist/examples/examples.integration.test.js +55 -0
  410. package/dist/examples/examples.integration.test.js.map +1 -0
  411. package/dist/examples/index.d.ts +50 -0
  412. package/dist/examples/index.d.ts.map +1 -0
  413. package/dist/examples/index.js +104 -0
  414. package/dist/examples/index.js.map +1 -0
  415. package/dist/examples/index.test.d.ts +2 -0
  416. package/dist/examples/index.test.d.ts.map +1 -0
  417. package/dist/examples/index.test.js +88 -0
  418. package/dist/examples/index.test.js.map +1 -0
  419. package/dist/examples/setup.d.ts +2 -0
  420. package/dist/examples/setup.d.ts.map +1 -0
  421. package/dist/examples/setup.js +22 -0
  422. package/dist/examples/setup.js.map +1 -0
  423. package/dist/index.d.ts +12 -0
  424. package/dist/index.d.ts.map +1 -0
  425. package/dist/index.js +57 -0
  426. package/dist/index.js.map +1 -0
  427. package/dist/output/dedup.d.ts +153 -0
  428. package/dist/output/dedup.d.ts.map +1 -0
  429. package/dist/output/dedup.js +416 -0
  430. package/dist/output/dedup.js.map +1 -0
  431. package/dist/output/dedup.test.d.ts +2 -0
  432. package/dist/output/dedup.test.d.ts.map +1 -0
  433. package/dist/output/dedup.test.js +357 -0
  434. package/dist/output/dedup.test.js.map +1 -0
  435. package/dist/output/github-checks.d.ts +106 -0
  436. package/dist/output/github-checks.d.ts.map +1 -0
  437. package/dist/output/github-checks.js +321 -0
  438. package/dist/output/github-checks.js.map +1 -0
  439. package/dist/output/github-checks.test.d.ts +2 -0
  440. package/dist/output/github-checks.test.d.ts.map +1 -0
  441. package/dist/output/github-checks.test.js +255 -0
  442. package/dist/output/github-checks.test.js.map +1 -0
  443. package/dist/output/github-issues.d.ts +35 -0
  444. package/dist/output/github-issues.d.ts.map +1 -0
  445. package/dist/output/github-issues.js +246 -0
  446. package/dist/output/github-issues.js.map +1 -0
  447. package/dist/output/index.d.ts +6 -0
  448. package/dist/output/index.d.ts.map +1 -0
  449. package/dist/output/index.js +6 -0
  450. package/dist/output/index.js.map +1 -0
  451. package/dist/output/issue-renderer.d.ts +20 -0
  452. package/dist/output/issue-renderer.d.ts.map +1 -0
  453. package/dist/output/issue-renderer.js +154 -0
  454. package/dist/output/issue-renderer.js.map +1 -0
  455. package/dist/output/renderer.d.ts +4 -0
  456. package/dist/output/renderer.d.ts.map +1 -0
  457. package/dist/output/renderer.js +168 -0
  458. package/dist/output/renderer.js.map +1 -0
  459. package/dist/output/renderer.test.d.ts +2 -0
  460. package/dist/output/renderer.test.d.ts.map +1 -0
  461. package/dist/output/renderer.test.js +645 -0
  462. package/dist/output/renderer.test.js.map +1 -0
  463. package/dist/output/stale.d.ts +31 -0
  464. package/dist/output/stale.d.ts.map +1 -0
  465. package/dist/output/stale.js +114 -0
  466. package/dist/output/stale.js.map +1 -0
  467. package/dist/output/stale.test.d.ts +2 -0
  468. package/dist/output/stale.test.d.ts.map +1 -0
  469. package/dist/output/stale.test.js +330 -0
  470. package/dist/output/stale.test.js.map +1 -0
  471. package/dist/output/types.d.ts +31 -0
  472. package/dist/output/types.d.ts.map +1 -0
  473. package/dist/output/types.js +2 -0
  474. package/dist/output/types.js.map +1 -0
  475. package/dist/sdk/index.d.ts +2 -0
  476. package/dist/sdk/index.d.ts.map +1 -0
  477. package/dist/sdk/index.js +2 -0
  478. package/dist/sdk/index.js.map +1 -0
  479. package/dist/sdk/runner.d.ts +202 -0
  480. package/dist/sdk/runner.d.ts.map +1 -0
  481. package/dist/sdk/runner.js +888 -0
  482. package/dist/sdk/runner.js.map +1 -0
  483. package/dist/sdk/runner.test.d.ts +2 -0
  484. package/dist/sdk/runner.test.d.ts.map +1 -0
  485. package/dist/sdk/runner.test.js +677 -0
  486. package/dist/sdk/runner.test.js.map +1 -0
  487. package/dist/skills/index.d.ts +5 -0
  488. package/dist/skills/index.d.ts.map +1 -0
  489. package/dist/skills/index.js +3 -0
  490. package/dist/skills/index.js.map +1 -0
  491. package/dist/skills/loader.d.ts +111 -0
  492. package/dist/skills/loader.d.ts.map +1 -0
  493. package/dist/skills/loader.js +319 -0
  494. package/dist/skills/loader.js.map +1 -0
  495. package/dist/skills/loader.test.d.ts +2 -0
  496. package/dist/skills/loader.test.d.ts.map +1 -0
  497. package/dist/skills/loader.test.js +241 -0
  498. package/dist/skills/loader.test.js.map +1 -0
  499. package/dist/skills/remote.d.ts +117 -0
  500. package/dist/skills/remote.d.ts.map +1 -0
  501. package/dist/skills/remote.js +496 -0
  502. package/dist/skills/remote.js.map +1 -0
  503. package/dist/skills/remote.test.d.ts +2 -0
  504. package/dist/skills/remote.test.d.ts.map +1 -0
  505. package/dist/skills/remote.test.js +582 -0
  506. package/dist/skills/remote.test.js.map +1 -0
  507. package/dist/triggers/matcher.d.ts +30 -0
  508. package/dist/triggers/matcher.d.ts.map +1 -0
  509. package/dist/triggers/matcher.js +122 -0
  510. package/dist/triggers/matcher.js.map +1 -0
  511. package/dist/triggers/matcher.test.d.ts +2 -0
  512. package/dist/triggers/matcher.test.d.ts.map +1 -0
  513. package/dist/triggers/matcher.test.js +234 -0
  514. package/dist/triggers/matcher.test.js.map +1 -0
  515. package/dist/types/index.d.ts +269 -0
  516. package/dist/types/index.d.ts.map +1 -0
  517. package/dist/types/index.js +162 -0
  518. package/dist/types/index.js.map +1 -0
  519. package/dist/utils/async.d.ts +5 -0
  520. package/dist/utils/async.d.ts.map +1 -0
  521. package/dist/utils/async.js +13 -0
  522. package/dist/utils/async.js.map +1 -0
  523. package/dist/utils/index.d.ts +16 -0
  524. package/dist/utils/index.d.ts.map +1 -0
  525. package/dist/utils/index.js +44 -0
  526. package/dist/utils/index.js.map +1 -0
  527. package/dist/utils/index.test.d.ts +2 -0
  528. package/dist/utils/index.test.d.ts.map +1 -0
  529. package/dist/utils/index.test.js +68 -0
  530. package/dist/utils/index.test.js.map +1 -0
  531. package/dist/utils/version.d.ts +3 -0
  532. package/dist/utils/version.d.ts.map +1 -0
  533. package/dist/utils/version.js +16 -0
  534. package/dist/utils/version.js.map +1 -0
  535. package/docs/src/pages/config.astro +2 -1
  536. package/docs/src/pages/guide.astro +2 -1
  537. package/docs/src/utils/version.ts +6 -0
  538. package/package.json +12 -2
  539. package/src/cli/args.ts +2 -3
  540. package/src/cli/commands/init.test.ts +2 -1
  541. package/src/cli/commands/init.ts +3 -1
  542. package/src/cli/output/reporter.ts +3 -4
  543. package/src/utils/index.ts +1 -0
  544. package/src/utils/version.ts +17 -0
  545. package/.claude/settings.local.json +0 -88
  546. package/docs/.claude/settings.local.json +0 -11
@@ -0,0 +1,496 @@
1
+ import { existsSync, mkdirSync, readFileSync, writeFileSync, rmSync, renameSync, readdirSync, statSync } from 'node:fs';
2
+ import { homedir } from 'node:os';
3
+ import { dirname, join } from 'node:path';
4
+ import { execFileSync } from 'node:child_process';
5
+ import { z } from 'zod';
6
+ import { loadSkillFromMarkdown, SkillLoaderError } from './loader.js';
7
+ /** Default TTL for unpinned remote skills: 24 hours */
8
+ const DEFAULT_TTL_SECONDS = 86400;
9
+ /** Schema for a single remote entry in state.json */
10
+ const RemoteEntrySchema = z.object({
11
+ sha: z.string(),
12
+ fetchedAt: z.string().datetime(),
13
+ });
14
+ /** Schema for the entire state.json file */
15
+ const RemoteStateSchema = z.object({
16
+ remotes: z.record(z.string(), RemoteEntrySchema),
17
+ });
18
+ /** Schema for a plugin in marketplace.json */
19
+ const MarketplacePluginSchema = z.object({
20
+ name: z.string(),
21
+ source: z.string(),
22
+ description: z.string().optional(),
23
+ category: z.string().optional(),
24
+ });
25
+ /** Schema for .claude-plugin/marketplace.json */
26
+ const MarketplaceConfigSchema = z.object({
27
+ $schema: z.string().optional(),
28
+ name: z.string(),
29
+ description: z.string().optional(),
30
+ plugins: z.array(MarketplacePluginSchema),
31
+ });
32
+ /**
33
+ * Normalize a GitHub URL to owner/repo format.
34
+ * Returns null if the input is not a recognized GitHub URL.
35
+ *
36
+ * Supports:
37
+ * - https://github.com/owner/repo
38
+ * - https://github.com/owner/repo.git
39
+ * - git@github.com:owner/repo.git
40
+ */
41
+ function normalizeGitHubUrl(input) {
42
+ // HTTPS URL: https://github.com/owner/repo or https://github.com/owner/repo.git
43
+ const httpsMatch = input.match(/^https?:\/\/github\.com\/([^/]+)\/([^/@]+?)(?:\.git)?$/);
44
+ if (httpsMatch) {
45
+ return `${httpsMatch[1]}/${httpsMatch[2]}`;
46
+ }
47
+ // SSH URL: git@github.com:owner/repo.git
48
+ const sshMatch = input.match(/^git@github\.com:([^/]+)\/([^/@]+?)(?:\.git)?$/);
49
+ if (sshMatch) {
50
+ return `${sshMatch[1]}/${sshMatch[2]}`;
51
+ }
52
+ return null;
53
+ }
54
+ /**
55
+ * Parse a remote reference string into its components.
56
+ * Supports formats:
57
+ * - "owner/repo" or "owner/repo@sha"
58
+ * - "https://github.com/owner/repo" or "https://github.com/owner/repo@sha"
59
+ * - "https://github.com/owner/repo.git" or "https://github.com/owner/repo.git@sha"
60
+ * - "git@github.com:owner/repo.git" or "git@github.com:owner/repo.git@sha"
61
+ */
62
+ export function parseRemoteRef(ref) {
63
+ let inputRef = ref;
64
+ let sha;
65
+ // Extract SHA suffix from the input before URL normalization.
66
+ // The SHA is always at the end, after a @ that follows the repo name.
67
+ // For git@github.com URLs, we need to find the @ after the colon.
68
+ if (ref.startsWith('git@')) {
69
+ const colonIndex = ref.indexOf(':');
70
+ if (colonIndex !== -1) {
71
+ const afterColon = ref.slice(colonIndex + 1);
72
+ const shaAtIndex = afterColon.lastIndexOf('@');
73
+ if (shaAtIndex !== -1) {
74
+ sha = afterColon.slice(shaAtIndex + 1);
75
+ inputRef = ref.slice(0, colonIndex + 1 + shaAtIndex);
76
+ }
77
+ }
78
+ }
79
+ else {
80
+ const lastAtIndex = ref.lastIndexOf('@');
81
+ if (lastAtIndex !== -1) {
82
+ const potentialSha = ref.slice(lastAtIndex + 1);
83
+ // SHA should not contain : or / (those would indicate URL structure)
84
+ if (!potentialSha.includes(':') && !potentialSha.includes('/')) {
85
+ if (!potentialSha) {
86
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (empty SHA after @)`);
87
+ }
88
+ sha = potentialSha;
89
+ inputRef = ref.slice(0, lastAtIndex);
90
+ }
91
+ }
92
+ }
93
+ // Normalize GitHub URLs to owner/repo format
94
+ const repoPath = normalizeGitHubUrl(inputRef) ?? inputRef;
95
+ const slashIndex = repoPath.indexOf('/');
96
+ if (slashIndex === -1) {
97
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (expected owner/repo format)`);
98
+ }
99
+ const owner = repoPath.slice(0, slashIndex);
100
+ const repo = repoPath.slice(slashIndex + 1);
101
+ if (!owner || !repo) {
102
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (empty owner or repo)`);
103
+ }
104
+ if (repo.includes('/')) {
105
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (repo name cannot contain /)`);
106
+ }
107
+ // Security: Prevent git flag injection by rejecting values starting with '-'
108
+ if (owner.startsWith('-')) {
109
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (owner cannot start with -)`);
110
+ }
111
+ if (repo.startsWith('-')) {
112
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (repo cannot start with -)`);
113
+ }
114
+ if (sha?.startsWith('-')) {
115
+ throw new SkillLoaderError(`Invalid remote ref: ${ref} (SHA cannot start with -)`);
116
+ }
117
+ return { owner, repo, sha };
118
+ }
119
+ /**
120
+ * Format a parsed remote ref back to string format.
121
+ */
122
+ export function formatRemoteRef(parsed) {
123
+ const base = `${parsed.owner}/${parsed.repo}`;
124
+ return parsed.sha ? `${base}@${parsed.sha}` : base;
125
+ }
126
+ /**
127
+ * Get the base directory for caching remote skills.
128
+ * Respects WARDEN_STATE_DIR environment variable.
129
+ * Default: ~/.local/warden/skills/
130
+ */
131
+ export function getSkillsCacheDir() {
132
+ const stateDir = process.env['WARDEN_STATE_DIR'];
133
+ if (stateDir) {
134
+ return join(stateDir, 'skills');
135
+ }
136
+ return join(homedir(), '.local', 'warden', 'skills');
137
+ }
138
+ /**
139
+ * Get the cache path for a specific remote ref.
140
+ * - Unpinned: ~/.local/warden/skills/owner/repo/
141
+ * - Pinned: ~/.local/warden/skills/owner/repo@sha/
142
+ */
143
+ export function getRemotePath(ref) {
144
+ const parsed = parseRemoteRef(ref);
145
+ const cacheDir = getSkillsCacheDir();
146
+ if (parsed.sha) {
147
+ return join(cacheDir, parsed.owner, `${parsed.repo}@${parsed.sha}`);
148
+ }
149
+ return join(cacheDir, parsed.owner, parsed.repo);
150
+ }
151
+ /**
152
+ * Get the path to the state.json file.
153
+ */
154
+ export function getStatePath() {
155
+ return join(getSkillsCacheDir(), 'state.json');
156
+ }
157
+ /**
158
+ * Load the remote state from state.json.
159
+ * Returns an empty state if the file doesn't exist.
160
+ */
161
+ export function loadState() {
162
+ const statePath = getStatePath();
163
+ if (!existsSync(statePath)) {
164
+ return { remotes: {} };
165
+ }
166
+ try {
167
+ const content = readFileSync(statePath, 'utf-8');
168
+ const data = JSON.parse(content);
169
+ return RemoteStateSchema.parse(data);
170
+ }
171
+ catch (error) {
172
+ // If state is corrupted, start fresh
173
+ const message = error instanceof Error ? error.message : String(error);
174
+ console.warn(`Warning: Failed to load state.json, starting fresh: ${message}`);
175
+ return { remotes: {} };
176
+ }
177
+ }
178
+ /**
179
+ * Save the remote state to state.json.
180
+ * Uses atomic write (write to temp, then rename).
181
+ */
182
+ export function saveState(state) {
183
+ const statePath = getStatePath();
184
+ const stateDir = dirname(statePath);
185
+ // Ensure directory exists
186
+ if (!existsSync(stateDir)) {
187
+ mkdirSync(stateDir, { recursive: true });
188
+ }
189
+ // Write atomically
190
+ const tempPath = `${statePath}.tmp`;
191
+ writeFileSync(tempPath, JSON.stringify(state, null, 2), 'utf-8');
192
+ // Rename is atomic on most filesystems
193
+ renameSync(tempPath, statePath);
194
+ }
195
+ /**
196
+ * Get the TTL for remote skill cache in seconds.
197
+ * Respects WARDEN_SKILL_CACHE_TTL environment variable.
198
+ */
199
+ export function getCacheTtlSeconds() {
200
+ const envTtl = process.env['WARDEN_SKILL_CACHE_TTL'];
201
+ if (envTtl) {
202
+ const parsed = parseInt(envTtl, 10);
203
+ if (!isNaN(parsed) && parsed > 0) {
204
+ return parsed;
205
+ }
206
+ }
207
+ return DEFAULT_TTL_SECONDS;
208
+ }
209
+ /**
210
+ * Check if an unpinned remote ref needs to be refreshed.
211
+ * Pinned refs (with @sha) never need refresh.
212
+ */
213
+ export function shouldRefresh(ref, state) {
214
+ const parsed = parseRemoteRef(ref);
215
+ // Pinned refs are immutable - never refresh
216
+ if (parsed.sha) {
217
+ return false;
218
+ }
219
+ const entry = state.remotes[ref];
220
+ if (!entry) {
221
+ return true; // Not cached, needs fetch
222
+ }
223
+ const fetchedAt = new Date(entry.fetchedAt).getTime();
224
+ const now = Date.now();
225
+ const ttl = getCacheTtlSeconds() * 1000;
226
+ return now - fetchedAt > ttl;
227
+ }
228
+ /**
229
+ * Execute a git command and return stdout.
230
+ * Uses execFileSync to avoid shell injection vulnerabilities.
231
+ * Throws SkillLoaderError on failure.
232
+ */
233
+ function execGit(args, options) {
234
+ try {
235
+ return execFileSync('git', args, {
236
+ encoding: 'utf-8',
237
+ cwd: options?.cwd,
238
+ stdio: ['pipe', 'pipe', 'pipe'],
239
+ }).trim();
240
+ }
241
+ catch (error) {
242
+ const message = error instanceof Error ? error.message : String(error);
243
+ throw new SkillLoaderError(`Git command failed: git ${args.join(' ')}: ${message}`);
244
+ }
245
+ }
246
+ /**
247
+ * Clone or update a remote repository to the cache.
248
+ * Returns the SHA of the fetched commit.
249
+ */
250
+ export async function fetchRemote(ref, options = {}) {
251
+ const { force = false, offline = false, onProgress } = options;
252
+ const parsed = parseRemoteRef(ref);
253
+ const remotePath = getRemotePath(ref);
254
+ const state = loadState();
255
+ const isPinned = !!parsed.sha;
256
+ const isCached = existsSync(remotePath);
257
+ const needsRefresh = shouldRefresh(ref, state);
258
+ // Check if we have a valid cache (directory exists AND state entry exists)
259
+ const stateEntry = state.remotes[ref];
260
+ const hasValidCache = isCached && !!stateEntry;
261
+ // Handle offline mode
262
+ if (offline) {
263
+ if (hasValidCache) {
264
+ return stateEntry.sha;
265
+ }
266
+ throw new SkillLoaderError(`Remote skill not cached and offline mode enabled: ${ref}`);
267
+ }
268
+ // Pinned + valid cache = use cache (SHA is immutable)
269
+ if (isPinned && hasValidCache && !force && parsed.sha) {
270
+ return parsed.sha;
271
+ }
272
+ // Unpinned + valid cache + fresh = use cache
273
+ if (!isPinned && hasValidCache && !needsRefresh && !force) {
274
+ return stateEntry.sha;
275
+ }
276
+ const repoUrl = `https://github.com/${parsed.owner}/${parsed.repo}.git`;
277
+ // Clone or update
278
+ if (!isCached) {
279
+ onProgress?.(`Cloning ${ref}...`);
280
+ // Ensure parent directory exists
281
+ const parentDir = dirname(remotePath);
282
+ if (!existsSync(parentDir)) {
283
+ mkdirSync(parentDir, { recursive: true });
284
+ }
285
+ // Clone with minimal depth for unpinned refs
286
+ // Note: '--' separates flags from positional args to prevent flag injection
287
+ if (isPinned && parsed.sha) {
288
+ // For pinned refs, we need full history to checkout the specific SHA
289
+ // Use a shallow clone then deepen if needed
290
+ execGit(['clone', '--depth=1', '--', repoUrl, remotePath]);
291
+ try {
292
+ // Try to checkout the pinned SHA
293
+ // Note: 'checkout' without '--' treats arg as ref; with '--' it's a file path
294
+ execGit(['fetch', '--depth=1', 'origin', '--', parsed.sha], { cwd: remotePath });
295
+ execGit(['checkout', parsed.sha], { cwd: remotePath });
296
+ }
297
+ catch {
298
+ // If SHA not found, do a full fetch and retry
299
+ execGit(['fetch', '--unshallow'], { cwd: remotePath });
300
+ execGit(['checkout', parsed.sha], { cwd: remotePath });
301
+ }
302
+ }
303
+ else if (!isPinned) {
304
+ // For unpinned refs, shallow clone of default branch
305
+ execGit(['clone', '--depth=1', '--', repoUrl, remotePath]);
306
+ }
307
+ }
308
+ else {
309
+ // Update existing cache
310
+ onProgress?.(`Updating ${ref}...`);
311
+ if (!isPinned) {
312
+ // For unpinned refs, pull latest
313
+ execGit(['fetch', '--depth=1', 'origin'], { cwd: remotePath });
314
+ execGit(['reset', '--hard', 'origin/HEAD'], { cwd: remotePath });
315
+ }
316
+ // Pinned refs don't need updates - SHA is immutable
317
+ }
318
+ // Get the current HEAD SHA
319
+ const sha = execGit(['rev-parse', 'HEAD'], { cwd: remotePath });
320
+ // Update state
321
+ state.remotes[ref] = {
322
+ sha,
323
+ fetchedAt: new Date().toISOString(),
324
+ };
325
+ saveState(state);
326
+ return sha;
327
+ }
328
+ /**
329
+ * Parse marketplace.json from a remote repository if it exists.
330
+ * Returns null if the file doesn't exist or is invalid.
331
+ */
332
+ function parseMarketplaceConfig(remotePath) {
333
+ const marketplacePath = join(remotePath, '.claude-plugin', 'marketplace.json');
334
+ if (!existsSync(marketplacePath)) {
335
+ return null;
336
+ }
337
+ try {
338
+ const content = readFileSync(marketplacePath, 'utf-8');
339
+ const data = JSON.parse(content);
340
+ return MarketplaceConfigSchema.parse(data);
341
+ }
342
+ catch {
343
+ // Invalid or malformed marketplace.json - fall back to traditional discovery
344
+ return null;
345
+ }
346
+ }
347
+ /** Directories to search for skills in remote repositories */
348
+ const REMOTE_SKILL_DIRECTORIES = [
349
+ '', // root level
350
+ 'skills', // skills/ subdirectory
351
+ '.warden/skills', // Warden-specific
352
+ '.agents/skills', // General agent skills
353
+ '.claude/skills', // Claude Code skills
354
+ ];
355
+ /**
356
+ * Discover skills using traditional directory layout.
357
+ * Searches root level, skills/, and conventional skill directories.
358
+ */
359
+ async function discoverTraditionalSkills(remotePath) {
360
+ const skills = [];
361
+ const seenNames = new Set();
362
+ for (const subdir of REMOTE_SKILL_DIRECTORIES) {
363
+ const searchPath = subdir ? join(remotePath, subdir) : remotePath;
364
+ if (!existsSync(searchPath))
365
+ continue;
366
+ const entries = readdirSync(searchPath);
367
+ for (const entry of entries) {
368
+ if (entry.startsWith('.'))
369
+ continue;
370
+ const entryPath = join(searchPath, entry);
371
+ const stat = statSync(entryPath);
372
+ if (stat.isDirectory()) {
373
+ const skillMdPath = join(entryPath, 'SKILL.md');
374
+ if (existsSync(skillMdPath)) {
375
+ try {
376
+ const skill = await loadSkillFromMarkdown(skillMdPath);
377
+ // First occurrence wins (root takes precedence over skills/)
378
+ if (!seenNames.has(skill.name)) {
379
+ seenNames.add(skill.name);
380
+ skills.push({
381
+ name: skill.name,
382
+ description: skill.description,
383
+ path: entryPath,
384
+ });
385
+ }
386
+ }
387
+ catch {
388
+ // Skip invalid skill directories
389
+ }
390
+ }
391
+ }
392
+ }
393
+ }
394
+ return skills;
395
+ }
396
+ /**
397
+ * Discover skills using marketplace format.
398
+ * Searches plugins/{plugin}/skills/ for each plugin defined in marketplace.json.
399
+ */
400
+ async function discoverMarketplaceSkills(remotePath, config) {
401
+ const skills = [];
402
+ const seenNames = new Set();
403
+ for (const plugin of config.plugins) {
404
+ // Resolve plugin source path (e.g., "./plugins/sentry-skills" -> "plugins/sentry-skills")
405
+ const pluginSource = plugin.source.replace(/^\.\//, '');
406
+ const skillsPath = join(remotePath, pluginSource, 'skills');
407
+ if (!existsSync(skillsPath))
408
+ continue;
409
+ const entries = readdirSync(skillsPath);
410
+ for (const entry of entries) {
411
+ if (entry.startsWith('.'))
412
+ continue;
413
+ const entryPath = join(skillsPath, entry);
414
+ const stat = statSync(entryPath);
415
+ if (stat.isDirectory()) {
416
+ const skillMdPath = join(entryPath, 'SKILL.md');
417
+ if (existsSync(skillMdPath)) {
418
+ try {
419
+ const skill = await loadSkillFromMarkdown(skillMdPath);
420
+ // First plugin wins for duplicate skill names
421
+ if (!seenNames.has(skill.name)) {
422
+ seenNames.add(skill.name);
423
+ skills.push({
424
+ name: skill.name,
425
+ description: skill.description,
426
+ path: entryPath,
427
+ pluginName: plugin.name,
428
+ });
429
+ }
430
+ }
431
+ catch {
432
+ // Skip invalid skill directories
433
+ }
434
+ }
435
+ }
436
+ }
437
+ }
438
+ return skills;
439
+ }
440
+ /**
441
+ * Discover all skills in a cached remote repository.
442
+ * Detects format and delegates to appropriate discovery function:
443
+ * - If .claude-plugin/marketplace.json exists, uses marketplace discovery
444
+ * - Otherwise, uses traditional discovery (root, skills/, .warden/skills, etc.)
445
+ */
446
+ export async function discoverRemoteSkills(ref) {
447
+ const remotePath = getRemotePath(ref);
448
+ if (!existsSync(remotePath)) {
449
+ throw new SkillLoaderError(`Remote not cached: ${ref}. Run fetch first.`);
450
+ }
451
+ // Check for marketplace format
452
+ const marketplaceConfig = parseMarketplaceConfig(remotePath);
453
+ if (marketplaceConfig) {
454
+ return discoverMarketplaceSkills(remotePath, marketplaceConfig);
455
+ }
456
+ // Fall back to traditional discovery
457
+ return discoverTraditionalSkills(remotePath);
458
+ }
459
+ /**
460
+ * Resolve a skill from a remote repository.
461
+ * Ensures the remote is fetched/cached, then loads the skill.
462
+ * Matches by skill name (from SKILL.md), not directory name.
463
+ */
464
+ export async function resolveRemoteSkill(ref, skillName, options = {}) {
465
+ await fetchRemote(ref, options);
466
+ const availableSkills = await discoverRemoteSkills(ref);
467
+ const match = availableSkills.find((s) => s.name === skillName);
468
+ if (match) {
469
+ return loadSkillFromMarkdown(join(match.path, 'SKILL.md'));
470
+ }
471
+ if (availableSkills.length === 0) {
472
+ throw new SkillLoaderError(`No skills found in remote: ${ref}`);
473
+ }
474
+ throw new SkillLoaderError(`Skill '${skillName}' not found in remote: ${ref}. Available skills: ${availableSkills.map((s) => s.name).join(', ')}`);
475
+ }
476
+ /**
477
+ * Remove a remote from the cache.
478
+ */
479
+ export function removeRemote(ref) {
480
+ const remotePath = getRemotePath(ref);
481
+ if (existsSync(remotePath)) {
482
+ rmSync(remotePath, { recursive: true, force: true });
483
+ }
484
+ const state = loadState();
485
+ const { [ref]: _removed, ...remainingRemotes } = state.remotes;
486
+ state.remotes = remainingRemotes;
487
+ saveState(state);
488
+ }
489
+ /**
490
+ * List all cached remotes with their metadata.
491
+ */
492
+ export function listCachedRemotes() {
493
+ const state = loadState();
494
+ return Object.entries(state.remotes).map(([ref, entry]) => ({ ref, entry }));
495
+ }
496
+ //# sourceMappingURL=remote.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"remote.js","sourceRoot":"","sources":["../../src/skills/remote.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,SAAS,EAAE,YAAY,EAAE,aAAa,EAAE,MAAM,EAAE,UAAU,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AACxH,OAAO,EAAE,OAAO,EAAE,MAAM,SAAS,CAAC;AAClC,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,qBAA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U,SAAS,0BAA0B,GAAG,uBAAuB,eAAe,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CACvH,CAAC;AACJ,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,YAAY,CAAC,GAAW;IACtC,MAAM,UAAU,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC;IAEtC,IAAI,UAAU,CAAC,UAAU,CAAC,EAAE,CAAC;QAC3B,MAAM,CAAC,UAAU,EAAE,EAAE,SAAS,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;IACvD,CAAC;IAED,MAAM,KAAK,GAAG,SAAS,EAAE,CAAC;IAC1B,MAAM,EAAE,CAAC,GAAG,CAAC,EAAE,QAAQ,EAAE,GAAG,gBAAgB,EAAE,GAAG,KAAK,CAAC,OAAO,CAAC;IAC/D,KAAK,CAAC,OAAO,GAAG,gBAAgB,CAAC;IACjC,SAAS,CAAC,KAAK,CAAC,CAAC;AACnB,CAAC;AAED;;GAEG;AACH,MAAM,UAAU,iBAAiB;IAC/B,MAAM,KAAK,GAAG,SAAS,EAAE,CAAC;IAC1B,OAAO,MAAM,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,EAAE,KAAK,CAAC,EAAE,EAAE,CAAC,CAAC,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC,CAAC;AAC/E,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=remote.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"remote.test.d.ts","sourceRoot":"","sources":["../../src/skills/remote.test.ts"],"names":[],"mappings":""}