@eui/mcp 1.5.0 → 1.5.2

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 (481) hide show
  1. package/dist/main.js +539 -208
  2. package/package.json +9 -6
  3. package/dist/config/__tests__/schema.property.test.d.ts +0 -2
  4. package/dist/config/__tests__/schema.property.test.d.ts.map +0 -1
  5. package/dist/config/__tests__/schema.property.test.js +0 -203
  6. package/dist/config/__tests__/schema.property.test.js.map +0 -1
  7. package/dist/config/__tests__/schema.test.d.ts +0 -2
  8. package/dist/config/__tests__/schema.test.d.ts.map +0 -1
  9. package/dist/config/__tests__/schema.test.js +0 -454
  10. package/dist/config/__tests__/schema.test.js.map +0 -1
  11. package/dist/config/index.d.ts +0 -6
  12. package/dist/config/index.d.ts.map +0 -1
  13. package/dist/config/index.js +0 -6
  14. package/dist/config/index.js.map +0 -1
  15. package/dist/config/loader.d.ts +0 -27
  16. package/dist/config/loader.d.ts.map +0 -1
  17. package/dist/config/loader.js +0 -224
  18. package/dist/config/loader.js.map +0 -1
  19. package/dist/config/schema.d.ts +0 -171
  20. package/dist/config/schema.d.ts.map +0 -1
  21. package/dist/config/schema.js +0 -100
  22. package/dist/config/schema.js.map +0 -1
  23. package/dist/index.d.ts +0 -3
  24. package/dist/index.d.ts.map +0 -1
  25. package/dist/index.js +0 -45
  26. package/dist/index.js.map +0 -1
  27. package/dist/loader/__tests__/cache-manager.property.test.d.ts +0 -2
  28. package/dist/loader/__tests__/cache-manager.property.test.d.ts.map +0 -1
  29. package/dist/loader/__tests__/cache-manager.property.test.js +0 -245
  30. package/dist/loader/__tests__/cache-manager.property.test.js.map +0 -1
  31. package/dist/loader/__tests__/cache-manager.test.d.ts +0 -2
  32. package/dist/loader/__tests__/cache-manager.test.d.ts.map +0 -1
  33. package/dist/loader/__tests__/cache-manager.test.js +0 -256
  34. package/dist/loader/__tests__/cache-manager.test.js.map +0 -1
  35. package/dist/loader/__tests__/documentation-loader.integration.test.d.ts +0 -2
  36. package/dist/loader/__tests__/documentation-loader.integration.test.d.ts.map +0 -1
  37. package/dist/loader/__tests__/documentation-loader.integration.test.js +0 -498
  38. package/dist/loader/__tests__/documentation-loader.integration.test.js.map +0 -1
  39. package/dist/loader/__tests__/documentation-loader.property.test.d.ts +0 -2
  40. package/dist/loader/__tests__/documentation-loader.property.test.d.ts.map +0 -1
  41. package/dist/loader/__tests__/documentation-loader.property.test.js +0 -258
  42. package/dist/loader/__tests__/documentation-loader.property.test.js.map +0 -1
  43. package/dist/loader/__tests__/errors.test.d.ts +0 -2
  44. package/dist/loader/__tests__/errors.test.d.ts.map +0 -1
  45. package/dist/loader/__tests__/errors.test.js +0 -132
  46. package/dist/loader/__tests__/errors.test.js.map +0 -1
  47. package/dist/loader/__tests__/http-client.property.test.d.ts +0 -2
  48. package/dist/loader/__tests__/http-client.property.test.d.ts.map +0 -1
  49. package/dist/loader/__tests__/http-client.property.test.js +0 -288
  50. package/dist/loader/__tests__/http-client.property.test.js.map +0 -1
  51. package/dist/loader/__tests__/http-client.test.d.ts +0 -2
  52. package/dist/loader/__tests__/http-client.test.d.ts.map +0 -1
  53. package/dist/loader/__tests__/http-client.test.js +0 -497
  54. package/dist/loader/__tests__/http-client.test.js.map +0 -1
  55. package/dist/loader/__tests__/local-documentation-source.property.test.d.ts +0 -2
  56. package/dist/loader/__tests__/local-documentation-source.property.test.d.ts.map +0 -1
  57. package/dist/loader/__tests__/local-documentation-source.property.test.js +0 -373
  58. package/dist/loader/__tests__/local-documentation-source.property.test.js.map +0 -1
  59. package/dist/loader/__tests__/local-documentation-source.test.d.ts +0 -2
  60. package/dist/loader/__tests__/local-documentation-source.test.d.ts.map +0 -1
  61. package/dist/loader/__tests__/local-documentation-source.test.js +0 -544
  62. package/dist/loader/__tests__/local-documentation-source.test.js.map +0 -1
  63. package/dist/loader/__tests__/path-type-detector.property.test.d.ts +0 -2
  64. package/dist/loader/__tests__/path-type-detector.property.test.d.ts.map +0 -1
  65. package/dist/loader/__tests__/path-type-detector.property.test.js +0 -245
  66. package/dist/loader/__tests__/path-type-detector.property.test.js.map +0 -1
  67. package/dist/loader/__tests__/path-type-detector.test.d.ts +0 -2
  68. package/dist/loader/__tests__/path-type-detector.test.d.ts.map +0 -1
  69. package/dist/loader/__tests__/path-type-detector.test.js +0 -390
  70. package/dist/loader/__tests__/path-type-detector.test.js.map +0 -1
  71. package/dist/loader/__tests__/remote-documentation-source.property.test.d.ts +0 -2
  72. package/dist/loader/__tests__/remote-documentation-source.property.test.d.ts.map +0 -1
  73. package/dist/loader/__tests__/remote-documentation-source.property.test.js +0 -462
  74. package/dist/loader/__tests__/remote-documentation-source.property.test.js.map +0 -1
  75. package/dist/loader/__tests__/remote-documentation-source.test.d.ts +0 -2
  76. package/dist/loader/__tests__/remote-documentation-source.test.d.ts.map +0 -1
  77. package/dist/loader/__tests__/remote-documentation-source.test.js +0 -707
  78. package/dist/loader/__tests__/remote-documentation-source.test.js.map +0 -1
  79. package/dist/loader/cache-manager.d.ts +0 -74
  80. package/dist/loader/cache-manager.d.ts.map +0 -1
  81. package/dist/loader/cache-manager.js +0 -107
  82. package/dist/loader/cache-manager.js.map +0 -1
  83. package/dist/loader/documentation-loader.d.ts +0 -57
  84. package/dist/loader/documentation-loader.d.ts.map +0 -1
  85. package/dist/loader/documentation-loader.js +0 -81
  86. package/dist/loader/documentation-loader.js.map +0 -1
  87. package/dist/loader/documentation-source.d.ts +0 -37
  88. package/dist/loader/documentation-source.d.ts.map +0 -1
  89. package/dist/loader/documentation-source.js +0 -2
  90. package/dist/loader/documentation-source.js.map +0 -1
  91. package/dist/loader/errors.d.ts +0 -34
  92. package/dist/loader/errors.d.ts.map +0 -1
  93. package/dist/loader/errors.js +0 -65
  94. package/dist/loader/errors.js.map +0 -1
  95. package/dist/loader/http-client.d.ts +0 -43
  96. package/dist/loader/http-client.d.ts.map +0 -1
  97. package/dist/loader/http-client.js +0 -144
  98. package/dist/loader/http-client.js.map +0 -1
  99. package/dist/loader/index.d.ts +0 -6
  100. package/dist/loader/index.d.ts.map +0 -1
  101. package/dist/loader/index.js +0 -5
  102. package/dist/loader/index.js.map +0 -1
  103. package/dist/loader/local-documentation-source.d.ts +0 -62
  104. package/dist/loader/local-documentation-source.d.ts.map +0 -1
  105. package/dist/loader/local-documentation-source.js +0 -190
  106. package/dist/loader/local-documentation-source.js.map +0 -1
  107. package/dist/loader/path-type-detector.d.ts +0 -34
  108. package/dist/loader/path-type-detector.d.ts.map +0 -1
  109. package/dist/loader/path-type-detector.js +0 -78
  110. package/dist/loader/path-type-detector.js.map +0 -1
  111. package/dist/loader/remote-documentation-source.d.ts +0 -108
  112. package/dist/loader/remote-documentation-source.d.ts.map +0 -1
  113. package/dist/loader/remote-documentation-source.js +0 -249
  114. package/dist/loader/remote-documentation-source.js.map +0 -1
  115. package/dist/main.d.ts +0 -3
  116. package/dist/main.d.ts.map +0 -1
  117. package/dist/main.js.map +0 -1
  118. package/dist/mcp/__tests__/server.property.test.d.ts +0 -2
  119. package/dist/mcp/__tests__/server.property.test.d.ts.map +0 -1
  120. package/dist/mcp/__tests__/server.property.test.js +0 -286
  121. package/dist/mcp/__tests__/server.property.test.js.map +0 -1
  122. package/dist/mcp/__tests__/server.test.d.ts +0 -2
  123. package/dist/mcp/__tests__/server.test.d.ts.map +0 -1
  124. package/dist/mcp/__tests__/server.test.js +0 -101
  125. package/dist/mcp/__tests__/server.test.js.map +0 -1
  126. package/dist/mcp/index.d.ts +0 -5
  127. package/dist/mcp/index.d.ts.map +0 -1
  128. package/dist/mcp/index.js +0 -5
  129. package/dist/mcp/index.js.map +0 -1
  130. package/dist/mcp/server.d.ts +0 -65
  131. package/dist/mcp/server.d.ts.map +0 -1
  132. package/dist/mcp/server.js +0 -242
  133. package/dist/mcp/server.js.map +0 -1
  134. package/dist/publish/__tests__/publish-utils.test.d.ts +0 -5
  135. package/dist/publish/__tests__/publish-utils.test.d.ts.map +0 -1
  136. package/dist/publish/__tests__/publish-utils.test.js +0 -189
  137. package/dist/publish/__tests__/publish-utils.test.js.map +0 -1
  138. package/dist/publish/index.d.ts +0 -8
  139. package/dist/publish/index.d.ts.map +0 -1
  140. package/dist/publish/index.js +0 -8
  141. package/dist/publish/index.js.map +0 -1
  142. package/dist/publish/publish-utils.d.ts +0 -74
  143. package/dist/publish/publish-utils.d.ts.map +0 -1
  144. package/dist/publish/publish-utils.js +0 -170
  145. package/dist/publish/publish-utils.js.map +0 -1
  146. package/dist/query/__tests__/deprecation-parser.test.d.ts +0 -2
  147. package/dist/query/__tests__/deprecation-parser.test.d.ts.map +0 -1
  148. package/dist/query/__tests__/deprecation-parser.test.js +0 -154
  149. package/dist/query/__tests__/deprecation-parser.test.js.map +0 -1
  150. package/dist/query/__tests__/deprecation-query.test.d.ts +0 -2
  151. package/dist/query/__tests__/deprecation-query.test.d.ts.map +0 -1
  152. package/dist/query/__tests__/deprecation-query.test.js +0 -199
  153. package/dist/query/__tests__/deprecation-query.test.js.map +0 -1
  154. package/dist/query/__tests__/index-builder-debug.test.d.ts +0 -2
  155. package/dist/query/__tests__/index-builder-debug.test.d.ts.map +0 -1
  156. package/dist/query/__tests__/index-builder-debug.test.js +0 -34
  157. package/dist/query/__tests__/index-builder-debug.test.js.map +0 -1
  158. package/dist/query/__tests__/index-builder.property.test.d.ts +0 -2
  159. package/dist/query/__tests__/index-builder.property.test.d.ts.map +0 -1
  160. package/dist/query/__tests__/index-builder.property.test.js +0 -422
  161. package/dist/query/__tests__/index-builder.property.test.js.map +0 -1
  162. package/dist/query/__tests__/index-builder.test.d.ts +0 -2
  163. package/dist/query/__tests__/index-builder.test.d.ts.map +0 -1
  164. package/dist/query/__tests__/index-builder.test.js +0 -55
  165. package/dist/query/__tests__/index-builder.test.js.map +0 -1
  166. package/dist/query/__tests__/result-formatter-deprecation.test.d.ts +0 -2
  167. package/dist/query/__tests__/result-formatter-deprecation.test.d.ts.map +0 -1
  168. package/dist/query/__tests__/result-formatter-deprecation.test.js +0 -159
  169. package/dist/query/__tests__/result-formatter-deprecation.test.js.map +0 -1
  170. package/dist/query/__tests__/result-formatter.integration.test.d.ts +0 -2
  171. package/dist/query/__tests__/result-formatter.integration.test.d.ts.map +0 -1
  172. package/dist/query/__tests__/result-formatter.integration.test.js +0 -140
  173. package/dist/query/__tests__/result-formatter.integration.test.js.map +0 -1
  174. package/dist/query/__tests__/result-formatter.property.test.d.ts +0 -2
  175. package/dist/query/__tests__/result-formatter.property.test.d.ts.map +0 -1
  176. package/dist/query/__tests__/result-formatter.property.test.js +0 -163
  177. package/dist/query/__tests__/result-formatter.property.test.js.map +0 -1
  178. package/dist/query/__tests__/result-formatter.test.d.ts +0 -2
  179. package/dist/query/__tests__/result-formatter.test.d.ts.map +0 -1
  180. package/dist/query/__tests__/result-formatter.test.js +0 -85
  181. package/dist/query/__tests__/result-formatter.test.js.map +0 -1
  182. package/dist/query/__tests__/search-engine.property.test.d.ts +0 -2
  183. package/dist/query/__tests__/search-engine.property.test.d.ts.map +0 -1
  184. package/dist/query/__tests__/search-engine.property.test.js +0 -389
  185. package/dist/query/__tests__/search-engine.property.test.js.map +0 -1
  186. package/dist/query/component-query.d.ts +0 -33
  187. package/dist/query/component-query.d.ts.map +0 -1
  188. package/dist/query/component-query.js +0 -63
  189. package/dist/query/component-query.js.map +0 -1
  190. package/dist/query/deprecation-parser.d.ts +0 -46
  191. package/dist/query/deprecation-parser.d.ts.map +0 -1
  192. package/dist/query/deprecation-parser.js +0 -81
  193. package/dist/query/deprecation-parser.js.map +0 -1
  194. package/dist/query/deprecation-query.d.ts +0 -19
  195. package/dist/query/deprecation-query.d.ts.map +0 -1
  196. package/dist/query/deprecation-query.js +0 -73
  197. package/dist/query/deprecation-query.js.map +0 -1
  198. package/dist/query/index-builder.d.ts +0 -79
  199. package/dist/query/index-builder.d.ts.map +0 -1
  200. package/dist/query/index-builder.js +0 -217
  201. package/dist/query/index-builder.js.map +0 -1
  202. package/dist/query/index.d.ts +0 -5
  203. package/dist/query/index.d.ts.map +0 -1
  204. package/dist/query/index.js +0 -6
  205. package/dist/query/index.js.map +0 -1
  206. package/dist/query/result-formatter.d.ts +0 -135
  207. package/dist/query/result-formatter.d.ts.map +0 -1
  208. package/dist/query/result-formatter.js +0 -224
  209. package/dist/query/result-formatter.js.map +0 -1
  210. package/dist/query/search-engine.d.ts +0 -54
  211. package/dist/query/search-engine.d.ts.map +0 -1
  212. package/dist/query/search-engine.js +0 -178
  213. package/dist/query/search-engine.js.map +0 -1
  214. package/dist/tools/__tests__/deprecation-tools.test.d.ts +0 -2
  215. package/dist/tools/__tests__/deprecation-tools.test.d.ts.map +0 -1
  216. package/dist/tools/__tests__/deprecation-tools.test.js +0 -178
  217. package/dist/tools/__tests__/deprecation-tools.test.js.map +0 -1
  218. package/dist/tools/__tests__/get-component-docs.property.test.d.ts +0 -2
  219. package/dist/tools/__tests__/get-component-docs.property.test.d.ts.map +0 -1
  220. package/dist/tools/__tests__/get-component-docs.property.test.js +0 -594
  221. package/dist/tools/__tests__/get-component-docs.property.test.js.map +0 -1
  222. package/dist/tools/__tests__/get-component-docs.test.d.ts +0 -2
  223. package/dist/tools/__tests__/get-component-docs.test.d.ts.map +0 -1
  224. package/dist/tools/__tests__/get-component-docs.test.js +0 -137
  225. package/dist/tools/__tests__/get-component-docs.test.js.map +0 -1
  226. package/dist/tools/__tests__/get-component-examples.property.test.d.ts +0 -2
  227. package/dist/tools/__tests__/get-component-examples.property.test.d.ts.map +0 -1
  228. package/dist/tools/__tests__/get-component-examples.property.test.js +0 -245
  229. package/dist/tools/__tests__/get-component-examples.property.test.js.map +0 -1
  230. package/dist/tools/__tests__/get-component-examples.test.d.ts +0 -2
  231. package/dist/tools/__tests__/get-component-examples.test.d.ts.map +0 -1
  232. package/dist/tools/__tests__/get-component-examples.test.js +0 -128
  233. package/dist/tools/__tests__/get-component-examples.test.js.map +0 -1
  234. package/dist/tools/__tests__/get-component-inputs.property.test.d.ts +0 -2
  235. package/dist/tools/__tests__/get-component-inputs.property.test.d.ts.map +0 -1
  236. package/dist/tools/__tests__/get-component-inputs.property.test.js +0 -310
  237. package/dist/tools/__tests__/get-component-inputs.property.test.js.map +0 -1
  238. package/dist/tools/__tests__/get-component-inputs.test.d.ts +0 -2
  239. package/dist/tools/__tests__/get-component-inputs.test.d.ts.map +0 -1
  240. package/dist/tools/__tests__/get-component-inputs.test.js +0 -245
  241. package/dist/tools/__tests__/get-component-inputs.test.js.map +0 -1
  242. package/dist/tools/__tests__/get-component-outputs.property.test.d.ts +0 -2
  243. package/dist/tools/__tests__/get-component-outputs.property.test.d.ts.map +0 -1
  244. package/dist/tools/__tests__/get-component-outputs.property.test.js +0 -227
  245. package/dist/tools/__tests__/get-component-outputs.property.test.js.map +0 -1
  246. package/dist/tools/__tests__/get-component-outputs.test.d.ts +0 -2
  247. package/dist/tools/__tests__/get-component-outputs.test.d.ts.map +0 -1
  248. package/dist/tools/__tests__/get-component-outputs.test.js +0 -189
  249. package/dist/tools/__tests__/get-component-outputs.test.js.map +0 -1
  250. package/dist/tools/__tests__/get-library-version.property.test.d.ts +0 -2
  251. package/dist/tools/__tests__/get-library-version.property.test.d.ts.map +0 -1
  252. package/dist/tools/__tests__/get-library-version.property.test.js +0 -115
  253. package/dist/tools/__tests__/get-library-version.property.test.js.map +0 -1
  254. package/dist/tools/__tests__/get-library-version.test.d.ts +0 -2
  255. package/dist/tools/__tests__/get-library-version.test.d.ts.map +0 -1
  256. package/dist/tools/__tests__/get-library-version.test.js +0 -97
  257. package/dist/tools/__tests__/get-library-version.test.js.map +0 -1
  258. package/dist/tools/__tests__/list-components.property.test.d.ts +0 -2
  259. package/dist/tools/__tests__/list-components.property.test.d.ts.map +0 -1
  260. package/dist/tools/__tests__/list-components.property.test.js +0 -241
  261. package/dist/tools/__tests__/list-components.property.test.js.map +0 -1
  262. package/dist/tools/__tests__/list-components.test.d.ts +0 -2
  263. package/dist/tools/__tests__/list-components.test.d.ts.map +0 -1
  264. package/dist/tools/__tests__/list-components.test.js +0 -170
  265. package/dist/tools/__tests__/list-components.test.js.map +0 -1
  266. package/dist/tools/__tests__/search-components.test.d.ts +0 -2
  267. package/dist/tools/__tests__/search-components.test.d.ts.map +0 -1
  268. package/dist/tools/__tests__/search-components.test.js +0 -239
  269. package/dist/tools/__tests__/search-components.test.js.map +0 -1
  270. package/dist/tools/get-component-docs.d.ts +0 -43
  271. package/dist/tools/get-component-docs.d.ts.map +0 -1
  272. package/dist/tools/get-component-docs.js +0 -55
  273. package/dist/tools/get-component-docs.js.map +0 -1
  274. package/dist/tools/get-component-examples.d.ts +0 -45
  275. package/dist/tools/get-component-examples.d.ts.map +0 -1
  276. package/dist/tools/get-component-examples.js +0 -56
  277. package/dist/tools/get-component-examples.js.map +0 -1
  278. package/dist/tools/get-component-inputs.d.ts +0 -44
  279. package/dist/tools/get-component-inputs.d.ts.map +0 -1
  280. package/dist/tools/get-component-inputs.js +0 -55
  281. package/dist/tools/get-component-inputs.js.map +0 -1
  282. package/dist/tools/get-component-outputs.d.ts +0 -44
  283. package/dist/tools/get-component-outputs.d.ts.map +0 -1
  284. package/dist/tools/get-component-outputs.js +0 -55
  285. package/dist/tools/get-component-outputs.js.map +0 -1
  286. package/dist/tools/get-deprecation-info.d.ts +0 -42
  287. package/dist/tools/get-deprecation-info.d.ts.map +0 -1
  288. package/dist/tools/get-deprecation-info.js +0 -55
  289. package/dist/tools/get-deprecation-info.js.map +0 -1
  290. package/dist/tools/get-eui-cli-guide.d.ts +0 -32
  291. package/dist/tools/get-eui-cli-guide.d.ts.map +0 -1
  292. package/dist/tools/get-eui-cli-guide.js +0 -160
  293. package/dist/tools/get-eui-cli-guide.js.map +0 -1
  294. package/dist/tools/get-eui-cli-instructions.d.ts +0 -32
  295. package/dist/tools/get-eui-cli-instructions.d.ts.map +0 -1
  296. package/dist/tools/get-eui-cli-instructions.js +0 -375
  297. package/dist/tools/get-eui-cli-instructions.js.map +0 -1
  298. package/dist/tools/get-library-version.d.ts +0 -33
  299. package/dist/tools/get-library-version.d.ts.map +0 -1
  300. package/dist/tools/get-library-version.js +0 -62
  301. package/dist/tools/get-library-version.js.map +0 -1
  302. package/dist/tools/index.d.ts +0 -12
  303. package/dist/tools/index.d.ts.map +0 -1
  304. package/dist/tools/index.js +0 -13
  305. package/dist/tools/index.js.map +0 -1
  306. package/dist/tools/list-components.d.ts +0 -69
  307. package/dist/tools/list-components.d.ts.map +0 -1
  308. package/dist/tools/list-components.js +0 -84
  309. package/dist/tools/list-components.js.map +0 -1
  310. package/dist/tools/list-deprecated.d.ts +0 -47
  311. package/dist/tools/list-deprecated.d.ts.map +0 -1
  312. package/dist/tools/list-deprecated.js +0 -56
  313. package/dist/tools/list-deprecated.js.map +0 -1
  314. package/dist/tools/search-components.d.ts +0 -69
  315. package/dist/tools/search-components.d.ts.map +0 -1
  316. package/dist/tools/search-components.js +0 -98
  317. package/dist/tools/search-components.js.map +0 -1
  318. package/dist/types/compodoc.d.ts +0 -262
  319. package/dist/types/compodoc.d.ts.map +0 -1
  320. package/dist/types/compodoc.js +0 -5
  321. package/dist/types/compodoc.js.map +0 -1
  322. package/dist/types/deprecation.d.ts +0 -33
  323. package/dist/types/deprecation.d.ts.map +0 -1
  324. package/dist/types/deprecation.js +0 -5
  325. package/dist/types/deprecation.js.map +0 -1
  326. package/dist/types/index.d.ts +0 -5
  327. package/dist/types/index.d.ts.map +0 -1
  328. package/dist/types/index.js +0 -5
  329. package/dist/types/index.js.map +0 -1
  330. package/dist/utils/__tests__/credential-masking.property.test.d.ts +0 -2
  331. package/dist/utils/__tests__/credential-masking.property.test.d.ts.map +0 -1
  332. package/dist/utils/__tests__/credential-masking.property.test.js +0 -145
  333. package/dist/utils/__tests__/credential-masking.property.test.js.map +0 -1
  334. package/dist/utils/__tests__/credential-masking.test.d.ts +0 -2
  335. package/dist/utils/__tests__/credential-masking.test.d.ts.map +0 -1
  336. package/dist/utils/__tests__/credential-masking.test.js +0 -188
  337. package/dist/utils/__tests__/credential-masking.test.js.map +0 -1
  338. package/dist/utils/__tests__/errors.test.d.ts +0 -2
  339. package/dist/utils/__tests__/errors.test.d.ts.map +0 -1
  340. package/dist/utils/__tests__/errors.test.js +0 -110
  341. package/dist/utils/__tests__/errors.test.js.map +0 -1
  342. package/dist/utils/__tests__/integration.test.d.ts +0 -2
  343. package/dist/utils/__tests__/integration.test.d.ts.map +0 -1
  344. package/dist/utils/__tests__/integration.test.js +0 -142
  345. package/dist/utils/__tests__/integration.test.js.map +0 -1
  346. package/dist/utils/__tests__/logger.test.d.ts +0 -2
  347. package/dist/utils/__tests__/logger.test.d.ts.map +0 -1
  348. package/dist/utils/__tests__/logger.test.js +0 -119
  349. package/dist/utils/__tests__/logger.test.js.map +0 -1
  350. package/dist/utils/__tests__/retry.test.d.ts +0 -2
  351. package/dist/utils/__tests__/retry.test.d.ts.map +0 -1
  352. package/dist/utils/__tests__/retry.test.js +0 -84
  353. package/dist/utils/__tests__/retry.test.js.map +0 -1
  354. package/dist/utils/circuit-breaker.d.ts +0 -91
  355. package/dist/utils/circuit-breaker.d.ts.map +0 -1
  356. package/dist/utils/circuit-breaker.js +0 -186
  357. package/dist/utils/circuit-breaker.js.map +0 -1
  358. package/dist/utils/credential-masking.d.ts +0 -90
  359. package/dist/utils/credential-masking.d.ts.map +0 -1
  360. package/dist/utils/credential-masking.js +0 -202
  361. package/dist/utils/credential-masking.js.map +0 -1
  362. package/dist/utils/error-handler.d.ts +0 -68
  363. package/dist/utils/error-handler.d.ts.map +0 -1
  364. package/dist/utils/error-handler.js +0 -184
  365. package/dist/utils/error-handler.js.map +0 -1
  366. package/dist/utils/errors.d.ts +0 -156
  367. package/dist/utils/errors.d.ts.map +0 -1
  368. package/dist/utils/errors.js +0 -242
  369. package/dist/utils/errors.js.map +0 -1
  370. package/dist/utils/index.d.ts +0 -10
  371. package/dist/utils/index.d.ts.map +0 -1
  372. package/dist/utils/index.js +0 -16
  373. package/dist/utils/index.js.map +0 -1
  374. package/dist/utils/logger.d.ts +0 -76
  375. package/dist/utils/logger.d.ts.map +0 -1
  376. package/dist/utils/logger.js +0 -150
  377. package/dist/utils/logger.js.map +0 -1
  378. package/dist/utils/retry.d.ts +0 -19
  379. package/dist/utils/retry.d.ts.map +0 -1
  380. package/dist/utils/retry.js +0 -81
  381. package/dist/utils/retry.js.map +0 -1
  382. package/dist/version/__tests__/changelog-commit-grouping.property.test.d.ts +0 -2
  383. package/dist/version/__tests__/changelog-commit-grouping.property.test.d.ts.map +0 -1
  384. package/dist/version/__tests__/changelog-commit-grouping.property.test.js +0 -297
  385. package/dist/version/__tests__/changelog-commit-grouping.property.test.js.map +0 -1
  386. package/dist/version/__tests__/changelog-commit-parsing.property.test.d.ts +0 -2
  387. package/dist/version/__tests__/changelog-commit-parsing.property.test.d.ts.map +0 -1
  388. package/dist/version/__tests__/changelog-commit-parsing.property.test.js +0 -396
  389. package/dist/version/__tests__/changelog-commit-parsing.property.test.js.map +0 -1
  390. package/dist/version/__tests__/changelog-file-updates.property.test.d.ts +0 -11
  391. package/dist/version/__tests__/changelog-file-updates.property.test.d.ts.map +0 -1
  392. package/dist/version/__tests__/changelog-file-updates.property.test.js +0 -452
  393. package/dist/version/__tests__/changelog-file-updates.property.test.js.map +0 -1
  394. package/dist/version/__tests__/dry-run-action.property.test.d.ts +0 -8
  395. package/dist/version/__tests__/dry-run-action.property.test.d.ts.map +0 -1
  396. package/dist/version/__tests__/dry-run-action.property.test.js +0 -50
  397. package/dist/version/__tests__/dry-run-action.property.test.js.map +0 -1
  398. package/dist/version/__tests__/dry-run-changelog.property.test.d.ts +0 -8
  399. package/dist/version/__tests__/dry-run-changelog.property.test.d.ts.map +0 -1
  400. package/dist/version/__tests__/dry-run-changelog.property.test.js +0 -53
  401. package/dist/version/__tests__/dry-run-changelog.property.test.js.map +0 -1
  402. package/dist/version/__tests__/dry-run-utils.test.d.ts +0 -7
  403. package/dist/version/__tests__/dry-run-utils.test.d.ts.map +0 -1
  404. package/dist/version/__tests__/dry-run-utils.test.js +0 -205
  405. package/dist/version/__tests__/dry-run-utils.test.js.map +0 -1
  406. package/dist/version/__tests__/dry-run-version.property.test.d.ts +0 -8
  407. package/dist/version/__tests__/dry-run-version.property.test.d.ts.map +0 -1
  408. package/dist/version/__tests__/dry-run-version.property.test.js +0 -59
  409. package/dist/version/__tests__/dry-run-version.property.test.js.map +0 -1
  410. package/dist/version/__tests__/git-tag-annotation.property.test.d.ts +0 -11
  411. package/dist/version/__tests__/git-tag-annotation.property.test.d.ts.map +0 -1
  412. package/dist/version/__tests__/git-tag-annotation.property.test.js +0 -271
  413. package/dist/version/__tests__/git-tag-annotation.property.test.js.map +0 -1
  414. package/dist/version/__tests__/git-tag-format.property.test.d.ts +0 -11
  415. package/dist/version/__tests__/git-tag-format.property.test.d.ts.map +0 -1
  416. package/dist/version/__tests__/git-tag-format.property.test.js +0 -411
  417. package/dist/version/__tests__/git-tag-format.property.test.js.map +0 -1
  418. package/dist/version/__tests__/git-tag-utils.test.d.ts +0 -2
  419. package/dist/version/__tests__/git-tag-utils.test.d.ts.map +0 -1
  420. package/dist/version/__tests__/git-tag-utils.test.js +0 -142
  421. package/dist/version/__tests__/git-tag-utils.test.js.map +0 -1
  422. package/dist/version/__tests__/npm-tag-selection.property.test.d.ts +0 -2
  423. package/dist/version/__tests__/npm-tag-selection.property.test.d.ts.map +0 -1
  424. package/dist/version/__tests__/npm-tag-selection.property.test.js +0 -79
  425. package/dist/version/__tests__/npm-tag-selection.property.test.js.map +0 -1
  426. package/dist/version/__tests__/release-title-format.property.test.d.ts +0 -11
  427. package/dist/version/__tests__/release-title-format.property.test.d.ts.map +0 -1
  428. package/dist/version/__tests__/release-title-format.property.test.js +0 -422
  429. package/dist/version/__tests__/release-title-format.property.test.js.map +0 -1
  430. package/dist/version/__tests__/release-utils.test.d.ts +0 -7
  431. package/dist/version/__tests__/release-utils.test.d.ts.map +0 -1
  432. package/dist/version/__tests__/release-utils.test.js +0 -176
  433. package/dist/version/__tests__/release-utils.test.js.map +0 -1
  434. package/dist/version/__tests__/rollback-changelog.property.test.d.ts +0 -8
  435. package/dist/version/__tests__/rollback-changelog.property.test.d.ts.map +0 -1
  436. package/dist/version/__tests__/rollback-changelog.property.test.js +0 -61
  437. package/dist/version/__tests__/rollback-changelog.property.test.js.map +0 -1
  438. package/dist/version/__tests__/rollback-utils.test.d.ts +0 -7
  439. package/dist/version/__tests__/rollback-utils.test.d.ts.map +0 -1
  440. package/dist/version/__tests__/rollback-utils.test.js +0 -74
  441. package/dist/version/__tests__/rollback-utils.test.js.map +0 -1
  442. package/dist/version/__tests__/version-manager.property.test.d.ts +0 -2
  443. package/dist/version/__tests__/version-manager.property.test.d.ts.map +0 -1
  444. package/dist/version/__tests__/version-manager.property.test.js +0 -143
  445. package/dist/version/__tests__/version-manager.property.test.js.map +0 -1
  446. package/dist/version/__tests__/version-manager.test.d.ts +0 -2
  447. package/dist/version/__tests__/version-manager.test.d.ts.map +0 -1
  448. package/dist/version/__tests__/version-manager.test.js +0 -203
  449. package/dist/version/__tests__/version-manager.test.js.map +0 -1
  450. package/dist/version/changelog-file-utils.d.ts +0 -69
  451. package/dist/version/changelog-file-utils.d.ts.map +0 -1
  452. package/dist/version/changelog-file-utils.js +0 -161
  453. package/dist/version/changelog-file-utils.js.map +0 -1
  454. package/dist/version/changelog-utils.d.ts +0 -98
  455. package/dist/version/changelog-utils.d.ts.map +0 -1
  456. package/dist/version/changelog-utils.js +0 -198
  457. package/dist/version/changelog-utils.js.map +0 -1
  458. package/dist/version/dry-run-utils.d.ts +0 -108
  459. package/dist/version/dry-run-utils.d.ts.map +0 -1
  460. package/dist/version/dry-run-utils.js +0 -126
  461. package/dist/version/dry-run-utils.js.map +0 -1
  462. package/dist/version/git-tag-utils.d.ts +0 -50
  463. package/dist/version/git-tag-utils.d.ts.map +0 -1
  464. package/dist/version/git-tag-utils.js +0 -66
  465. package/dist/version/git-tag-utils.js.map +0 -1
  466. package/dist/version/index.d.ts +0 -11
  467. package/dist/version/index.d.ts.map +0 -1
  468. package/dist/version/index.js +0 -11
  469. package/dist/version/index.js.map +0 -1
  470. package/dist/version/release-utils.d.ts +0 -94
  471. package/dist/version/release-utils.d.ts.map +0 -1
  472. package/dist/version/release-utils.js +0 -170
  473. package/dist/version/release-utils.js.map +0 -1
  474. package/dist/version/rollback-utils.d.ts +0 -47
  475. package/dist/version/rollback-utils.d.ts.map +0 -1
  476. package/dist/version/rollback-utils.js +0 -73
  477. package/dist/version/rollback-utils.js.map +0 -1
  478. package/dist/version/version-manager.d.ts +0 -98
  479. package/dist/version/version-manager.d.ts.map +0 -1
  480. package/dist/version/version-manager.js +0 -154
  481. package/dist/version/version-manager.js.map +0 -1
@@ -1,203 +0,0 @@
1
- /**
2
- * Unit tests for version management utilities
3
- * Tests version parsing, validation, formatting, and bumping logic
4
- * Requirements: 3.1, 3.2, 3.3, 3.4
5
- */
6
- import { describe, it, expect } from '@jest/globals';
7
- import { parseVersion, isValidVersion, formatVersion, bumpVersion, bumpVersionString, } from '../version-manager.js';
8
- describe('Version Management Unit Tests', () => {
9
- describe('parseVersion - Version Parsing (Requirement 3.1)', () => {
10
- it('should parse valid semantic version', () => {
11
- const result = parseVersion('1.2.3');
12
- expect(result).toEqual({ major: 1, minor: 2, patch: 3 });
13
- });
14
- it('should parse version with leading v', () => {
15
- const result = parseVersion('v1.2.3');
16
- expect(result).toEqual({ major: 1, minor: 2, patch: 3 });
17
- });
18
- it('should parse version 0.0.0', () => {
19
- const result = parseVersion('0.0.0');
20
- expect(result).toEqual({ major: 0, minor: 0, patch: 0 });
21
- });
22
- it('should parse version with large numbers', () => {
23
- const result = parseVersion('999.888.777');
24
- expect(result).toEqual({ major: 999, minor: 888, patch: 777 });
25
- });
26
- it('should parse version with single digit components', () => {
27
- const result = parseVersion('1.0.0');
28
- expect(result).toEqual({ major: 1, minor: 0, patch: 0 });
29
- });
30
- it('should parse version with multi-digit components', () => {
31
- const result = parseVersion('12.34.56');
32
- expect(result).toEqual({ major: 12, minor: 34, patch: 56 });
33
- });
34
- it('should throw error for invalid format with too few parts', () => {
35
- expect(() => parseVersion('1.2')).toThrow('Invalid version format');
36
- });
37
- it('should throw error for invalid format with too many parts', () => {
38
- expect(() => parseVersion('1.2.3.4')).toThrow('Invalid version format');
39
- });
40
- it('should throw error for non-numeric components', () => {
41
- expect(() => parseVersion('1.2.x')).toThrow('All components must be integers');
42
- });
43
- it('should throw error for negative numbers', () => {
44
- expect(() => parseVersion('1.-2.3')).toThrow('All components must be non-negative');
45
- });
46
- it('should throw error for leading zeros', () => {
47
- expect(() => parseVersion('01.2.3')).toThrow('Components must not have leading zeros');
48
- });
49
- it('should throw error for empty string', () => {
50
- expect(() => parseVersion('')).toThrow('Invalid version format');
51
- });
52
- it('should throw error for version with spaces', () => {
53
- expect(() => parseVersion('1. 2.3')).toThrow('Invalid version format');
54
- });
55
- });
56
- describe('isValidVersion - Version Validation (Requirement 3.1)', () => {
57
- it('should return true for valid version', () => {
58
- expect(isValidVersion('1.2.3')).toBe(true);
59
- });
60
- it('should return true for version with leading v', () => {
61
- expect(isValidVersion('v1.2.3')).toBe(true);
62
- });
63
- it('should return true for version 0.0.0', () => {
64
- expect(isValidVersion('0.0.0')).toBe(true);
65
- });
66
- it('should return false for invalid format', () => {
67
- expect(isValidVersion('1.2')).toBe(false);
68
- });
69
- it('should return false for non-numeric components', () => {
70
- expect(isValidVersion('1.2.x')).toBe(false);
71
- });
72
- it('should return false for negative numbers', () => {
73
- expect(isValidVersion('1.-2.3')).toBe(false);
74
- });
75
- it('should return false for leading zeros', () => {
76
- expect(isValidVersion('01.2.3')).toBe(false);
77
- });
78
- it('should return false for empty string', () => {
79
- expect(isValidVersion('')).toBe(false);
80
- });
81
- });
82
- describe('formatVersion - Version Formatting (Requirement 3.1)', () => {
83
- it('should format semantic version object', () => {
84
- const version = { major: 1, minor: 2, patch: 3 };
85
- expect(formatVersion(version)).toBe('1.2.3');
86
- });
87
- it('should format version 0.0.0', () => {
88
- const version = { major: 0, minor: 0, patch: 0 };
89
- expect(formatVersion(version)).toBe('0.0.0');
90
- });
91
- it('should format version with large numbers', () => {
92
- const version = { major: 999, minor: 888, patch: 777 };
93
- expect(formatVersion(version)).toBe('999.888.777');
94
- });
95
- });
96
- describe('bumpVersion - Patch Increment (Requirement 3.2)', () => {
97
- it('should increment patch version', () => {
98
- const version = { major: 1, minor: 2, patch: 3 };
99
- const result = bumpVersion(version, 'patch');
100
- expect(result).toEqual({ major: 1, minor: 2, patch: 4 });
101
- });
102
- it('should increment patch from 0', () => {
103
- const version = { major: 1, minor: 2, patch: 0 };
104
- const result = bumpVersion(version, 'patch');
105
- expect(result).toEqual({ major: 1, minor: 2, patch: 1 });
106
- });
107
- it('should increment patch with large number', () => {
108
- const version = { major: 1, minor: 2, patch: 99 };
109
- const result = bumpVersion(version, 'patch');
110
- expect(result).toEqual({ major: 1, minor: 2, patch: 100 });
111
- });
112
- it('should not modify original version object', () => {
113
- const version = { major: 1, minor: 2, patch: 3 };
114
- const original = { ...version };
115
- bumpVersion(version, 'patch');
116
- expect(version).toEqual(original);
117
- });
118
- });
119
- describe('bumpVersion - Minor Increment (Requirement 3.3)', () => {
120
- it('should increment minor version and reset patch', () => {
121
- const version = { major: 1, minor: 2, patch: 3 };
122
- const result = bumpVersion(version, 'minor');
123
- expect(result).toEqual({ major: 1, minor: 3, patch: 0 });
124
- });
125
- it('should increment minor from 0', () => {
126
- const version = { major: 1, minor: 0, patch: 5 };
127
- const result = bumpVersion(version, 'minor');
128
- expect(result).toEqual({ major: 1, minor: 1, patch: 0 });
129
- });
130
- it('should reset patch to 0 even when patch is 0', () => {
131
- const version = { major: 1, minor: 2, patch: 0 };
132
- const result = bumpVersion(version, 'minor');
133
- expect(result).toEqual({ major: 1, minor: 3, patch: 0 });
134
- });
135
- it('should increment minor with large number', () => {
136
- const version = { major: 1, minor: 99, patch: 50 };
137
- const result = bumpVersion(version, 'minor');
138
- expect(result).toEqual({ major: 1, minor: 100, patch: 0 });
139
- });
140
- });
141
- describe('bumpVersion - Major Increment (Requirement 3.4)', () => {
142
- it('should increment major version and reset minor and patch', () => {
143
- const version = { major: 1, minor: 2, patch: 3 };
144
- const result = bumpVersion(version, 'major');
145
- expect(result).toEqual({ major: 2, minor: 0, patch: 0 });
146
- });
147
- it('should increment major from 0', () => {
148
- const version = { major: 0, minor: 5, patch: 10 };
149
- const result = bumpVersion(version, 'major');
150
- expect(result).toEqual({ major: 1, minor: 0, patch: 0 });
151
- });
152
- it('should reset minor and patch to 0 even when they are 0', () => {
153
- const version = { major: 1, minor: 0, patch: 0 };
154
- const result = bumpVersion(version, 'major');
155
- expect(result).toEqual({ major: 2, minor: 0, patch: 0 });
156
- });
157
- it('should increment major with large number', () => {
158
- const version = { major: 99, minor: 50, patch: 25 };
159
- const result = bumpVersion(version, 'major');
160
- expect(result).toEqual({ major: 100, minor: 0, patch: 0 });
161
- });
162
- });
163
- describe('bumpVersionString - String Version Bumping (Requirements 3.2, 3.3, 3.4)', () => {
164
- it('should bump patch version from string', () => {
165
- const result = bumpVersionString('1.2.3', 'patch');
166
- expect(result).toBe('1.2.4');
167
- });
168
- it('should bump minor version from string', () => {
169
- const result = bumpVersionString('1.2.3', 'minor');
170
- expect(result).toBe('1.3.0');
171
- });
172
- it('should bump major version from string', () => {
173
- const result = bumpVersionString('1.2.3', 'major');
174
- expect(result).toBe('2.0.0');
175
- });
176
- it('should handle version string with leading v', () => {
177
- const result = bumpVersionString('v1.2.3', 'patch');
178
- expect(result).toBe('1.2.4');
179
- });
180
- it('should throw error for invalid version string', () => {
181
- expect(() => bumpVersionString('invalid', 'patch')).toThrow('Invalid version format');
182
- });
183
- });
184
- describe('Edge Cases', () => {
185
- it('should handle version 0.0.0 patch bump', () => {
186
- const result = bumpVersionString('0.0.0', 'patch');
187
- expect(result).toBe('0.0.1');
188
- });
189
- it('should handle version 0.0.0 minor bump', () => {
190
- const result = bumpVersionString('0.0.0', 'minor');
191
- expect(result).toBe('0.1.0');
192
- });
193
- it('should handle version 0.0.0 major bump', () => {
194
- const result = bumpVersionString('0.0.0', 'major');
195
- expect(result).toBe('1.0.0');
196
- });
197
- it('should handle very large version numbers', () => {
198
- const result = bumpVersionString('999.999.999', 'patch');
199
- expect(result).toBe('999.999.1000');
200
- });
201
- });
202
- });
203
- //# sourceMappingURL=version-manager.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"version-manager.test.js","sourceRoot":"","sources":["../../../src/version/__tests__/version-manager.test.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,QAAQ,EAAE,EAAE,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACrD,OAAO,EACL,YAAY,EACZ,cAAc,EACd,aAAa,EACb,WAAW,EACX,iBAAiB,GAElB,MAAM,uBAAuB,CAAC;AAE/B,QAAQ,CAAC,+BAA+B,EAAE,GAAG,EAAE;IAC7C,QAAQ,CAAC,kDAAkD,EAAE,GAAG,EAAE;QAChE,EAAE,CAAC,qCAAqC,EAAE,GAAG,EAAE;YAC7C,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;YACrC,MAAM,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,qCAAqC,EAAE,GAAG,EAAE;YAC7C,MAAM,MAAM,GAAG,YAAY,CAAC,QAAQ,CAAC,CAAC;YACtC,MAAM,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,KAAK,EAAE,CAAC,EAAE,CAAC,CAAC;QAC3D,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,4BAA4B,EAAE,GAAG,EAAE;YACpC,MAAM,MAAM,GAAG,YAAY,CAAC,OAAO,CAAC,CAAC;YACrC,MAAM,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,EAAE,KAAK,EAAE,CA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0,0 @@
1
- /**
2
- * Changelog File Utilities
3
- *
4
- * Provides functions for reading, parsing, and updating CHANGELOG.md files.
5
- * Ensures idempotent operations and proper version section ordering.
6
- */
7
- export interface ChangelogSection {
8
- version: string;
9
- date: string;
10
- content: string;
11
- }
12
- export interface ChangelogEntry {
13
- version: string;
14
- date: string;
15
- features?: string[];
16
- fixes?: string[];
17
- breaking?: string[];
18
- other?: string[];
19
- }
20
- /**
21
- * Parses a CHANGELOG.md file into structured sections.
22
- *
23
- * @param changelogContent - The raw content of CHANGELOG.md
24
- * @returns Array of changelog sections, ordered from newest to oldest
25
- */
26
- export declare function parseChangelog(changelogContent: string): ChangelogSection[];
27
- /**
28
- * Formats a changelog entry as markdown.
29
- *
30
- * @param entry - The changelog entry to format
31
- * @returns Formatted markdown string
32
- */
33
- export declare function formatChangelogEntry(entry: ChangelogEntry): string;
34
- /**
35
- * Adds a new version section to an existing changelog.
36
- *
37
- * This operation is idempotent:
38
- * - If the version already exists, the changelog is returned unchanged
39
- * - New sections are always placed at the top (after the title)
40
- * - All existing sections are preserved in their original order
41
- *
42
- * @param existingChangelog - The current changelog content
43
- * @param newEntry - The new changelog entry to add
44
- * @returns Updated changelog content with the new entry at the top
45
- */
46
- export declare function addChangelogEntry(existingChangelog: string, newEntry: ChangelogEntry): string;
47
- /**
48
- * Creates a new changelog with an initial entry.
49
- *
50
- * @param entry - The initial changelog entry
51
- * @returns New changelog content with title and entry
52
- */
53
- export declare function createChangelog(entry: ChangelogEntry): string;
54
- /**
55
- * Extracts all version numbers from a changelog.
56
- *
57
- * @param changelogContent - The changelog content to parse
58
- * @returns Array of version strings, ordered from newest to oldest
59
- */
60
- export declare function extractVersions(changelogContent: string): string[];
61
- /**
62
- * Checks if a version exists in the changelog.
63
- *
64
- * @param changelogContent - The changelog content to check
65
- * @param version - The version to look for
66
- * @returns true if the version exists, false otherwise
67
- */
68
- export declare function hasVersion(changelogContent: string, version: string): boolean;
69
- //# sourceMappingURL=changelog-file-utils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"changelog-file-utils.d.ts","sourceRoot":"","sources":["../../src/version/changelog-file-utils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,cAAc;IAC7B,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;IACjB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,gBAAgB,EAAE,MAAM,GAAG,gBAAgB,EAAE,CAmC3E;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,cAAc,GAAG,MAAM,CAgDlE;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,iBAAiB,CAC/B,iBAAiB,EAAE,MAAM,EACzB,QAAQ,EAAE,cAAc,GACvB,MAAM,CAkCR;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,KAAK,EAAE,cAAc,GAAG,MAAM,CAI7D;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,gBAAgB,EAAE,MAAM,GAAG,MAAM,EAAE,CAGlE;AAED;;;;;;GAMG;AACH,wBAAgB,UAAU,CAAC,gBAAgB,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAG7E"}
@@ -1,161 +0,0 @@
1
- /**
2
- * Changelog File Utilities
3
- *
4
- * Provides functions for reading, parsing, and updating CHANGELOG.md files.
5
- * Ensures idempotent operations and proper version section ordering.
6
- */
7
- /**
8
- * Parses a CHANGELOG.md file into structured sections.
9
- *
10
- * @param changelogContent - The raw content of CHANGELOG.md
11
- * @returns Array of changelog sections, ordered from newest to oldest
12
- */
13
- export function parseChangelog(changelogContent) {
14
- const sections = [];
15
- // Split by version headers (## [version] - date or ## version - date)
16
- const versionHeaderRegex = /^## \[?(\d+\.\d+\.\d+)\]?\s*-\s*(.+)$/gm;
17
- let match;
18
- const matches = [];
19
- while ((match = versionHeaderRegex.exec(changelogContent)) !== null) {
20
- matches.push({
21
- version: match[1],
22
- date: match[2],
23
- index: match.index,
24
- });
25
- }
26
- // Extract content for each section
27
- for (let i = 0; i < matches.length; i++) {
28
- const current = matches[i];
29
- const next = matches[i + 1];
30
- const startIndex = current.index;
31
- const endIndex = next ? next.index : changelogContent.length;
32
- const sectionContent = changelogContent.substring(startIndex, endIndex).trim();
33
- sections.push({
34
- version: current.version,
35
- date: current.date,
36
- content: sectionContent,
37
- });
38
- }
39
- return sections;
40
- }
41
- /**
42
- * Formats a changelog entry as markdown.
43
- *
44
- * @param entry - The changelog entry to format
45
- * @returns Formatted markdown string
46
- */
47
- export function formatChangelogEntry(entry) {
48
- const lines = [];
49
- // Header
50
- lines.push(`## [${entry.version}] - ${entry.date}`);
51
- lines.push('');
52
- // Features
53
- if (entry.features && entry.features.length > 0) {
54
- lines.push('### Features');
55
- lines.push('');
56
- entry.features.forEach(feature => {
57
- lines.push(`- ${feature}`);
58
- });
59
- lines.push('');
60
- }
61
- // Bug Fixes
62
- if (entry.fixes && entry.fixes.length > 0) {
63
- lines.push('### Bug Fixes');
64
- lines.push('');
65
- entry.fixes.forEach(fix => {
66
- lines.push(`- ${fix}`);
67
- });
68
- lines.push('');
69
- }
70
- // Breaking Changes
71
- if (entry.breaking && entry.breaking.length > 0) {
72
- lines.push('### Breaking Changes');
73
- lines.push('');
74
- entry.breaking.forEach(breaking => {
75
- lines.push(`- ${breaking}`);
76
- });
77
- lines.push('');
78
- }
79
- // Other changes
80
- if (entry.other && entry.other.length > 0) {
81
- lines.push('### Other Changes');
82
- lines.push('');
83
- entry.other.forEach(other => {
84
- lines.push(`- ${other}`);
85
- });
86
- lines.push('');
87
- }
88
- return lines.join('\n');
89
- }
90
- /**
91
- * Adds a new version section to an existing changelog.
92
- *
93
- * This operation is idempotent:
94
- * - If the version already exists, the changelog is returned unchanged
95
- * - New sections are always placed at the top (after the title)
96
- * - All existing sections are preserved in their original order
97
- *
98
- * @param existingChangelog - The current changelog content
99
- * @param newEntry - The new changelog entry to add
100
- * @returns Updated changelog content with the new entry at the top
101
- */
102
- export function addChangelogEntry(existingChangelog, newEntry) {
103
- // Parse existing changelog
104
- const existingSections = parseChangelog(existingChangelog);
105
- // Check if version already exists (idempotence)
106
- const versionExists = existingSections.some(section => section.version === newEntry.version);
107
- if (versionExists) {
108
- // Return unchanged if version already exists
109
- return existingChangelog;
110
- }
111
- // Format the new entry
112
- const newEntryContent = formatChangelogEntry(newEntry);
113
- // Find the title line (# Changelog or similar)
114
- const titleRegex = /^#\s+.+$/m;
115
- const titleMatch = existingChangelog.match(titleRegex);
116
- if (titleMatch && titleMatch.index !== undefined) {
117
- // Insert after title
118
- const titleEndIndex = titleMatch.index + titleMatch[0].length;
119
- const before = existingChangelog.substring(0, titleEndIndex);
120
- const after = existingChangelog.substring(titleEndIndex);
121
- // Add new entry with proper spacing
122
- return `${before}\n\n${newEntryContent}\n${after.trimStart()}`;
123
- }
124
- else {
125
- // No title found, prepend to the beginning
126
- return `${newEntryContent}\n\n${existingChangelog}`;
127
- }
128
- }
129
- /**
130
- * Creates a new changelog with an initial entry.
131
- *
132
- * @param entry - The initial changelog entry
133
- * @returns New changelog content with title and entry
134
- */
135
- export function createChangelog(entry) {
136
- const title = '# Changelog\n\n';
137
- const entryContent = formatChangelogEntry(entry);
138
- return title + entryContent;
139
- }
140
- /**
141
- * Extracts all version numbers from a changelog.
142
- *
143
- * @param changelogContent - The changelog content to parse
144
- * @returns Array of version strings, ordered from newest to oldest
145
- */
146
- export function extractVersions(changelogContent) {
147
- const sections = parseChangelog(changelogContent);
148
- return sections.map(section => section.version);
149
- }
150
- /**
151
- * Checks if a version exists in the changelog.
152
- *
153
- * @param changelogContent - The changelog content to check
154
- * @param version - The version to look for
155
- * @returns true if the version exists, false otherwise
156
- */
157
- export function hasVersion(changelogContent, version) {
158
- const versions = extractVersions(changelogContent);
159
- return versions.includes(version);
160
- }
161
- //# sourceMappingURL=changelog-file-utils.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"changelog-file-utils.js","sourceRoot":"","sources":["../../src/version/changelog-file-utils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAiBH;;;;;GAKG;AACH,MAAM,UAAU,cAAc,CAAC,gBAAwB;IACrD,MAAM,QAAQ,GAAuB,EAAE,CAAC;IAExC,sEAAsE;IACtE,MAAM,kBAAkB,GAAG,yCAAyC,CAAC;IAErE,IAAI,KAAK,CAAC;IACV,MAAM,OAAO,GAA4D,EAAE,CAAC;IAE5E,OAAO,CAAC,KAAK,GAAG,kBAAkB,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC,KAAK,IAAI,EAAE,CAAC;QACpE,OAAO,CAAC,IAAI,CAAC;YACX,OAAO,EAAE,KAAK,CAAC,CAAC,CAAC;YACjB,IAAI,EAAE,KAAK,CAAC,CAAC,CAAC;YACd,KAAK,EAAE,KAAK,CAAC,KAAK;SACnB,CAAC,CAAC;IACL,CAAC;IAED,mCAAmC;IACnC,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QACxC,MAAM,OAAO,GAAG,OAAO,CAAC,CAAC,CAAC,CAAC;QAC3B,MAAM,IAAI,GAAG,OAAO,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;QAE5B,MAAM,UAAU,GAAG,OAAO,CAAC,KAAK,CAAC;QACjC,MAAM,QAAQ,GAAG,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,gBAAgB,CAAC,MAAM,CAA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AC,EAAE,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC;AAClD,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,UAAU,CAAC,gBAAwB,EAAE,OAAe;IAClE,MAAM,QAAQ,GAAG,eAAe,CAAC,gBAAgB,CAAC,CAAC;IACnD,OAAO,QAAQ,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC;AACpC,CAAC"}
@@ -1,98 +0,0 @@
1
- /**
2
- * Changelog Utilities
3
- *
4
- * Provides functions for parsing conventional commits and grouping them by type.
5
- * Follows the Conventional Commits specification (conventionalcommits.org).
6
- */
7
- /**
8
- * Represents a parsed conventional commit
9
- */
10
- export interface ConventionalCommit {
11
- type: string;
12
- scope?: string;
13
- message: string;
14
- breaking: boolean;
15
- raw: string;
16
- }
17
- /**
18
- * Represents grouped commits by type
19
- */
20
- export interface GroupedCommits {
21
- [type: string]: ConventionalCommit[];
22
- }
23
- /**
24
- * Standard commit types used in conventional commits
25
- */
26
- export declare const COMMIT_TYPES: readonly ["feat", "fix", "docs", "style", "refactor", "perf", "test", "build", "ci", "chore", "revert"];
27
- /**
28
- * Parses a conventional commit message.
29
- *
30
- * Format: type(scope): message
31
- * or: type: message
32
- *
33
- * Breaking changes are indicated by:
34
- * - BREAKING CHANGE: in the commit body
35
- * - ! after type/scope: type!: message or type(scope)!: message
36
- *
37
- * @param commitMessage - The commit message to parse
38
- * @returns Parsed conventional commit object, or null if not a valid conventional commit
39
- */
40
- export declare function parseConventionalCommit(commitMessage: string): ConventionalCommit | null;
41
- /**
42
- * Groups an array of conventional commits by their type.
43
- *
44
- * Commits are grouped into sections based on their type prefix:
45
- * - feat: Features
46
- * - fix: Bug Fixes
47
- * - docs: Documentation
48
- * - etc.
49
- *
50
- * @param commits - Array of commit messages to group
51
- * @returns Object with commit types as keys and arrays of commits as values
52
- */
53
- export declare function groupCommitsByType(commits: string[]): GroupedCommits;
54
- /**
55
- * Checks if a commit message follows the conventional commit format.
56
- *
57
- * @param commitMessage - The commit message to validate
58
- * @returns true if the message follows conventional commit format, false otherwise
59
- */
60
- export declare function isConventionalCommit(commitMessage: string): boolean;
61
- /**
62
- * Gets all unique commit types from an array of commits.
63
- *
64
- * @param commits - Array of commit messages
65
- * @returns Array of unique commit types found
66
- */
67
- export declare function getCommitTypes(commits: string[]): string[];
68
- /**
69
- * Filters commits by type.
70
- *
71
- * @param commits - Array of commit messages
72
- * @param type - The commit type to filter by (e.g., 'feat', 'fix')
73
- * @returns Array of commits matching the specified type
74
- */
75
- export declare function filterCommitsByType(commits: string[], type: string): ConventionalCommit[];
76
- /**
77
- * Result of a dry run changelog generation
78
- */
79
- export interface DryRunChangelogResult {
80
- version: string;
81
- date: string;
82
- commits: GroupedCommits;
83
- preview: string;
84
- isDryRun: true;
85
- }
86
- /**
87
- * Generates a changelog preview without writing to files.
88
- *
89
- * This function is used in dry run mode to preview changelog content.
90
- *
91
- * @param version - The version for this changelog entry
92
- * @param commits - Array of commit messages since last release
93
- * @returns Dry run result with changelog preview
94
- *
95
- * Validates: Requirements 15.3
96
- */
97
- export declare function generateDryRunChangelog(version: string, commits: string[]): DryRunChangelogResult;
98
- //# sourceMappingURL=changelog-utils.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"changelog-utils.d.ts","sourceRoot":"","sources":["../../src/version/changelog-utils.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAIH;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,OAAO,CAAC;IAClB,GAAG,EAAE,MAAM,CAAC;CACb;AAED;;GAEG;AACH,MAAM,WAAW,cAAc;IAC7B,CAAC,IAAI,EAAE,MAAM,GAAG,kBAAkB,EAAE,CAAC;CACtC;AAED;;GAEG;AACH,eAAO,MAAM,YAAY,yGAYf,CAAC;AAEX;;;;;;;;;;;;GAYG;AACH,wBAA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