@hyperfrontend/versioning 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 (353) hide show
  1. package/ARCHITECTURE.md +593 -0
  2. package/CHANGELOG.md +35 -0
  3. package/FUNDING.md +141 -0
  4. package/LICENSE.md +21 -0
  5. package/README.md +195 -0
  6. package/SECURITY.md +82 -0
  7. package/changelog/compare/diff.d.ts +128 -0
  8. package/changelog/compare/diff.d.ts.map +1 -0
  9. package/changelog/compare/index.cjs.js +628 -0
  10. package/changelog/compare/index.cjs.js.map +1 -0
  11. package/changelog/compare/index.d.ts +4 -0
  12. package/changelog/compare/index.d.ts.map +1 -0
  13. package/changelog/compare/index.esm.js +612 -0
  14. package/changelog/compare/index.esm.js.map +1 -0
  15. package/changelog/compare/is-equal.d.ts +114 -0
  16. package/changelog/compare/is-equal.d.ts.map +1 -0
  17. package/changelog/index.cjs.js +6448 -0
  18. package/changelog/index.cjs.js.map +1 -0
  19. package/changelog/index.d.ts +6 -0
  20. package/changelog/index.d.ts.map +1 -0
  21. package/changelog/index.esm.js +6358 -0
  22. package/changelog/index.esm.js.map +1 -0
  23. package/changelog/models/changelog.d.ts +86 -0
  24. package/changelog/models/changelog.d.ts.map +1 -0
  25. package/changelog/models/commit-ref.d.ts +51 -0
  26. package/changelog/models/commit-ref.d.ts.map +1 -0
  27. package/changelog/models/entry.d.ts +84 -0
  28. package/changelog/models/entry.d.ts.map +1 -0
  29. package/changelog/models/index.cjs.js +2043 -0
  30. package/changelog/models/index.cjs.js.map +1 -0
  31. package/changelog/models/index.d.ts +11 -0
  32. package/changelog/models/index.d.ts.map +1 -0
  33. package/changelog/models/index.esm.js +2026 -0
  34. package/changelog/models/index.esm.js.map +1 -0
  35. package/changelog/models/schema.d.ts +68 -0
  36. package/changelog/models/schema.d.ts.map +1 -0
  37. package/changelog/models/section.d.ts +25 -0
  38. package/changelog/models/section.d.ts.map +1 -0
  39. package/changelog/operations/add-entry.d.ts +56 -0
  40. package/changelog/operations/add-entry.d.ts.map +1 -0
  41. package/changelog/operations/add-item.d.ts +18 -0
  42. package/changelog/operations/add-item.d.ts.map +1 -0
  43. package/changelog/operations/filter-by-predicate.d.ts +81 -0
  44. package/changelog/operations/filter-by-predicate.d.ts.map +1 -0
  45. package/changelog/operations/filter-by-range.d.ts +63 -0
  46. package/changelog/operations/filter-by-range.d.ts.map +1 -0
  47. package/changelog/operations/filter-entries.d.ts +9 -0
  48. package/changelog/operations/filter-entries.d.ts.map +1 -0
  49. package/changelog/operations/index.cjs.js +2455 -0
  50. package/changelog/operations/index.cjs.js.map +1 -0
  51. package/changelog/operations/index.d.ts +15 -0
  52. package/changelog/operations/index.d.ts.map +1 -0
  53. package/changelog/operations/index.esm.js +2411 -0
  54. package/changelog/operations/index.esm.js.map +1 -0
  55. package/changelog/operations/merge.d.ts +88 -0
  56. package/changelog/operations/merge.d.ts.map +1 -0
  57. package/changelog/operations/remove-entry.d.ts +45 -0
  58. package/changelog/operations/remove-entry.d.ts.map +1 -0
  59. package/changelog/operations/remove-section.d.ts +50 -0
  60. package/changelog/operations/remove-section.d.ts.map +1 -0
  61. package/changelog/operations/transform.d.ts +143 -0
  62. package/changelog/operations/transform.d.ts.map +1 -0
  63. package/changelog/parse/index.cjs.js +1282 -0
  64. package/changelog/parse/index.cjs.js.map +1 -0
  65. package/changelog/parse/index.d.ts +5 -0
  66. package/changelog/parse/index.d.ts.map +1 -0
  67. package/changelog/parse/index.esm.js +1275 -0
  68. package/changelog/parse/index.esm.js.map +1 -0
  69. package/changelog/parse/line.d.ts +48 -0
  70. package/changelog/parse/line.d.ts.map +1 -0
  71. package/changelog/parse/parser.d.ts +16 -0
  72. package/changelog/parse/parser.d.ts.map +1 -0
  73. package/changelog/parse/tokenizer.d.ts +49 -0
  74. package/changelog/parse/tokenizer.d.ts.map +1 -0
  75. package/changelog/serialize/index.cjs.js +574 -0
  76. package/changelog/serialize/index.cjs.js.map +1 -0
  77. package/changelog/serialize/index.d.ts +6 -0
  78. package/changelog/serialize/index.d.ts.map +1 -0
  79. package/changelog/serialize/index.esm.js +564 -0
  80. package/changelog/serialize/index.esm.js.map +1 -0
  81. package/changelog/serialize/templates.d.ts +81 -0
  82. package/changelog/serialize/templates.d.ts.map +1 -0
  83. package/changelog/serialize/to-json.d.ts +57 -0
  84. package/changelog/serialize/to-json.d.ts.map +1 -0
  85. package/changelog/serialize/to-string.d.ts +30 -0
  86. package/changelog/serialize/to-string.d.ts.map +1 -0
  87. package/commits/index.cjs.js +648 -0
  88. package/commits/index.cjs.js.map +1 -0
  89. package/commits/index.d.ts +3 -0
  90. package/commits/index.d.ts.map +1 -0
  91. package/commits/index.esm.js +629 -0
  92. package/commits/index.esm.js.map +1 -0
  93. package/commits/models/breaking.d.ts +39 -0
  94. package/commits/models/breaking.d.ts.map +1 -0
  95. package/commits/models/commit-type.d.ts +32 -0
  96. package/commits/models/commit-type.d.ts.map +1 -0
  97. package/commits/models/conventional.d.ts +49 -0
  98. package/commits/models/conventional.d.ts.map +1 -0
  99. package/commits/models/index.cjs.js +207 -0
  100. package/commits/models/index.cjs.js.map +1 -0
  101. package/commits/models/index.d.ts +7 -0
  102. package/commits/models/index.d.ts.map +1 -0
  103. package/commits/models/index.esm.js +193 -0
  104. package/commits/models/index.esm.js.map +1 -0
  105. package/commits/parse/body.d.ts +18 -0
  106. package/commits/parse/body.d.ts.map +1 -0
  107. package/commits/parse/footer.d.ts +16 -0
  108. package/commits/parse/footer.d.ts.map +1 -0
  109. package/commits/parse/header.d.ts +15 -0
  110. package/commits/parse/header.d.ts.map +1 -0
  111. package/commits/parse/index.cjs.js +505 -0
  112. package/commits/parse/index.cjs.js.map +1 -0
  113. package/commits/parse/index.d.ts +5 -0
  114. package/commits/parse/index.d.ts.map +1 -0
  115. package/commits/parse/index.esm.js +499 -0
  116. package/commits/parse/index.esm.js.map +1 -0
  117. package/commits/parse/message.d.ts +17 -0
  118. package/commits/parse/message.d.ts.map +1 -0
  119. package/commits/utils/replace-char.d.ts +19 -0
  120. package/commits/utils/replace-char.d.ts.map +1 -0
  121. package/flow/executor/execute.d.ts +72 -0
  122. package/flow/executor/execute.d.ts.map +1 -0
  123. package/flow/executor/index.cjs.js +4402 -0
  124. package/flow/executor/index.cjs.js.map +1 -0
  125. package/flow/executor/index.d.ts +3 -0
  126. package/flow/executor/index.d.ts.map +1 -0
  127. package/flow/executor/index.esm.js +4398 -0
  128. package/flow/executor/index.esm.js.map +1 -0
  129. package/flow/factory.d.ts +58 -0
  130. package/flow/factory.d.ts.map +1 -0
  131. package/flow/index.cjs.js +8506 -0
  132. package/flow/index.cjs.js.map +1 -0
  133. package/flow/index.d.ts +7 -0
  134. package/flow/index.d.ts.map +1 -0
  135. package/flow/index.esm.js +8451 -0
  136. package/flow/index.esm.js.map +1 -0
  137. package/flow/models/flow.d.ts +130 -0
  138. package/flow/models/flow.d.ts.map +1 -0
  139. package/flow/models/index.cjs.js +285 -0
  140. package/flow/models/index.cjs.js.map +1 -0
  141. package/flow/models/index.d.ts +7 -0
  142. package/flow/models/index.d.ts.map +1 -0
  143. package/flow/models/index.esm.js +268 -0
  144. package/flow/models/index.esm.js.map +1 -0
  145. package/flow/models/step.d.ts +108 -0
  146. package/flow/models/step.d.ts.map +1 -0
  147. package/flow/models/types.d.ts +150 -0
  148. package/flow/models/types.d.ts.map +1 -0
  149. package/flow/presets/conventional.d.ts +59 -0
  150. package/flow/presets/conventional.d.ts.map +1 -0
  151. package/flow/presets/independent.d.ts +61 -0
  152. package/flow/presets/independent.d.ts.map +1 -0
  153. package/flow/presets/index.cjs.js +3903 -0
  154. package/flow/presets/index.cjs.js.map +1 -0
  155. package/flow/presets/index.d.ts +4 -0
  156. package/flow/presets/index.d.ts.map +1 -0
  157. package/flow/presets/index.esm.js +3889 -0
  158. package/flow/presets/index.esm.js.map +1 -0
  159. package/flow/presets/synced.d.ts +65 -0
  160. package/flow/presets/synced.d.ts.map +1 -0
  161. package/flow/steps/analyze-commits.d.ts +19 -0
  162. package/flow/steps/analyze-commits.d.ts.map +1 -0
  163. package/flow/steps/calculate-bump.d.ts +27 -0
  164. package/flow/steps/calculate-bump.d.ts.map +1 -0
  165. package/flow/steps/create-commit.d.ts +16 -0
  166. package/flow/steps/create-commit.d.ts.map +1 -0
  167. package/flow/steps/create-tag.d.ts +22 -0
  168. package/flow/steps/create-tag.d.ts.map +1 -0
  169. package/flow/steps/fetch-registry.d.ts +19 -0
  170. package/flow/steps/fetch-registry.d.ts.map +1 -0
  171. package/flow/steps/generate-changelog.d.ts +25 -0
  172. package/flow/steps/generate-changelog.d.ts.map +1 -0
  173. package/flow/steps/index.cjs.js +3523 -0
  174. package/flow/steps/index.cjs.js.map +1 -0
  175. package/flow/steps/index.d.ts +8 -0
  176. package/flow/steps/index.d.ts.map +1 -0
  177. package/flow/steps/index.esm.js +3504 -0
  178. package/flow/steps/index.esm.js.map +1 -0
  179. package/flow/steps/update-packages.d.ts +25 -0
  180. package/flow/steps/update-packages.d.ts.map +1 -0
  181. package/flow/utils/interpolate.d.ts +11 -0
  182. package/flow/utils/interpolate.d.ts.map +1 -0
  183. package/git/factory.d.ts +233 -0
  184. package/git/factory.d.ts.map +1 -0
  185. package/git/index.cjs.js +2863 -0
  186. package/git/index.cjs.js.map +1 -0
  187. package/git/index.d.ts +5 -0
  188. package/git/index.d.ts.map +1 -0
  189. package/git/index.esm.js +2785 -0
  190. package/git/index.esm.js.map +1 -0
  191. package/git/models/commit.d.ts +129 -0
  192. package/git/models/commit.d.ts.map +1 -0
  193. package/git/models/index.cjs.js +755 -0
  194. package/git/models/index.cjs.js.map +1 -0
  195. package/git/models/index.d.ts +7 -0
  196. package/git/models/index.d.ts.map +1 -0
  197. package/git/models/index.esm.js +729 -0
  198. package/git/models/index.esm.js.map +1 -0
  199. package/git/models/ref.d.ts +120 -0
  200. package/git/models/ref.d.ts.map +1 -0
  201. package/git/models/tag.d.ts +141 -0
  202. package/git/models/tag.d.ts.map +1 -0
  203. package/git/operations/commit.d.ts +97 -0
  204. package/git/operations/commit.d.ts.map +1 -0
  205. package/git/operations/head-info.d.ts +29 -0
  206. package/git/operations/head-info.d.ts.map +1 -0
  207. package/git/operations/index.cjs.js +1954 -0
  208. package/git/operations/index.cjs.js.map +1 -0
  209. package/git/operations/index.d.ts +14 -0
  210. package/git/operations/index.d.ts.map +1 -0
  211. package/git/operations/index.esm.js +1903 -0
  212. package/git/operations/index.esm.js.map +1 -0
  213. package/git/operations/log.d.ts +104 -0
  214. package/git/operations/log.d.ts.map +1 -0
  215. package/git/operations/manage-tags.d.ts +60 -0
  216. package/git/operations/manage-tags.d.ts.map +1 -0
  217. package/git/operations/query-tags.d.ts +88 -0
  218. package/git/operations/query-tags.d.ts.map +1 -0
  219. package/git/operations/stage.d.ts +66 -0
  220. package/git/operations/stage.d.ts.map +1 -0
  221. package/git/operations/status.d.ts +173 -0
  222. package/git/operations/status.d.ts.map +1 -0
  223. package/index.cjs.js +16761 -0
  224. package/index.cjs.js.map +1 -0
  225. package/index.d.ts +102 -0
  226. package/index.d.ts.map +1 -0
  227. package/index.esm.js +16427 -0
  228. package/index.esm.js.map +1 -0
  229. package/package.json +200 -0
  230. package/registry/factory.d.ts +18 -0
  231. package/registry/factory.d.ts.map +1 -0
  232. package/registry/index.cjs.js +543 -0
  233. package/registry/index.cjs.js.map +1 -0
  234. package/registry/index.d.ts +5 -0
  235. package/registry/index.d.ts.map +1 -0
  236. package/registry/index.esm.js +535 -0
  237. package/registry/index.esm.js.map +1 -0
  238. package/registry/models/index.cjs.js +69 -0
  239. package/registry/models/index.cjs.js.map +1 -0
  240. package/registry/models/index.d.ts +6 -0
  241. package/registry/models/index.d.ts.map +1 -0
  242. package/registry/models/index.esm.js +66 -0
  243. package/registry/models/index.esm.js.map +1 -0
  244. package/registry/models/package-info.d.ts +55 -0
  245. package/registry/models/package-info.d.ts.map +1 -0
  246. package/registry/models/registry.d.ts +62 -0
  247. package/registry/models/registry.d.ts.map +1 -0
  248. package/registry/models/version-info.d.ts +67 -0
  249. package/registry/models/version-info.d.ts.map +1 -0
  250. package/registry/npm/cache.d.ts +50 -0
  251. package/registry/npm/cache.d.ts.map +1 -0
  252. package/registry/npm/client.d.ts +30 -0
  253. package/registry/npm/client.d.ts.map +1 -0
  254. package/registry/npm/index.cjs.js +456 -0
  255. package/registry/npm/index.cjs.js.map +1 -0
  256. package/registry/npm/index.d.ts +4 -0
  257. package/registry/npm/index.d.ts.map +1 -0
  258. package/registry/npm/index.esm.js +451 -0
  259. package/registry/npm/index.esm.js.map +1 -0
  260. package/semver/compare/compare.d.ts +100 -0
  261. package/semver/compare/compare.d.ts.map +1 -0
  262. package/semver/compare/index.cjs.js +386 -0
  263. package/semver/compare/index.cjs.js.map +1 -0
  264. package/semver/compare/index.d.ts +3 -0
  265. package/semver/compare/index.d.ts.map +1 -0
  266. package/semver/compare/index.esm.js +370 -0
  267. package/semver/compare/index.esm.js.map +1 -0
  268. package/semver/compare/sort.d.ts +36 -0
  269. package/semver/compare/sort.d.ts.map +1 -0
  270. package/semver/format/index.cjs.js +58 -0
  271. package/semver/format/index.cjs.js.map +1 -0
  272. package/semver/format/index.d.ts +2 -0
  273. package/semver/format/index.d.ts.map +1 -0
  274. package/semver/format/index.esm.js +53 -0
  275. package/semver/format/index.esm.js.map +1 -0
  276. package/semver/format/to-string.d.ts +31 -0
  277. package/semver/format/to-string.d.ts.map +1 -0
  278. package/semver/increment/bump.d.ts +37 -0
  279. package/semver/increment/bump.d.ts.map +1 -0
  280. package/semver/increment/index.cjs.js +223 -0
  281. package/semver/increment/index.cjs.js.map +1 -0
  282. package/semver/increment/index.d.ts +2 -0
  283. package/semver/increment/index.d.ts.map +1 -0
  284. package/semver/increment/index.esm.js +219 -0
  285. package/semver/increment/index.esm.js.map +1 -0
  286. package/semver/index.cjs.js +1499 -0
  287. package/semver/index.cjs.js.map +1 -0
  288. package/semver/index.d.ts +6 -0
  289. package/semver/index.d.ts.map +1 -0
  290. package/semver/index.esm.js +1458 -0
  291. package/semver/index.esm.js.map +1 -0
  292. package/semver/models/index.cjs.js +153 -0
  293. package/semver/models/index.cjs.js.map +1 -0
  294. package/semver/models/index.d.ts +5 -0
  295. package/semver/models/index.d.ts.map +1 -0
  296. package/semver/models/index.esm.js +139 -0
  297. package/semver/models/index.esm.js.map +1 -0
  298. package/semver/models/range.d.ts +83 -0
  299. package/semver/models/range.d.ts.map +1 -0
  300. package/semver/models/version.d.ts +78 -0
  301. package/semver/models/version.d.ts.map +1 -0
  302. package/semver/parse/index.cjs.js +799 -0
  303. package/semver/parse/index.cjs.js.map +1 -0
  304. package/semver/parse/index.d.ts +5 -0
  305. package/semver/parse/index.d.ts.map +1 -0
  306. package/semver/parse/index.esm.js +793 -0
  307. package/semver/parse/index.esm.js.map +1 -0
  308. package/semver/parse/range.d.ts +38 -0
  309. package/semver/parse/range.d.ts.map +1 -0
  310. package/semver/parse/version.d.ts +49 -0
  311. package/semver/parse/version.d.ts.map +1 -0
  312. package/workspace/discovery/changelog-path.d.ts +21 -0
  313. package/workspace/discovery/changelog-path.d.ts.map +1 -0
  314. package/workspace/discovery/dependencies.d.ts +145 -0
  315. package/workspace/discovery/dependencies.d.ts.map +1 -0
  316. package/workspace/discovery/discover-changelogs.d.ts +76 -0
  317. package/workspace/discovery/discover-changelogs.d.ts.map +1 -0
  318. package/workspace/discovery/index.cjs.js +2300 -0
  319. package/workspace/discovery/index.cjs.js.map +1 -0
  320. package/workspace/discovery/index.d.ts +13 -0
  321. package/workspace/discovery/index.d.ts.map +1 -0
  322. package/workspace/discovery/index.esm.js +2283 -0
  323. package/workspace/discovery/index.esm.js.map +1 -0
  324. package/workspace/discovery/packages.d.ts +83 -0
  325. package/workspace/discovery/packages.d.ts.map +1 -0
  326. package/workspace/index.cjs.js +4445 -0
  327. package/workspace/index.cjs.js.map +1 -0
  328. package/workspace/index.d.ts +52 -0
  329. package/workspace/index.d.ts.map +1 -0
  330. package/workspace/index.esm.js +4394 -0
  331. package/workspace/index.esm.js.map +1 -0
  332. package/workspace/models/index.cjs.js +284 -0
  333. package/workspace/models/index.cjs.js.map +1 -0
  334. package/workspace/models/index.d.ts +10 -0
  335. package/workspace/models/index.d.ts.map +1 -0
  336. package/workspace/models/index.esm.js +261 -0
  337. package/workspace/models/index.esm.js.map +1 -0
  338. package/workspace/models/project.d.ts +118 -0
  339. package/workspace/models/project.d.ts.map +1 -0
  340. package/workspace/models/workspace.d.ts +139 -0
  341. package/workspace/models/workspace.d.ts.map +1 -0
  342. package/workspace/operations/batch-update.d.ts +99 -0
  343. package/workspace/operations/batch-update.d.ts.map +1 -0
  344. package/workspace/operations/cascade-bump.d.ts +125 -0
  345. package/workspace/operations/cascade-bump.d.ts.map +1 -0
  346. package/workspace/operations/index.cjs.js +2675 -0
  347. package/workspace/operations/index.cjs.js.map +1 -0
  348. package/workspace/operations/index.d.ts +12 -0
  349. package/workspace/operations/index.d.ts.map +1 -0
  350. package/workspace/operations/index.esm.js +2663 -0
  351. package/workspace/operations/index.esm.js.map +1 -0
  352. package/workspace/operations/validate.d.ts +85 -0
  353. package/workspace/operations/validate.d.ts.map +1 -0
@@ -0,0 +1,456 @@
1
+ 'use strict';
2
+
3
+ var node_child_process = require('node:child_process');
4
+
5
+ /**
6
+ * Safe copies of Array built-in static methods.
7
+ *
8
+ * These references are captured at module initialization time to protect against
9
+ * prototype pollution attacks. Import only what you need for tree-shaking.
10
+ *
11
+ * @module @hyperfrontend/immutable-api-utils/built-in-copy/array
12
+ */
13
+ // Capture references at module initialization time
14
+ const _Array = globalThis.Array;
15
+ /**
16
+ * (Safe copy) Determines whether the passed value is an Array.
17
+ */
18
+ const isArray = _Array.isArray;
19
+
20
+ /**
21
+ * Safe copies of Date built-in via factory function and static methods.
22
+ *
23
+ * Since constructors cannot be safely captured via Object.assign, this module
24
+ * provides a factory function that uses Reflect.construct internally.
25
+ *
26
+ * These references are captured at module initialization time to protect against
27
+ * prototype pollution attacks. Import only what you need for tree-shaking.
28
+ *
29
+ * @module @hyperfrontend/immutable-api-utils/built-in-copy/date
30
+ */
31
+ // Capture references at module initialization time
32
+ const _Date = globalThis.Date;
33
+ const _Reflect$2 = globalThis.Reflect;
34
+ function createDate(...args) {
35
+ return _Reflect$2.construct(_Date, args);
36
+ }
37
+ /**
38
+ * (Safe copy) Returns the number of milliseconds elapsed since January 1, 1970 00:00:00 UTC.
39
+ */
40
+ const dateNow = _Date.now;
41
+
42
+ /**
43
+ * Safe copies of Error built-ins via factory functions.
44
+ *
45
+ * Since constructors cannot be safely captured via Object.assign, this module
46
+ * provides factory functions that use Reflect.construct internally.
47
+ *
48
+ * These references are captured at module initialization time to protect against
49
+ * prototype pollution attacks. Import only what you need for tree-shaking.
50
+ *
51
+ * @module @hyperfrontend/immutable-api-utils/built-in-copy/error
52
+ */
53
+ // Capture references at module initialization time
54
+ const _Error = globalThis.Error;
55
+ const _Reflect$1 = globalThis.Reflect;
56
+ /**
57
+ * (Safe copy) Creates a new Error using the captured Error constructor.
58
+ * Use this instead of `new Error()`.
59
+ *
60
+ * @param message - Optional error message.
61
+ * @param options - Optional error options.
62
+ * @returns A new Error instance.
63
+ */
64
+ const createError = (message, options) => _Reflect$1.construct(_Error, [message, options]);
65
+
66
+ /**
67
+ * Safe copies of JSON built-in methods.
68
+ *
69
+ * These references are captured at module initialization time to protect against
70
+ * prototype pollution attacks. Import only what you need for tree-shaking.
71
+ *
72
+ * @module @hyperfrontend/immutable-api-utils/built-in-copy/json
73
+ */
74
+ // Capture references at module initialization time
75
+ const _JSON = globalThis.JSON;
76
+ /**
77
+ * (Safe copy) Converts a JavaScript Object Notation (JSON) string into an object.
78
+ */
79
+ const parse = _JSON.parse;
80
+
81
+ /**
82
+ * Safe copies of Map built-in via factory function.
83
+ *
84
+ * Since constructors cannot be safely captured via Object.assign, this module
85
+ * provides a factory function that uses Reflect.construct internally.
86
+ *
87
+ * These references are captured at module initialization time to protect against
88
+ * prototype pollution attacks. Import only what you need for tree-shaking.
89
+ *
90
+ * @module @hyperfrontend/immutable-api-utils/built-in-copy/map
91
+ */
92
+ // Capture references at module initialization time
93
+ const _Map = globalThis.Map;
94
+ const _Reflect = globalThis.Reflect;
95
+ /**
96
+ * (Safe copy) Creates a new Map using the captured Map constructor.
97
+ * Use this instead of `new Map()`.
98
+ *
99
+ * @param iterable - Optional iterable of key-value pairs.
100
+ * @returns A new Map instance.
101
+ */
102
+ const createMap = (iterable) => _Reflect.construct(_Map, iterable ? [iterable] : []);
103
+
104
+ /**
105
+ * Creates a new cache instance.
106
+ *
107
+ * @param ttl - Time-to-live in milliseconds (default: 60000 = 1 minute)
108
+ * @returns A new Cache instance
109
+ */
110
+ function createCache(ttl = 60000) {
111
+ const entries = createMap();
112
+ return {
113
+ get(key) {
114
+ const entry = entries.get(key);
115
+ if (!entry)
116
+ return undefined;
117
+ const now = dateNow();
118
+ if (now - entry.timestamp > ttl) {
119
+ entries.delete(key);
120
+ return undefined;
121
+ }
122
+ return entry.data;
123
+ },
124
+ set(key, value) {
125
+ entries.set(key, { data: value, timestamp: dateNow() });
126
+ },
127
+ delete(key) {
128
+ entries.delete(key);
129
+ },
130
+ clear() {
131
+ entries.clear();
132
+ },
133
+ size() {
134
+ return entries.size;
135
+ },
136
+ };
137
+ }
138
+
139
+ /**
140
+ * Creates an npm registry client.
141
+ *
142
+ * @param config - Registry configuration
143
+ * @returns A Registry implementation for npm
144
+ *
145
+ * @example
146
+ * const registry = createNpmRegistry()
147
+ * const version = await registry.getLatestVersion('@hyperfrontend/utils')
148
+ */
149
+ function createNpmRegistry(config = {}) {
150
+ const state = {
151
+ config: {
152
+ url: config.url ?? 'https://registry.npmjs.org',
153
+ timeout: config.timeout ?? 10000,
154
+ cacheTtl: config.cacheTtl ?? 60000,
155
+ authToken: config.authToken,
156
+ },
157
+ cache: createCache(config.cacheTtl ?? 60000),
158
+ };
159
+ return {
160
+ name: 'npm',
161
+ url: state.config.url,
162
+ getLatestVersion: (packageName) => getLatestVersion(state, packageName),
163
+ isVersionPublished: (packageName, version) => isVersionPublished(state, packageName, version),
164
+ getPackageInfo: (packageName) => getPackageInfo(state, packageName),
165
+ getVersionInfo: (packageName, version) => getVersionInfo(state, packageName, version),
166
+ listVersions: (packageName) => listVersions(state, packageName),
167
+ };
168
+ }
169
+ /**
170
+ * Gets the latest published version of a package.
171
+ *
172
+ * @param state - Internal registry client state
173
+ * @param packageName - Name of the package to query
174
+ * @returns The latest version string, or null if not found
175
+ */
176
+ async function getLatestVersion(state, packageName) {
177
+ const cacheKey = `latest:${packageName}`;
178
+ const cached = state.cache.get(cacheKey);
179
+ if (cached !== undefined)
180
+ return cached;
181
+ try {
182
+ const safeName = escapePackageName(packageName);
183
+ const result = node_child_process.execSync(`npm view ${safeName} version`, {
184
+ encoding: 'utf-8',
185
+ timeout: state.config.timeout,
186
+ stdio: ['pipe', 'pipe', 'pipe'],
187
+ }).trim();
188
+ const version = result || null;
189
+ state.cache.set(cacheKey, version);
190
+ return version;
191
+ }
192
+ catch {
193
+ state.cache.set(cacheKey, null);
194
+ return null;
195
+ }
196
+ }
197
+ /**
198
+ * Checks if a specific version is published.
199
+ *
200
+ * @param state - Internal registry client state
201
+ * @param packageName - Name of the package to check
202
+ * @param version - Semver version string to verify
203
+ * @returns True if the version is published
204
+ */
205
+ async function isVersionPublished(state, packageName, version) {
206
+ const cacheKey = `published:${packageName}@${version}`;
207
+ const cached = state.cache.get(cacheKey);
208
+ if (cached !== undefined)
209
+ return cached;
210
+ try {
211
+ const safeName = escapePackageName(packageName);
212
+ const safeVersion = escapeVersion(version);
213
+ const result = node_child_process.execSync(`npm view ${safeName}@${safeVersion} version`, {
214
+ encoding: 'utf-8',
215
+ timeout: state.config.timeout,
216
+ stdio: ['pipe', 'pipe', 'pipe'],
217
+ }).trim();
218
+ const published = result === version;
219
+ state.cache.set(cacheKey, published);
220
+ return published;
221
+ }
222
+ catch {
223
+ state.cache.set(cacheKey, false);
224
+ return false;
225
+ }
226
+ }
227
+ /**
228
+ * Gets full package information.
229
+ *
230
+ * @param state - Internal registry client state
231
+ * @param packageName - Name of the package to query
232
+ * @returns Package info, or null if not found
233
+ */
234
+ async function getPackageInfo(state, packageName) {
235
+ const cacheKey = `info:${packageName}`;
236
+ const cached = state.cache.get(cacheKey);
237
+ if (cached !== undefined)
238
+ return cached;
239
+ try {
240
+ const safeName = escapePackageName(packageName);
241
+ const result = node_child_process.execSync(`npm view ${safeName} --json`, {
242
+ encoding: 'utf-8',
243
+ timeout: state.config.timeout,
244
+ stdio: ['pipe', 'pipe', 'pipe'],
245
+ maxBuffer: 10 * 1024 * 1024, // 10MB
246
+ });
247
+ const data = parse(result);
248
+ const info = {
249
+ name: data.name,
250
+ description: data.description,
251
+ latestVersion: data.version,
252
+ versions: isArray(data.versions) ? data.versions : [data.version],
253
+ license: data.license,
254
+ repository: extractRepoUrl(data.repository),
255
+ homepage: data.homepage,
256
+ maintainers: (data.maintainers ?? []).map((m) => {
257
+ if (typeof m === 'string') {
258
+ return { name: m };
259
+ }
260
+ return { name: m.name ?? '', email: m.email };
261
+ }),
262
+ keywords: data.keywords,
263
+ lastModified: data.time?.modified,
264
+ };
265
+ state.cache.set(cacheKey, info);
266
+ return info;
267
+ }
268
+ catch {
269
+ state.cache.set(cacheKey, null);
270
+ return null;
271
+ }
272
+ }
273
+ /**
274
+ * Gets version-specific information.
275
+ *
276
+ * @param state - Internal registry client state
277
+ * @param packageName - Name of the package to query
278
+ * @param version - Semver version string to look up
279
+ * @returns Version info, or null if not found
280
+ */
281
+ async function getVersionInfo(state, packageName, version) {
282
+ const cacheKey = `versionInfo:${packageName}@${version}`;
283
+ const cached = state.cache.get(cacheKey);
284
+ if (cached !== undefined)
285
+ return cached;
286
+ try {
287
+ const safeName = escapePackageName(packageName);
288
+ const safeVersion = escapeVersion(version);
289
+ const result = node_child_process.execSync(`npm view ${safeName}@${safeVersion} --json`, {
290
+ encoding: 'utf-8',
291
+ timeout: state.config.timeout,
292
+ stdio: ['pipe', 'pipe', 'pipe'],
293
+ maxBuffer: 5 * 1024 * 1024, // 5MB
294
+ });
295
+ const data = parse(result);
296
+ const info = {
297
+ version: data.version,
298
+ publishedAt: data.time ?? createDate().toISOString(),
299
+ tarball: data.dist?.tarball ?? '',
300
+ integrity: data.dist?.integrity,
301
+ dependencies: data.dependencies,
302
+ devDependencies: data.devDependencies,
303
+ peerDependencies: data.peerDependencies,
304
+ optionalDependencies: data.optionalDependencies,
305
+ engines: data.engines,
306
+ nodeVersion: data._nodeVersion,
307
+ npmVersion: data._npmVersion,
308
+ };
309
+ state.cache.set(cacheKey, info);
310
+ return info;
311
+ }
312
+ catch {
313
+ state.cache.set(cacheKey, null);
314
+ return null;
315
+ }
316
+ }
317
+ /**
318
+ * Lists all published versions.
319
+ *
320
+ * @param state - Internal registry client state
321
+ * @param packageName - Name of the package to query
322
+ * @returns Array of version strings
323
+ */
324
+ async function listVersions(state, packageName) {
325
+ const cacheKey = `versions:${packageName}`;
326
+ const cached = state.cache.get(cacheKey);
327
+ if (cached !== undefined)
328
+ return cached;
329
+ try {
330
+ const safeName = escapePackageName(packageName);
331
+ const result = node_child_process.execSync(`npm view ${safeName} versions --json`, {
332
+ encoding: 'utf-8',
333
+ timeout: state.config.timeout,
334
+ stdio: ['pipe', 'pipe', 'pipe'],
335
+ });
336
+ const versions = parse(result);
337
+ const versionList = isArray(versions) ? versions : [versions];
338
+ state.cache.set(cacheKey, versionList);
339
+ return versionList;
340
+ }
341
+ catch {
342
+ state.cache.set(cacheKey, []);
343
+ return [];
344
+ }
345
+ }
346
+ // ============================================================================
347
+ // Security helpers - character-by-character validation (no regex)
348
+ // ============================================================================
349
+ /**
350
+ * Maximum allowed package name length (npm limit).
351
+ */
352
+ const MAX_PACKAGE_NAME_LENGTH = 214;
353
+ /**
354
+ * Escapes a package name for safe use in shell commands.
355
+ * Uses character-by-character validation to prevent injection.
356
+ *
357
+ * @param name - Package name to escape
358
+ * @returns Safe package name
359
+ * @throws {Error} If package name contains invalid characters
360
+ */
361
+ function escapePackageName(name) {
362
+ if (!name || typeof name !== 'string') {
363
+ throw createError('Package name is required');
364
+ }
365
+ if (name.length > MAX_PACKAGE_NAME_LENGTH) {
366
+ throw createError(`Package name exceeds maximum length of ${MAX_PACKAGE_NAME_LENGTH}`);
367
+ }
368
+ const safe = [];
369
+ for (let i = 0; i < name.length; i++) {
370
+ const code = name.charCodeAt(i);
371
+ // Allow: a-z, A-Z, 0-9, @, /, -, _, .
372
+ if ((code >= 97 && code <= 122) || // a-z
373
+ (code >= 65 && code <= 90) || // A-Z
374
+ (code >= 48 && code <= 57) || // 0-9
375
+ code === 64 || // @
376
+ code === 47 || // /
377
+ code === 45 || // -
378
+ code === 95 || // _
379
+ code === 46 // .
380
+ ) {
381
+ safe.push(name[i]);
382
+ }
383
+ else {
384
+ throw createError(`Invalid character in package name at position ${i}: "${name[i]}"`);
385
+ }
386
+ }
387
+ return safe.join('');
388
+ }
389
+ /**
390
+ * Maximum allowed version string length.
391
+ */
392
+ const MAX_VERSION_LENGTH = 256;
393
+ /**
394
+ * Escapes a version string for safe use in shell commands.
395
+ *
396
+ * @param version - Version string to escape
397
+ * @returns Safe version string
398
+ * @throws {Error} If version contains invalid characters
399
+ */
400
+ function escapeVersion(version) {
401
+ if (!version || typeof version !== 'string') {
402
+ throw createError('Version is required');
403
+ }
404
+ if (version.length > MAX_VERSION_LENGTH) {
405
+ throw createError(`Version exceeds maximum length of ${MAX_VERSION_LENGTH}`);
406
+ }
407
+ const safe = [];
408
+ for (let i = 0; i < version.length; i++) {
409
+ const code = version.charCodeAt(i);
410
+ // Allow: 0-9, ., -, +, a-z, A-Z
411
+ if ((code >= 48 && code <= 57) || // 0-9
412
+ (code >= 97 && code <= 122) || // a-z
413
+ (code >= 65 && code <= 90) || // A-Z
414
+ code === 46 || // .
415
+ code === 45 || // -
416
+ code === 43 // +
417
+ ) {
418
+ safe.push(version[i]);
419
+ }
420
+ else {
421
+ throw createError(`Invalid character in version at position ${i}: "${version[i]}"`);
422
+ }
423
+ }
424
+ return safe.join('');
425
+ }
426
+ /**
427
+ * Extracts repository URL from npm package repository field.
428
+ *
429
+ * @param repository - Repository field from package.json (string or object)
430
+ * @returns Repository URL, or undefined if not found
431
+ */
432
+ function extractRepoUrl(repository) {
433
+ if (typeof repository === 'string')
434
+ return repository;
435
+ if (repository && typeof repository === 'object') {
436
+ const repo = repository;
437
+ if (repo.url) {
438
+ // Clean up git+ prefix and .git suffix
439
+ let url = repo.url;
440
+ if (url.startsWith('git+')) {
441
+ url = url.slice(4);
442
+ }
443
+ if (url.endsWith('.git')) {
444
+ url = url.slice(0, -4);
445
+ }
446
+ return url;
447
+ }
448
+ }
449
+ return undefined;
450
+ }
451
+
452
+ exports.createCache = createCache;
453
+ exports.createNpmRegistry = createNpmRegistry;
454
+ exports.escapePackageName = escapePackageName;
455
+ exports.escapeVersion = escapeVersion;
456
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":["../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/array/index.ts","../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/date/index.ts","../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/error/index.ts","../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/json/index.ts","../../../../../../../../../../libs/utils/immutable-api/src/built-in-copy/map/index.ts","../../../../../../../../../../libs/versioning/src/registry/npm/cache.ts","../../../../../../../../../../libs/versioning/src/registry/npm/client.ts"],"sourcesContent":[null,null,null,null,null,null,null],"names":["_Reflect","execSync"],"mappings":";;;;AAAA;;;;;;;AAOG;AAEH;AACA,MAAM,MAAM,GAAG,UAAU,CAAC,KAAK;AAG/B;;AAEG;AACI,MAAM,OAAO,GAAG,MAAM,CAAC,OAAO;;AChBrC;;;;;;;;;;AAUG;AAEH;AACA,MAAM,KAAK,GAAG,UAAU,CAAC,IAAI;AAC7B,MAAMA,UAAQ,GAAG,UAAU,CAAC,OAAO;AAoB7B,SAAU,UAAU,CAAC,GAAG,IAAe,EAAA;IAC3C,O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ChD,MAAM,IAAI,GAAoC,UAAU;AACxD,QAAA,IAAI,IAAI,CAAC,GAAG,EAAE;;AAEZ,YAAA,IAAI,GAAG,GAAG,IAAI,CAAC,GAAG;AAClB,YAAA,IAAI,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,EAAE;AAC1B,gBAAA,GAAG,GAAG,GAAG,CAAC,KAAK,CAAC,CAAC,CAAC;YACpB;AACA,YAAA,IAAI,GAAG,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE;gBACxB,GAAG,GAAG,GAAG,CAAC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC;YACxB;AACA,YAAA,OAAO,GAAG;QACZ;IACF;AAEA,IAAA,OAAO,SAAS;AAClB;;;;;;;"}
@@ -0,0 +1,4 @@
1
+ export type { Cache, CacheEntry } from './cache';
2
+ export { createNpmRegistry, escapePackageName, escapeVersion } from './client';
3
+ export { createCache } from './cache';
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../../../../libs/versioning/src/registry/npm/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAChD,OAAO,EAAE,iBAAiB,EAAE,iBAAiB,EAAE,aAAa,EAAE,MAAM,UAAU,CAAA;AAC9E,OAAO,EAAE,WAAW,EAAE,MAAM,SAAS,CAAA"}