@macula-io/martha 0.0.0 → 1.0.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 (1022) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +53 -8
  3. package/bin/martha-install.mjs +54 -0
  4. package/check_the_node_version/check_the_node_version.mjs +19 -0
  5. package/install_a_release/install_a_release.mjs +166 -0
  6. package/keep_the_names_in_one_place/names.mjs +49 -0
  7. package/node_modules/@gar/promise-retry/LICENSE +20 -0
  8. package/node_modules/@gar/promise-retry/README.md +86 -0
  9. package/node_modules/@gar/promise-retry/lib/index.d.ts +114 -0
  10. package/node_modules/@gar/promise-retry/lib/index.js +62 -0
  11. package/node_modules/@gar/promise-retry/lib/retry.js +109 -0
  12. package/node_modules/@gar/promise-retry/package.json +45 -0
  13. package/node_modules/@isaacs/nonrecursive-glob-match/LICENSE.md +55 -0
  14. package/node_modules/@isaacs/nonrecursive-glob-match/README.md +364 -0
  15. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.d.ts +123 -0
  16. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.d.ts.map +1 -0
  17. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.js +778 -0
  18. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.js.map +1 -0
  19. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.min.js +3 -0
  20. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/index.min.js.map +7 -0
  21. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/numeric-range.d.ts +15 -0
  22. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/numeric-range.d.ts.map +1 -0
  23. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/numeric-range.js +76 -0
  24. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/numeric-range.js.map +1 -0
  25. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/package.json +3 -0
  26. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/parse-class.d.ts +4 -0
  27. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/parse-class.d.ts.map +1 -0
  28. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/parse-class.js +142 -0
  29. package/node_modules/@isaacs/nonrecursive-glob-match/dist/commonjs/parse-class.js.map +1 -0
  30. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.d.ts +123 -0
  31. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.d.ts.map +1 -0
  32. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.js +774 -0
  33. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.js.map +1 -0
  34. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.min.js +3 -0
  35. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/index.min.js.map +7 -0
  36. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/numeric-range.d.ts +15 -0
  37. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/numeric-range.d.ts.map +1 -0
  38. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/numeric-range.js +72 -0
  39. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/numeric-range.js.map +1 -0
  40. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/package.json +3 -0
  41. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/parse-class.d.ts +4 -0
  42. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/parse-class.d.ts.map +1 -0
  43. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/parse-class.js +138 -0
  44. package/node_modules/@isaacs/nonrecursive-glob-match/dist/esm/parse-class.js.map +1 -0
  45. package/node_modules/@isaacs/nonrecursive-glob-match/package.json +56 -0
  46. package/node_modules/@isaacs/nonrecursive-glob-match/src/index.ts +932 -0
  47. package/node_modules/@isaacs/nonrecursive-glob-match/src/numeric-range.ts +79 -0
  48. package/node_modules/@isaacs/nonrecursive-glob-match/src/parse-class.ts +158 -0
  49. package/node_modules/@npmcli/agent/README.md +40 -0
  50. package/node_modules/@npmcli/agent/lib/agents.js +268 -0
  51. package/node_modules/@npmcli/agent/lib/dns.js +53 -0
  52. package/node_modules/@npmcli/agent/lib/errors.js +61 -0
  53. package/node_modules/@npmcli/agent/lib/index.js +56 -0
  54. package/node_modules/@npmcli/agent/lib/options.js +90 -0
  55. package/node_modules/@npmcli/agent/lib/proxy.js +88 -0
  56. package/node_modules/@npmcli/agent/package.json +61 -0
  57. package/node_modules/@npmcli/fs/LICENSE.md +20 -0
  58. package/node_modules/@npmcli/fs/README.md +97 -0
  59. package/node_modules/@npmcli/fs/lib/common/get-options.js +20 -0
  60. package/node_modules/@npmcli/fs/lib/common/node.js +9 -0
  61. package/node_modules/@npmcli/fs/lib/cp/LICENSE +15 -0
  62. package/node_modules/@npmcli/fs/lib/cp/errors.js +129 -0
  63. package/node_modules/@npmcli/fs/lib/cp/index.js +22 -0
  64. package/node_modules/@npmcli/fs/lib/cp/polyfill.js +428 -0
  65. package/node_modules/@npmcli/fs/lib/index.js +13 -0
  66. package/node_modules/@npmcli/fs/lib/move-file.js +78 -0
  67. package/node_modules/@npmcli/fs/lib/readdir-scoped.js +20 -0
  68. package/node_modules/@npmcli/fs/lib/with-temp-dir.js +39 -0
  69. package/node_modules/@npmcli/fs/package.json +54 -0
  70. package/node_modules/@npmcli/redact/LICENSE +21 -0
  71. package/node_modules/@npmcli/redact/README.md +42 -0
  72. package/node_modules/@npmcli/redact/lib/deep-map.js +71 -0
  73. package/node_modules/@npmcli/redact/lib/error.js +28 -0
  74. package/node_modules/@npmcli/redact/lib/index.js +44 -0
  75. package/node_modules/@npmcli/redact/lib/matchers.js +88 -0
  76. package/node_modules/@npmcli/redact/lib/server.js +59 -0
  77. package/node_modules/@npmcli/redact/lib/utils.js +202 -0
  78. package/node_modules/@npmcli/redact/package.json +52 -0
  79. package/node_modules/@sigstore/bundle/LICENSE +202 -0
  80. package/node_modules/@sigstore/bundle/README.md +19 -0
  81. package/node_modules/@sigstore/bundle/dist/build.d.ts +18 -0
  82. package/node_modules/@sigstore/bundle/dist/build.js +100 -0
  83. package/node_modules/@sigstore/bundle/dist/bundle.d.ts +74 -0
  84. package/node_modules/@sigstore/bundle/dist/bundle.js +24 -0
  85. package/node_modules/@sigstore/bundle/dist/error.d.ts +4 -0
  86. package/node_modules/@sigstore/bundle/dist/error.js +26 -0
  87. package/node_modules/@sigstore/bundle/dist/index.d.ts +8 -0
  88. package/node_modules/@sigstore/bundle/dist/index.js +43 -0
  89. package/node_modules/@sigstore/bundle/dist/serialized.d.ts +74 -0
  90. package/node_modules/@sigstore/bundle/dist/serialized.js +49 -0
  91. package/node_modules/@sigstore/bundle/dist/utility.d.ts +14 -0
  92. package/node_modules/@sigstore/bundle/dist/utility.js +2 -0
  93. package/node_modules/@sigstore/bundle/dist/validate.d.ts +7 -0
  94. package/node_modules/@sigstore/bundle/dist/validate.js +199 -0
  95. package/node_modules/@sigstore/bundle/package.json +35 -0
  96. package/node_modules/@sigstore/core/LICENSE +202 -0
  97. package/node_modules/@sigstore/core/README.md +10 -0
  98. package/node_modules/@sigstore/core/dist/asn1/error.d.ts +4 -0
  99. package/node_modules/@sigstore/core/dist/asn1/error.js +24 -0
  100. package/node_modules/@sigstore/core/dist/asn1/index.d.ts +1 -0
  101. package/node_modules/@sigstore/core/dist/asn1/index.js +20 -0
  102. package/node_modules/@sigstore/core/dist/asn1/length.d.ts +3 -0
  103. package/node_modules/@sigstore/core/dist/asn1/length.js +73 -0
  104. package/node_modules/@sigstore/core/dist/asn1/obj.d.ts +14 -0
  105. package/node_modules/@sigstore/core/dist/asn1/obj.js +173 -0
  106. package/node_modules/@sigstore/core/dist/asn1/parse.d.ts +6 -0
  107. package/node_modules/@sigstore/core/dist/asn1/parse.js +143 -0
  108. package/node_modules/@sigstore/core/dist/asn1/tag.d.ts +16 -0
  109. package/node_modules/@sigstore/core/dist/asn1/tag.js +89 -0
  110. package/node_modules/@sigstore/core/dist/crypto.d.ts +6 -0
  111. package/node_modules/@sigstore/core/dist/crypto.js +69 -0
  112. package/node_modules/@sigstore/core/dist/dsse.d.ts +1 -0
  113. package/node_modules/@sigstore/core/dist/dsse.js +29 -0
  114. package/node_modules/@sigstore/core/dist/encoding.d.ts +2 -0
  115. package/node_modules/@sigstore/core/dist/encoding.js +27 -0
  116. package/node_modules/@sigstore/core/dist/index.d.ts +9 -0
  117. package/node_modules/@sigstore/core/dist/index.js +66 -0
  118. package/node_modules/@sigstore/core/dist/json.d.ts +1 -0
  119. package/node_modules/@sigstore/core/dist/json.js +60 -0
  120. package/node_modules/@sigstore/core/dist/oid.d.ts +3 -0
  121. package/node_modules/@sigstore/core/dist/oid.js +20 -0
  122. package/node_modules/@sigstore/core/dist/pem.d.ts +2 -0
  123. package/node_modules/@sigstore/core/dist/pem.js +43 -0
  124. package/node_modules/@sigstore/core/dist/rfc3161/error.d.ts +2 -0
  125. package/node_modules/@sigstore/core/dist/rfc3161/error.js +21 -0
  126. package/node_modules/@sigstore/core/dist/rfc3161/index.d.ts +1 -0
  127. package/node_modules/@sigstore/core/dist/rfc3161/index.js +20 -0
  128. package/node_modules/@sigstore/core/dist/rfc3161/timestamp.d.ts +36 -0
  129. package/node_modules/@sigstore/core/dist/rfc3161/timestamp.js +212 -0
  130. package/node_modules/@sigstore/core/dist/rfc3161/tstinfo.d.ts +12 -0
  131. package/node_modules/@sigstore/core/dist/rfc3161/tstinfo.js +72 -0
  132. package/node_modules/@sigstore/core/dist/stream.d.ts +21 -0
  133. package/node_modules/@sigstore/core/dist/stream.js +117 -0
  134. package/node_modules/@sigstore/core/dist/x509/cert.d.ts +43 -0
  135. package/node_modules/@sigstore/core/dist/x509/cert.js +245 -0
  136. package/node_modules/@sigstore/core/dist/x509/ext.d.ts +41 -0
  137. package/node_modules/@sigstore/core/dist/x509/ext.js +146 -0
  138. package/node_modules/@sigstore/core/dist/x509/index.d.ts +2 -0
  139. package/node_modules/@sigstore/core/dist/x509/index.js +23 -0
  140. package/node_modules/@sigstore/core/dist/x509/sct.d.ts +25 -0
  141. package/node_modules/@sigstore/core/dist/x509/sct.js +158 -0
  142. package/node_modules/@sigstore/core/package.json +31 -0
  143. package/node_modules/@sigstore/protobuf-specs/LICENSE +202 -0
  144. package/node_modules/@sigstore/protobuf-specs/README.md +5 -0
  145. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/envelope.d.ts +44 -0
  146. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/envelope.js +59 -0
  147. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/events.d.ts +64 -0
  148. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/events.js +174 -0
  149. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/api/field_behavior.d.ts +74 -0
  150. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/api/field_behavior.js +141 -0
  151. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/any.d.ts +74 -0
  152. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/any.js +35 -0
  153. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/descriptor.d.ts +1309 -0
  154. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/descriptor.js +2191 -0
  155. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/timestamp.d.ts +113 -0
  156. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/google/protobuf/timestamp.js +29 -0
  157. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/dsse.d.ts +23 -0
  158. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/dsse.js +55 -0
  159. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/entry.d.ts +43 -0
  160. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/entry.js +81 -0
  161. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/hashedrekord.d.ts +22 -0
  162. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/hashedrekord.js +56 -0
  163. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/verifier.d.ts +35 -0
  164. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/rekor/v2/verifier.js +74 -0
  165. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_bundle.d.ts +146 -0
  166. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_bundle.js +103 -0
  167. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_common.d.ts +304 -0
  168. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_common.js +612 -0
  169. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_monitor.d.ts +33 -0
  170. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_monitor.js +55 -0
  171. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_rekor.d.ts +144 -0
  172. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_rekor.js +137 -0
  173. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_trustroot.d.ts +386 -0
  174. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_trustroot.js +284 -0
  175. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_verification.d.ts +191 -0
  176. package/node_modules/@sigstore/protobuf-specs/dist/__generated__/sigstore_verification.js +281 -0
  177. package/node_modules/@sigstore/protobuf-specs/dist/index.d.ts +6 -0
  178. package/node_modules/@sigstore/protobuf-specs/dist/index.js +37 -0
  179. package/node_modules/@sigstore/protobuf-specs/dist/rekor/v2/index.d.ts +4 -0
  180. package/node_modules/@sigstore/protobuf-specs/dist/rekor/v2/index.js +35 -0
  181. package/node_modules/@sigstore/protobuf-specs/package.json +35 -0
  182. package/node_modules/@sigstore/sign/LICENSE +202 -0
  183. package/node_modules/@sigstore/sign/README.md +185 -0
  184. package/node_modules/@sigstore/sign/dist/bundler/base.d.ts +22 -0
  185. package/node_modules/@sigstore/sign/dist/bundler/base.js +52 -0
  186. package/node_modules/@sigstore/sign/dist/bundler/bundle.d.ts +5 -0
  187. package/node_modules/@sigstore/sign/dist/bundler/bundle.js +81 -0
  188. package/node_modules/@sigstore/sign/dist/bundler/dsse.d.ts +13 -0
  189. package/node_modules/@sigstore/sign/dist/bundler/dsse.js +47 -0
  190. package/node_modules/@sigstore/sign/dist/bundler/index.d.ts +3 -0
  191. package/node_modules/@sigstore/sign/dist/bundler/index.js +7 -0
  192. package/node_modules/@sigstore/sign/dist/bundler/message.d.ts +7 -0
  193. package/node_modules/@sigstore/sign/dist/bundler/message.js +30 -0
  194. package/node_modules/@sigstore/sign/dist/config.d.ts +18 -0
  195. package/node_modules/@sigstore/sign/dist/config.js +143 -0
  196. package/node_modules/@sigstore/sign/dist/error.d.ts +12 -0
  197. package/node_modules/@sigstore/sign/dist/error.js +41 -0
  198. package/node_modules/@sigstore/sign/dist/external/error.d.ts +9 -0
  199. package/node_modules/@sigstore/sign/dist/external/error.js +28 -0
  200. package/node_modules/@sigstore/sign/dist/external/fetch.d.ts +4 -0
  201. package/node_modules/@sigstore/sign/dist/external/fetch.js +98 -0
  202. package/node_modules/@sigstore/sign/dist/external/fulcio.d.ts +37 -0
  203. package/node_modules/@sigstore/sign/dist/external/fulcio.js +42 -0
  204. package/node_modules/@sigstore/sign/dist/external/rekor-v2.d.ts +14 -0
  205. package/node_modules/@sigstore/sign/dist/external/rekor-v2.js +45 -0
  206. package/node_modules/@sigstore/sign/dist/external/rekor.d.ts +28 -0
  207. package/node_modules/@sigstore/sign/dist/external/rekor.js +81 -0
  208. package/node_modules/@sigstore/sign/dist/external/tsa.d.ts +16 -0
  209. package/node_modules/@sigstore/sign/dist/external/tsa.js +44 -0
  210. package/node_modules/@sigstore/sign/dist/identity/ci.d.ts +11 -0
  211. package/node_modules/@sigstore/sign/dist/identity/ci.js +88 -0
  212. package/node_modules/@sigstore/sign/dist/identity/index.d.ts +2 -0
  213. package/node_modules/@sigstore/sign/dist/identity/index.js +20 -0
  214. package/node_modules/@sigstore/sign/dist/identity/provider.d.ts +3 -0
  215. package/node_modules/@sigstore/sign/dist/identity/provider.js +2 -0
  216. package/node_modules/@sigstore/sign/dist/index.d.ts +11 -0
  217. package/node_modules/@sigstore/sign/dist/index.js +19 -0
  218. package/node_modules/@sigstore/sign/dist/signer/fulcio/ca.d.ts +12 -0
  219. package/node_modules/@sigstore/sign/dist/signer/fulcio/ca.js +60 -0
  220. package/node_modules/@sigstore/sign/dist/signer/fulcio/ephemeral.d.ts +6 -0
  221. package/node_modules/@sigstore/sign/dist/signer/fulcio/ephemeral.js +43 -0
  222. package/node_modules/@sigstore/sign/dist/signer/fulcio/index.d.ts +16 -0
  223. package/node_modules/@sigstore/sign/dist/signer/fulcio/index.js +90 -0
  224. package/node_modules/@sigstore/sign/dist/signer/index.d.ts +2 -0
  225. package/node_modules/@sigstore/sign/dist/signer/index.js +22 -0
  226. package/node_modules/@sigstore/sign/dist/signer/signer.d.ts +15 -0
  227. package/node_modules/@sigstore/sign/dist/signer/signer.js +17 -0
  228. package/node_modules/@sigstore/sign/dist/types/fetch.d.ts +6 -0
  229. package/node_modules/@sigstore/sign/dist/types/fetch.js +2 -0
  230. package/node_modules/@sigstore/sign/dist/util/index.d.ts +3 -0
  231. package/node_modules/@sigstore/sign/dist/util/index.js +59 -0
  232. package/node_modules/@sigstore/sign/dist/util/oidc.d.ts +1 -0
  233. package/node_modules/@sigstore/sign/dist/util/oidc.js +35 -0
  234. package/node_modules/@sigstore/sign/dist/util/ua.d.ts +1 -0
  235. package/node_modules/@sigstore/sign/dist/util/ua.js +32 -0
  236. package/node_modules/@sigstore/sign/dist/witness/index.d.ts +3 -0
  237. package/node_modules/@sigstore/sign/dist/witness/index.js +24 -0
  238. package/node_modules/@sigstore/sign/dist/witness/tlog/client.d.ts +29 -0
  239. package/node_modules/@sigstore/sign/dist/witness/tlog/client.js +92 -0
  240. package/node_modules/@sigstore/sign/dist/witness/tlog/entry.d.ts +5 -0
  241. package/node_modules/@sigstore/sign/dist/witness/tlog/entry.js +197 -0
  242. package/node_modules/@sigstore/sign/dist/witness/tlog/index.d.ts +20 -0
  243. package/node_modules/@sigstore/sign/dist/witness/tlog/index.js +97 -0
  244. package/node_modules/@sigstore/sign/dist/witness/tsa/client.d.ts +12 -0
  245. package/node_modules/@sigstore/sign/dist/witness/tsa/client.js +47 -0
  246. package/node_modules/@sigstore/sign/dist/witness/tsa/index.d.ts +13 -0
  247. package/node_modules/@sigstore/sign/dist/witness/tsa/index.js +45 -0
  248. package/node_modules/@sigstore/sign/dist/witness/witness.d.ts +9 -0
  249. package/node_modules/@sigstore/sign/dist/witness/witness.js +2 -0
  250. package/node_modules/@sigstore/sign/package.json +45 -0
  251. package/node_modules/@sigstore/tuf/LICENSE +202 -0
  252. package/node_modules/@sigstore/tuf/README.md +69 -0
  253. package/node_modules/@sigstore/tuf/dist/appdata.d.ts +1 -0
  254. package/node_modules/@sigstore/tuf/dist/appdata.js +43 -0
  255. package/node_modules/@sigstore/tuf/dist/client.d.ts +23 -0
  256. package/node_modules/@sigstore/tuf/dist/client.js +116 -0
  257. package/node_modules/@sigstore/tuf/dist/error.d.ts +11 -0
  258. package/node_modules/@sigstore/tuf/dist/error.js +14 -0
  259. package/node_modules/@sigstore/tuf/dist/index.d.ts +10 -0
  260. package/node_modules/@sigstore/tuf/dist/index.js +56 -0
  261. package/node_modules/@sigstore/tuf/dist/target.d.ts +2 -0
  262. package/node_modules/@sigstore/tuf/dist/target.js +79 -0
  263. package/node_modules/@sigstore/tuf/package.json +41 -0
  264. package/node_modules/@sigstore/tuf/seeds.json +1 -0
  265. package/node_modules/@sigstore/verify/README.md +13 -0
  266. package/node_modules/@sigstore/verify/dist/bundle/dsse.d.ts +13 -0
  267. package/node_modules/@sigstore/verify/dist/bundle/dsse.js +50 -0
  268. package/node_modules/@sigstore/verify/dist/bundle/index.d.ts +4 -0
  269. package/node_modules/@sigstore/verify/dist/bundle/index.js +59 -0
  270. package/node_modules/@sigstore/verify/dist/bundle/message.d.ts +14 -0
  271. package/node_modules/@sigstore/verify/dist/bundle/message.js +59 -0
  272. package/node_modules/@sigstore/verify/dist/error.d.ts +16 -0
  273. package/node_modules/@sigstore/verify/dist/error.js +34 -0
  274. package/node_modules/@sigstore/verify/dist/index.d.ts +6 -0
  275. package/node_modules/@sigstore/verify/dist/index.js +28 -0
  276. package/node_modules/@sigstore/verify/dist/key/certificate.d.ts +21 -0
  277. package/node_modules/@sigstore/verify/dist/key/certificate.js +216 -0
  278. package/node_modules/@sigstore/verify/dist/key/index.d.ts +10 -0
  279. package/node_modules/@sigstore/verify/dist/key/index.js +75 -0
  280. package/node_modules/@sigstore/verify/dist/key/sct.d.ts +4 -0
  281. package/node_modules/@sigstore/verify/dist/key/sct.js +78 -0
  282. package/node_modules/@sigstore/verify/dist/policy.d.ts +5 -0
  283. package/node_modules/@sigstore/verify/dist/policy.js +48 -0
  284. package/node_modules/@sigstore/verify/dist/shared.types.d.ts +55 -0
  285. package/node_modules/@sigstore/verify/dist/shared.types.js +2 -0
  286. package/node_modules/@sigstore/verify/dist/timestamp/index.d.ts +11 -0
  287. package/node_modules/@sigstore/verify/dist/timestamp/index.js +24 -0
  288. package/node_modules/@sigstore/verify/dist/timestamp/tsa.d.ts +3 -0
  289. package/node_modules/@sigstore/verify/dist/timestamp/tsa.js +63 -0
  290. package/node_modules/@sigstore/verify/dist/tlog/checkpoint.d.ts +11 -0
  291. package/node_modules/@sigstore/verify/dist/tlog/checkpoint.js +168 -0
  292. package/node_modules/@sigstore/verify/dist/tlog/dsse.d.ts +6 -0
  293. package/node_modules/@sigstore/verify/dist/tlog/dsse.js +106 -0
  294. package/node_modules/@sigstore/verify/dist/tlog/hashedrekord.d.ts +6 -0
  295. package/node_modules/@sigstore/verify/dist/tlog/hashedrekord.js +94 -0
  296. package/node_modules/@sigstore/verify/dist/tlog/index.d.ts +5 -0
  297. package/node_modules/@sigstore/verify/dist/tlog/index.js +106 -0
  298. package/node_modules/@sigstore/verify/dist/tlog/intoto.d.ts +3 -0
  299. package/node_modules/@sigstore/verify/dist/tlog/intoto.js +62 -0
  300. package/node_modules/@sigstore/verify/dist/tlog/merkle.d.ts +3 -0
  301. package/node_modules/@sigstore/verify/dist/tlog/merkle.js +115 -0
  302. package/node_modules/@sigstore/verify/dist/tlog/set.d.ts +3 -0
  303. package/node_modules/@sigstore/verify/dist/tlog/set.js +60 -0
  304. package/node_modules/@sigstore/verify/dist/trust/filter.d.ts +8 -0
  305. package/node_modules/@sigstore/verify/dist/trust/filter.js +23 -0
  306. package/node_modules/@sigstore/verify/dist/trust/index.d.ts +5 -0
  307. package/node_modules/@sigstore/verify/dist/trust/index.js +90 -0
  308. package/node_modules/@sigstore/verify/dist/trust/trust.types.d.ts +29 -0
  309. package/node_modules/@sigstore/verify/dist/trust/trust.types.js +2 -0
  310. package/node_modules/@sigstore/verify/dist/verifier.d.ts +34 -0
  311. package/node_modules/@sigstore/verify/dist/verifier.js +172 -0
  312. package/node_modules/@sigstore/verify/package.json +36 -0
  313. package/node_modules/@tufjs/canonical-json/LICENSE +21 -0
  314. package/node_modules/@tufjs/canonical-json/README.md +53 -0
  315. package/node_modules/@tufjs/canonical-json/lib/index.d.ts +2 -0
  316. package/node_modules/@tufjs/canonical-json/lib/index.js +64 -0
  317. package/node_modules/@tufjs/canonical-json/package.json +35 -0
  318. package/node_modules/@tufjs/models/LICENSE +21 -0
  319. package/node_modules/@tufjs/models/README.md +3 -0
  320. package/node_modules/@tufjs/models/dist/base.d.ts +37 -0
  321. package/node_modules/@tufjs/models/dist/base.js +99 -0
  322. package/node_modules/@tufjs/models/dist/delegations.d.ts +32 -0
  323. package/node_modules/@tufjs/models/dist/delegations.js +122 -0
  324. package/node_modules/@tufjs/models/dist/error.d.ts +12 -0
  325. package/node_modules/@tufjs/models/dist/error.js +27 -0
  326. package/node_modules/@tufjs/models/dist/file.d.ts +38 -0
  327. package/node_modules/@tufjs/models/dist/file.js +191 -0
  328. package/node_modules/@tufjs/models/dist/index.d.ts +10 -0
  329. package/node_modules/@tufjs/models/dist/index.js +24 -0
  330. package/node_modules/@tufjs/models/dist/key.d.ts +21 -0
  331. package/node_modules/@tufjs/models/dist/key.js +90 -0
  332. package/node_modules/@tufjs/models/dist/metadata.d.ts +47 -0
  333. package/node_modules/@tufjs/models/dist/metadata.js +165 -0
  334. package/node_modules/@tufjs/models/dist/role.d.ts +103 -0
  335. package/node_modules/@tufjs/models/dist/role.js +310 -0
  336. package/node_modules/@tufjs/models/dist/root.d.ts +29 -0
  337. package/node_modules/@tufjs/models/dist/root.js +119 -0
  338. package/node_modules/@tufjs/models/dist/signature.d.ts +20 -0
  339. package/node_modules/@tufjs/models/dist/signature.js +40 -0
  340. package/node_modules/@tufjs/models/dist/snapshot.d.ts +23 -0
  341. package/node_modules/@tufjs/models/dist/snapshot.js +72 -0
  342. package/node_modules/@tufjs/models/dist/targets.d.ts +20 -0
  343. package/node_modules/@tufjs/models/dist/targets.js +94 -0
  344. package/node_modules/@tufjs/models/dist/timestamp.d.ts +21 -0
  345. package/node_modules/@tufjs/models/dist/timestamp.js +59 -0
  346. package/node_modules/@tufjs/models/dist/utils/guard.d.ts +7 -0
  347. package/node_modules/@tufjs/models/dist/utils/guard.js +32 -0
  348. package/node_modules/@tufjs/models/dist/utils/index.d.ts +3 -0
  349. package/node_modules/@tufjs/models/dist/utils/index.js +38 -0
  350. package/node_modules/@tufjs/models/dist/utils/key.d.ts +11 -0
  351. package/node_modules/@tufjs/models/dist/utils/key.js +170 -0
  352. package/node_modules/@tufjs/models/dist/utils/oid.d.ts +1 -0
  353. package/node_modules/@tufjs/models/dist/utils/oid.js +26 -0
  354. package/node_modules/@tufjs/models/dist/utils/types.d.ts +4 -0
  355. package/node_modules/@tufjs/models/dist/utils/types.js +2 -0
  356. package/node_modules/@tufjs/models/dist/utils/verify.d.ts +3 -0
  357. package/node_modules/@tufjs/models/dist/utils/verify.js +13 -0
  358. package/node_modules/@tufjs/models/package.json +37 -0
  359. package/node_modules/agent-base/LICENSE +22 -0
  360. package/node_modules/agent-base/README.md +69 -0
  361. package/node_modules/agent-base/dist/helpers.d.ts +10 -0
  362. package/node_modules/agent-base/dist/helpers.d.ts.map +1 -0
  363. package/node_modules/agent-base/dist/helpers.js +37 -0
  364. package/node_modules/agent-base/dist/helpers.js.map +1 -0
  365. package/node_modules/agent-base/dist/index.d.ts +37 -0
  366. package/node_modules/agent-base/dist/index.d.ts.map +1 -0
  367. package/node_modules/agent-base/dist/index.js +146 -0
  368. package/node_modules/agent-base/dist/index.js.map +1 -0
  369. package/node_modules/agent-base/package.json +46 -0
  370. package/node_modules/balanced-match/LICENSE.md +23 -0
  371. package/node_modules/balanced-match/README.md +57 -0
  372. package/node_modules/balanced-match/dist/commonjs/index.d.ts +9 -0
  373. package/node_modules/balanced-match/dist/commonjs/index.d.ts.map +1 -0
  374. package/node_modules/balanced-match/dist/commonjs/index.js +59 -0
  375. package/node_modules/balanced-match/dist/commonjs/index.js.map +1 -0
  376. package/node_modules/balanced-match/dist/commonjs/package.json +3 -0
  377. package/node_modules/balanced-match/dist/esm/index.d.ts +9 -0
  378. package/node_modules/balanced-match/dist/esm/index.d.ts.map +1 -0
  379. package/node_modules/balanced-match/dist/esm/index.js +54 -0
  380. package/node_modules/balanced-match/dist/esm/index.js.map +1 -0
  381. package/node_modules/balanced-match/dist/esm/package.json +3 -0
  382. package/node_modules/balanced-match/package.json +68 -0
  383. package/node_modules/brace-expansion/LICENSE +23 -0
  384. package/node_modules/brace-expansion/README.md +105 -0
  385. package/node_modules/brace-expansion/dist/commonjs/index.d.ts +12 -0
  386. package/node_modules/brace-expansion/dist/commonjs/index.d.ts.map +1 -0
  387. package/node_modules/brace-expansion/dist/commonjs/index.js +333 -0
  388. package/node_modules/brace-expansion/dist/commonjs/index.js.map +1 -0
  389. package/node_modules/brace-expansion/dist/commonjs/package.json +3 -0
  390. package/node_modules/brace-expansion/dist/esm/index.d.ts +12 -0
  391. package/node_modules/brace-expansion/dist/esm/index.d.ts.map +1 -0
  392. package/node_modules/brace-expansion/dist/esm/index.js +329 -0
  393. package/node_modules/brace-expansion/dist/esm/index.js.map +1 -0
  394. package/node_modules/brace-expansion/dist/esm/package.json +3 -0
  395. package/node_modules/brace-expansion/package.json +65 -0
  396. package/node_modules/cacache/LICENSE.md +16 -0
  397. package/node_modules/cacache/README.md +715 -0
  398. package/node_modules/cacache/lib/content/path.js +29 -0
  399. package/node_modules/cacache/lib/content/read.js +165 -0
  400. package/node_modules/cacache/lib/content/rm.js +18 -0
  401. package/node_modules/cacache/lib/content/write.js +208 -0
  402. package/node_modules/cacache/lib/entry-index.js +339 -0
  403. package/node_modules/cacache/lib/get.js +170 -0
  404. package/node_modules/cacache/lib/index.js +42 -0
  405. package/node_modules/cacache/lib/memoization.js +72 -0
  406. package/node_modules/cacache/lib/put.js +80 -0
  407. package/node_modules/cacache/lib/rm.js +32 -0
  408. package/node_modules/cacache/lib/util/cache-dir.js +29 -0
  409. package/node_modules/cacache/lib/util/glob.js +7 -0
  410. package/node_modules/cacache/lib/util/hash-to-segments.js +7 -0
  411. package/node_modules/cacache/lib/util/tmp.js +36 -0
  412. package/node_modules/cacache/lib/verify.js +258 -0
  413. package/node_modules/cacache/package.json +81 -0
  414. package/node_modules/content-type/LICENSE +22 -0
  415. package/node_modules/content-type/README.md +71 -0
  416. package/node_modules/content-type/dist/index.d.ts +46 -0
  417. package/node_modules/content-type/dist/index.js +176 -0
  418. package/node_modules/content-type/dist/index.js.map +1 -0
  419. package/node_modules/content-type/package.json +52 -0
  420. package/node_modules/debug/LICENSE +20 -0
  421. package/node_modules/debug/README.md +481 -0
  422. package/node_modules/debug/package.json +64 -0
  423. package/node_modules/debug/src/browser.js +272 -0
  424. package/node_modules/debug/src/common.js +292 -0
  425. package/node_modules/debug/src/index.js +10 -0
  426. package/node_modules/debug/src/node.js +263 -0
  427. package/node_modules/fs-minipass/LICENSE +15 -0
  428. package/node_modules/fs-minipass/README.md +70 -0
  429. package/node_modules/fs-minipass/lib/index.js +443 -0
  430. package/node_modules/fs-minipass/package.json +54 -0
  431. package/node_modules/glob/LICENSE.md +63 -0
  432. package/node_modules/glob/README.md +1377 -0
  433. package/node_modules/glob/dist/commonjs/glob.d.ts +405 -0
  434. package/node_modules/glob/dist/commonjs/glob.d.ts.map +1 -0
  435. package/node_modules/glob/dist/commonjs/glob.js +241 -0
  436. package/node_modules/glob/dist/commonjs/glob.js.map +1 -0
  437. package/node_modules/glob/dist/commonjs/has-magic.d.ts +14 -0
  438. package/node_modules/glob/dist/commonjs/has-magic.d.ts.map +1 -0
  439. package/node_modules/glob/dist/commonjs/has-magic.js +24 -0
  440. package/node_modules/glob/dist/commonjs/has-magic.js.map +1 -0
  441. package/node_modules/glob/dist/commonjs/ignore.d.ts +36 -0
  442. package/node_modules/glob/dist/commonjs/ignore.d.ts.map +1 -0
  443. package/node_modules/glob/dist/commonjs/ignore.js +139 -0
  444. package/node_modules/glob/dist/commonjs/ignore.js.map +1 -0
  445. package/node_modules/glob/dist/commonjs/index.d.ts +98 -0
  446. package/node_modules/glob/dist/commonjs/index.d.ts.map +1 -0
  447. package/node_modules/glob/dist/commonjs/index.js +68 -0
  448. package/node_modules/glob/dist/commonjs/index.js.map +1 -0
  449. package/node_modules/glob/dist/commonjs/index.min.js +3 -0
  450. package/node_modules/glob/dist/commonjs/index.min.js.map +7 -0
  451. package/node_modules/glob/dist/commonjs/package.json +3 -0
  452. package/node_modules/glob/dist/commonjs/pattern.d.ts +86 -0
  453. package/node_modules/glob/dist/commonjs/pattern.d.ts.map +1 -0
  454. package/node_modules/glob/dist/commonjs/pattern.js +235 -0
  455. package/node_modules/glob/dist/commonjs/pattern.js.map +1 -0
  456. package/node_modules/glob/dist/commonjs/processor.d.ts +72 -0
  457. package/node_modules/glob/dist/commonjs/processor.d.ts.map +1 -0
  458. package/node_modules/glob/dist/commonjs/processor.js +314 -0
  459. package/node_modules/glob/dist/commonjs/processor.js.map +1 -0
  460. package/node_modules/glob/dist/commonjs/walker.d.ts +99 -0
  461. package/node_modules/glob/dist/commonjs/walker.d.ts.map +1 -0
  462. package/node_modules/glob/dist/commonjs/walker.js +402 -0
  463. package/node_modules/glob/dist/commonjs/walker.js.map +1 -0
  464. package/node_modules/glob/dist/esm/glob.d.ts +405 -0
  465. package/node_modules/glob/dist/esm/glob.d.ts.map +1 -0
  466. package/node_modules/glob/dist/esm/glob.js +237 -0
  467. package/node_modules/glob/dist/esm/glob.js.map +1 -0
  468. package/node_modules/glob/dist/esm/has-magic.d.ts +14 -0
  469. package/node_modules/glob/dist/esm/has-magic.d.ts.map +1 -0
  470. package/node_modules/glob/dist/esm/has-magic.js +20 -0
  471. package/node_modules/glob/dist/esm/has-magic.js.map +1 -0
  472. package/node_modules/glob/dist/esm/ignore.d.ts +36 -0
  473. package/node_modules/glob/dist/esm/ignore.d.ts.map +1 -0
  474. package/node_modules/glob/dist/esm/ignore.js +135 -0
  475. package/node_modules/glob/dist/esm/ignore.js.map +1 -0
  476. package/node_modules/glob/dist/esm/index.d.ts +98 -0
  477. package/node_modules/glob/dist/esm/index.d.ts.map +1 -0
  478. package/node_modules/glob/dist/esm/index.js +55 -0
  479. package/node_modules/glob/dist/esm/index.js.map +1 -0
  480. package/node_modules/glob/dist/esm/index.min.js +3 -0
  481. package/node_modules/glob/dist/esm/index.min.js.map +7 -0
  482. package/node_modules/glob/dist/esm/package.json +3 -0
  483. package/node_modules/glob/dist/esm/pattern.d.ts +86 -0
  484. package/node_modules/glob/dist/esm/pattern.d.ts.map +1 -0
  485. package/node_modules/glob/dist/esm/pattern.js +231 -0
  486. package/node_modules/glob/dist/esm/pattern.js.map +1 -0
  487. package/node_modules/glob/dist/esm/processor.d.ts +72 -0
  488. package/node_modules/glob/dist/esm/processor.d.ts.map +1 -0
  489. package/node_modules/glob/dist/esm/processor.js +307 -0
  490. package/node_modules/glob/dist/esm/processor.js.map +1 -0
  491. package/node_modules/glob/dist/esm/walker.d.ts +99 -0
  492. package/node_modules/glob/dist/esm/walker.d.ts.map +1 -0
  493. package/node_modules/glob/dist/esm/walker.js +396 -0
  494. package/node_modules/glob/dist/esm/walker.js.map +1 -0
  495. package/node_modules/glob/package.json +114 -0
  496. package/node_modules/glob/src/glob.ts +655 -0
  497. package/node_modules/glob/src/has-magic.ts +23 -0
  498. package/node_modules/glob/src/ignore.ts +162 -0
  499. package/node_modules/glob/src/index.ts +225 -0
  500. package/node_modules/glob/src/pattern.ts +286 -0
  501. package/node_modules/glob/src/processor.ts +333 -0
  502. package/node_modules/glob/src/walker.ts +523 -0
  503. package/node_modules/http-cache-semantics/LICENSE +9 -0
  504. package/node_modules/http-cache-semantics/README.md +268 -0
  505. package/node_modules/http-cache-semantics/index.js +951 -0
  506. package/node_modules/http-cache-semantics/package.json +22 -0
  507. package/node_modules/http-proxy-agent/LICENSE +22 -0
  508. package/node_modules/http-proxy-agent/README.md +44 -0
  509. package/node_modules/http-proxy-agent/dist/index.d.ts +47 -0
  510. package/node_modules/http-proxy-agent/dist/index.d.ts.map +1 -0
  511. package/node_modules/http-proxy-agent/dist/index.js +132 -0
  512. package/node_modules/http-proxy-agent/dist/index.js.map +1 -0
  513. package/node_modules/http-proxy-agent/package.json +48 -0
  514. package/node_modules/https-proxy-agent/LICENSE +22 -0
  515. package/node_modules/https-proxy-agent/README.md +70 -0
  516. package/node_modules/https-proxy-agent/dist/index.d.ts +51 -0
  517. package/node_modules/https-proxy-agent/dist/index.d.ts.map +1 -0
  518. package/node_modules/https-proxy-agent/dist/index.js +234 -0
  519. package/node_modules/https-proxy-agent/dist/index.js.map +1 -0
  520. package/node_modules/https-proxy-agent/dist/parse-proxy-response.d.ts +12 -0
  521. package/node_modules/https-proxy-agent/dist/parse-proxy-response.d.ts.map +1 -0
  522. package/node_modules/https-proxy-agent/dist/parse-proxy-response.js +94 -0
  523. package/node_modules/https-proxy-agent/dist/parse-proxy-response.js.map +1 -0
  524. package/node_modules/https-proxy-agent/package.json +51 -0
  525. package/node_modules/iconv-lite/LICENSE +21 -0
  526. package/node_modules/iconv-lite/README.md +138 -0
  527. package/node_modules/iconv-lite/encodings/dbcs-codec.js +532 -0
  528. package/node_modules/iconv-lite/encodings/dbcs-data.js +185 -0
  529. package/node_modules/iconv-lite/encodings/index.js +23 -0
  530. package/node_modules/iconv-lite/encodings/internal.js +218 -0
  531. package/node_modules/iconv-lite/encodings/sbcs-codec.js +75 -0
  532. package/node_modules/iconv-lite/encodings/sbcs-data-generated.js +451 -0
  533. package/node_modules/iconv-lite/encodings/sbcs-data.js +180 -0
  534. package/node_modules/iconv-lite/encodings/tables/big5-added.json +122 -0
  535. package/node_modules/iconv-lite/encodings/tables/cp936.json +264 -0
  536. package/node_modules/iconv-lite/encodings/tables/cp949.json +273 -0
  537. package/node_modules/iconv-lite/encodings/tables/cp950.json +177 -0
  538. package/node_modules/iconv-lite/encodings/tables/eucjp.json +182 -0
  539. package/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json +1 -0
  540. package/node_modules/iconv-lite/encodings/tables/gbk-added.json +56 -0
  541. package/node_modules/iconv-lite/encodings/tables/shiftjis.json +125 -0
  542. package/node_modules/iconv-lite/encodings/utf16.js +187 -0
  543. package/node_modules/iconv-lite/encodings/utf32.js +314 -0
  544. package/node_modules/iconv-lite/encodings/utf7.js +283 -0
  545. package/node_modules/iconv-lite/lib/bom-handling.js +48 -0
  546. package/node_modules/iconv-lite/lib/helpers/merge-exports.js +13 -0
  547. package/node_modules/iconv-lite/lib/index.d.ts +129 -0
  548. package/node_modules/iconv-lite/lib/index.js +182 -0
  549. package/node_modules/iconv-lite/lib/streams.js +105 -0
  550. package/node_modules/iconv-lite/package.json +70 -0
  551. package/node_modules/iconv-lite/types/encodings.d.ts +425 -0
  552. package/node_modules/ip-address/LICENSE +19 -0
  553. package/node_modules/ip-address/README.md +308 -0
  554. package/node_modules/ip-address/dist/address-error.d.ts +15 -0
  555. package/node_modules/ip-address/dist/address-error.js +12 -0
  556. package/node_modules/ip-address/dist/address-error.js.map +1 -0
  557. package/node_modules/ip-address/dist/common.d.ts +74 -0
  558. package/node_modules/ip-address/dist/common.js +154 -0
  559. package/node_modules/ip-address/dist/common.js.map +1 -0
  560. package/node_modules/ip-address/dist/ip-address.d.ts +7 -0
  561. package/node_modules/ip-address/dist/ip-address.js +35 -0
  562. package/node_modules/ip-address/dist/ip-address.js.map +1 -0
  563. package/node_modules/ip-address/dist/ipv4.d.ts +347 -0
  564. package/node_modules/ip-address/dist/ipv4.js +602 -0
  565. package/node_modules/ip-address/dist/ipv4.js.map +1 -0
  566. package/node_modules/ip-address/dist/ipv6.d.ts +634 -0
  567. package/node_modules/ip-address/dist/ipv6.js +1461 -0
  568. package/node_modules/ip-address/dist/ipv6.js.map +1 -0
  569. package/node_modules/ip-address/dist/v4/constants.d.ts +16 -0
  570. package/node_modules/ip-address/dist/v4/constants.js +51 -0
  571. package/node_modules/ip-address/dist/v4/constants.js.map +1 -0
  572. package/node_modules/ip-address/dist/v6/constants.d.ts +61 -0
  573. package/node_modules/ip-address/dist/v6/constants.js +131 -0
  574. package/node_modules/ip-address/dist/v6/constants.js.map +1 -0
  575. package/node_modules/ip-address/dist/v6/helpers.d.ts +18 -0
  576. package/node_modules/ip-address/dist/v6/helpers.js +54 -0
  577. package/node_modules/ip-address/dist/v6/helpers.js.map +1 -0
  578. package/node_modules/ip-address/dist/v6/regular-expressions.d.ts +5 -0
  579. package/node_modules/ip-address/dist/v6/regular-expressions.js +95 -0
  580. package/node_modules/ip-address/dist/v6/regular-expressions.js.map +1 -0
  581. package/node_modules/ip-address/package.json +91 -0
  582. package/node_modules/lru-cache/LICENSE.md +55 -0
  583. package/node_modules/lru-cache/README.md +469 -0
  584. package/node_modules/lru-cache/dist/commonjs/browser/diagnostics-channel-browser.d.ts.map +1 -0
  585. package/node_modules/lru-cache/dist/commonjs/browser/diagnostics-channel-browser.js.map +1 -0
  586. package/node_modules/lru-cache/dist/commonjs/browser/diagnostics-channel.d.ts +5 -0
  587. package/node_modules/lru-cache/dist/commonjs/browser/diagnostics-channel.js +7 -0
  588. package/node_modules/lru-cache/dist/commonjs/browser/index.d.ts +1400 -0
  589. package/node_modules/lru-cache/dist/commonjs/browser/index.d.ts.map +1 -0
  590. package/node_modules/lru-cache/dist/commonjs/browser/index.js +1733 -0
  591. package/node_modules/lru-cache/dist/commonjs/browser/index.js.map +1 -0
  592. package/node_modules/lru-cache/dist/commonjs/browser/index.min.js +2 -0
  593. package/node_modules/lru-cache/dist/commonjs/browser/index.min.js.map +7 -0
  594. package/node_modules/lru-cache/dist/commonjs/browser/perf.d.ts +12 -0
  595. package/node_modules/lru-cache/dist/commonjs/browser/perf.d.ts.map +1 -0
  596. package/node_modules/lru-cache/dist/commonjs/browser/perf.js +10 -0
  597. package/node_modules/lru-cache/dist/commonjs/browser/perf.js.map +1 -0
  598. package/node_modules/lru-cache/dist/commonjs/diagnostics-channel-cjs.cjs.map +1 -0
  599. package/node_modules/lru-cache/dist/commonjs/diagnostics-channel-cjs.d.cts.map +1 -0
  600. package/node_modules/lru-cache/dist/commonjs/diagnostics-channel.d.ts +5 -0
  601. package/node_modules/lru-cache/dist/commonjs/diagnostics-channel.js +7 -0
  602. package/node_modules/lru-cache/dist/commonjs/index.d.ts +1400 -0
  603. package/node_modules/lru-cache/dist/commonjs/index.d.ts.map +1 -0
  604. package/node_modules/lru-cache/dist/commonjs/index.js +1733 -0
  605. package/node_modules/lru-cache/dist/commonjs/index.js.map +1 -0
  606. package/node_modules/lru-cache/dist/commonjs/index.min.js +2 -0
  607. package/node_modules/lru-cache/dist/commonjs/index.min.js.map +7 -0
  608. package/node_modules/lru-cache/dist/commonjs/node/diagnostics-channel-node.d.ts.map +1 -0
  609. package/node_modules/lru-cache/dist/commonjs/node/diagnostics-channel-node.js.map +1 -0
  610. package/node_modules/lru-cache/dist/commonjs/node/diagnostics-channel.d.ts +5 -0
  611. package/node_modules/lru-cache/dist/commonjs/node/diagnostics-channel.js +9 -0
  612. package/node_modules/lru-cache/dist/commonjs/node/index.d.ts +1400 -0
  613. package/node_modules/lru-cache/dist/commonjs/node/index.d.ts.map +1 -0
  614. package/node_modules/lru-cache/dist/commonjs/node/index.js +1733 -0
  615. package/node_modules/lru-cache/dist/commonjs/node/index.js.map +1 -0
  616. package/node_modules/lru-cache/dist/commonjs/node/index.min.js +2 -0
  617. package/node_modules/lru-cache/dist/commonjs/node/index.min.js.map +7 -0
  618. package/node_modules/lru-cache/dist/commonjs/node/perf.d.ts +12 -0
  619. package/node_modules/lru-cache/dist/commonjs/node/perf.d.ts.map +1 -0
  620. package/node_modules/lru-cache/dist/commonjs/node/perf.js +10 -0
  621. package/node_modules/lru-cache/dist/commonjs/node/perf.js.map +1 -0
  622. package/node_modules/lru-cache/dist/commonjs/package.json +3 -0
  623. package/node_modules/lru-cache/dist/commonjs/perf.d.ts +12 -0
  624. package/node_modules/lru-cache/dist/commonjs/perf.d.ts.map +1 -0
  625. package/node_modules/lru-cache/dist/commonjs/perf.js +10 -0
  626. package/node_modules/lru-cache/dist/commonjs/perf.js.map +1 -0
  627. package/node_modules/lru-cache/dist/commonjs/react-native/diagnostics-channel-react-native.d.ts.map +1 -0
  628. package/node_modules/lru-cache/dist/commonjs/react-native/diagnostics-channel-react-native.js.map +1 -0
  629. package/node_modules/lru-cache/dist/commonjs/react-native/diagnostics-channel.d.ts +5 -0
  630. package/node_modules/lru-cache/dist/commonjs/react-native/diagnostics-channel.js +7 -0
  631. package/node_modules/lru-cache/dist/commonjs/react-native/index.d.ts +1400 -0
  632. package/node_modules/lru-cache/dist/commonjs/react-native/index.d.ts.map +1 -0
  633. package/node_modules/lru-cache/dist/commonjs/react-native/index.js +1733 -0
  634. package/node_modules/lru-cache/dist/commonjs/react-native/index.js.map +1 -0
  635. package/node_modules/lru-cache/dist/commonjs/react-native/perf.d.ts +12 -0
  636. package/node_modules/lru-cache/dist/commonjs/react-native/perf.d.ts.map +1 -0
  637. package/node_modules/lru-cache/dist/commonjs/react-native/perf.js +10 -0
  638. package/node_modules/lru-cache/dist/commonjs/react-native/perf.js.map +1 -0
  639. package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel-browser.d.ts.map +1 -0
  640. package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel-browser.js.map +1 -0
  641. package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel.d.ts +5 -0
  642. package/node_modules/lru-cache/dist/esm/browser/diagnostics-channel.js +4 -0
  643. package/node_modules/lru-cache/dist/esm/browser/index.d.ts +1400 -0
  644. package/node_modules/lru-cache/dist/esm/browser/index.d.ts.map +1 -0
  645. package/node_modules/lru-cache/dist/esm/browser/index.js +1729 -0
  646. package/node_modules/lru-cache/dist/esm/browser/index.js.map +1 -0
  647. package/node_modules/lru-cache/dist/esm/browser/index.min.js +2 -0
  648. package/node_modules/lru-cache/dist/esm/browser/index.min.js.map +7 -0
  649. package/node_modules/lru-cache/dist/esm/browser/perf.d.ts +12 -0
  650. package/node_modules/lru-cache/dist/esm/browser/perf.d.ts.map +1 -0
  651. package/node_modules/lru-cache/dist/esm/browser/perf.js +7 -0
  652. package/node_modules/lru-cache/dist/esm/browser/perf.js.map +1 -0
  653. package/node_modules/lru-cache/dist/esm/diagnostics-channel-esm.d.mts.map +1 -0
  654. package/node_modules/lru-cache/dist/esm/diagnostics-channel-esm.mjs.map +1 -0
  655. package/node_modules/lru-cache/dist/esm/diagnostics-channel.d.ts +5 -0
  656. package/node_modules/lru-cache/dist/esm/diagnostics-channel.js +19 -0
  657. package/node_modules/lru-cache/dist/esm/index.d.ts +1400 -0
  658. package/node_modules/lru-cache/dist/esm/index.d.ts.map +1 -0
  659. package/node_modules/lru-cache/dist/esm/index.js +1729 -0
  660. package/node_modules/lru-cache/dist/esm/index.js.map +1 -0
  661. package/node_modules/lru-cache/dist/esm/index.min.js +2 -0
  662. package/node_modules/lru-cache/dist/esm/index.min.js.map +7 -0
  663. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel-node.d.ts.map +1 -0
  664. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel-node.js.map +1 -0
  665. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel.d.ts +5 -0
  666. package/node_modules/lru-cache/dist/esm/node/diagnostics-channel.js +6 -0
  667. package/node_modules/lru-cache/dist/esm/node/index.d.ts +1400 -0
  668. package/node_modules/lru-cache/dist/esm/node/index.d.ts.map +1 -0
  669. package/node_modules/lru-cache/dist/esm/node/index.js +1729 -0
  670. package/node_modules/lru-cache/dist/esm/node/index.js.map +1 -0
  671. package/node_modules/lru-cache/dist/esm/node/index.min.js +2 -0
  672. package/node_modules/lru-cache/dist/esm/node/index.min.js.map +7 -0
  673. package/node_modules/lru-cache/dist/esm/node/perf.d.ts +12 -0
  674. package/node_modules/lru-cache/dist/esm/node/perf.d.ts.map +1 -0
  675. package/node_modules/lru-cache/dist/esm/node/perf.js +7 -0
  676. package/node_modules/lru-cache/dist/esm/node/perf.js.map +1 -0
  677. package/node_modules/lru-cache/dist/esm/package.json +3 -0
  678. package/node_modules/lru-cache/dist/esm/perf.d.ts +12 -0
  679. package/node_modules/lru-cache/dist/esm/perf.d.ts.map +1 -0
  680. package/node_modules/lru-cache/dist/esm/perf.js +7 -0
  681. package/node_modules/lru-cache/dist/esm/perf.js.map +1 -0
  682. package/node_modules/lru-cache/dist/esm/react-native/diagnostics-channel-react-native.d.ts.map +1 -0
  683. package/node_modules/lru-cache/dist/esm/react-native/diagnostics-channel-react-native.js.map +1 -0
  684. package/node_modules/lru-cache/dist/esm/react-native/diagnostics-channel.d.ts +5 -0
  685. package/node_modules/lru-cache/dist/esm/react-native/diagnostics-channel.js +4 -0
  686. package/node_modules/lru-cache/dist/esm/react-native/index.d.ts +1400 -0
  687. package/node_modules/lru-cache/dist/esm/react-native/index.d.ts.map +1 -0
  688. package/node_modules/lru-cache/dist/esm/react-native/index.js +1729 -0
  689. package/node_modules/lru-cache/dist/esm/react-native/index.js.map +1 -0
  690. package/node_modules/lru-cache/dist/esm/react-native/perf.d.ts +12 -0
  691. package/node_modules/lru-cache/dist/esm/react-native/perf.d.ts.map +1 -0
  692. package/node_modules/lru-cache/dist/esm/react-native/perf.js +7 -0
  693. package/node_modules/lru-cache/dist/esm/react-native/perf.js.map +1 -0
  694. package/node_modules/lru-cache/package.json +180 -0
  695. package/node_modules/make-fetch-happen/LICENSE +16 -0
  696. package/node_modules/make-fetch-happen/README.md +364 -0
  697. package/node_modules/make-fetch-happen/lib/cache/entry.js +471 -0
  698. package/node_modules/make-fetch-happen/lib/cache/errors.js +11 -0
  699. package/node_modules/make-fetch-happen/lib/cache/index.js +49 -0
  700. package/node_modules/make-fetch-happen/lib/cache/key.js +17 -0
  701. package/node_modules/make-fetch-happen/lib/cache/policy.js +161 -0
  702. package/node_modules/make-fetch-happen/lib/fetch.js +118 -0
  703. package/node_modules/make-fetch-happen/lib/index.js +41 -0
  704. package/node_modules/make-fetch-happen/lib/options.js +59 -0
  705. package/node_modules/make-fetch-happen/lib/pipeline.js +41 -0
  706. package/node_modules/make-fetch-happen/lib/remote.js +134 -0
  707. package/node_modules/make-fetch-happen/package.json +75 -0
  708. package/node_modules/minimatch/LICENSE.md +55 -0
  709. package/node_modules/minimatch/README.md +556 -0
  710. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.d.ts +2 -0
  711. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.d.ts.map +1 -0
  712. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js +14 -0
  713. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js.map +1 -0
  714. package/node_modules/minimatch/dist/commonjs/escape.d.ts +15 -0
  715. package/node_modules/minimatch/dist/commonjs/escape.d.ts.map +1 -0
  716. package/node_modules/minimatch/dist/commonjs/escape.js +30 -0
  717. package/node_modules/minimatch/dist/commonjs/escape.js.map +1 -0
  718. package/node_modules/minimatch/dist/commonjs/index.d.ts +188 -0
  719. package/node_modules/minimatch/dist/commonjs/index.d.ts.map +1 -0
  720. package/node_modules/minimatch/dist/commonjs/index.js +1600 -0
  721. package/node_modules/minimatch/dist/commonjs/index.js.map +1 -0
  722. package/node_modules/minimatch/dist/commonjs/package.json +3 -0
  723. package/node_modules/minimatch/dist/commonjs/unescape.d.ts +22 -0
  724. package/node_modules/minimatch/dist/commonjs/unescape.d.ts.map +1 -0
  725. package/node_modules/minimatch/dist/commonjs/unescape.js +38 -0
  726. package/node_modules/minimatch/dist/commonjs/unescape.js.map +1 -0
  727. package/node_modules/minimatch/dist/esm/assert-valid-pattern.d.ts +2 -0
  728. package/node_modules/minimatch/dist/esm/assert-valid-pattern.d.ts.map +1 -0
  729. package/node_modules/minimatch/dist/esm/assert-valid-pattern.js +10 -0
  730. package/node_modules/minimatch/dist/esm/assert-valid-pattern.js.map +1 -0
  731. package/node_modules/minimatch/dist/esm/escape.d.ts +15 -0
  732. package/node_modules/minimatch/dist/esm/escape.d.ts.map +1 -0
  733. package/node_modules/minimatch/dist/esm/escape.js +26 -0
  734. package/node_modules/minimatch/dist/esm/escape.js.map +1 -0
  735. package/node_modules/minimatch/dist/esm/index.d.ts +188 -0
  736. package/node_modules/minimatch/dist/esm/index.d.ts.map +1 -0
  737. package/node_modules/minimatch/dist/esm/index.js +1589 -0
  738. package/node_modules/minimatch/dist/esm/index.js.map +1 -0
  739. package/node_modules/minimatch/dist/esm/package.json +3 -0
  740. package/node_modules/minimatch/dist/esm/unescape.d.ts +22 -0
  741. package/node_modules/minimatch/dist/esm/unescape.d.ts.map +1 -0
  742. package/node_modules/minimatch/dist/esm/unescape.js +34 -0
  743. package/node_modules/minimatch/dist/esm/unescape.js.map +1 -0
  744. package/node_modules/minimatch/package.json +74 -0
  745. package/node_modules/minipass/LICENSE.md +55 -0
  746. package/node_modules/minipass/README.md +825 -0
  747. package/node_modules/minipass/dist/commonjs/index.d.ts +545 -0
  748. package/node_modules/minipass/dist/commonjs/index.d.ts.map +1 -0
  749. package/node_modules/minipass/dist/commonjs/index.js +1038 -0
  750. package/node_modules/minipass/dist/commonjs/index.js.map +1 -0
  751. package/node_modules/minipass/dist/commonjs/package.json +3 -0
  752. package/node_modules/minipass/dist/esm/index.d.ts +545 -0
  753. package/node_modules/minipass/dist/esm/index.d.ts.map +1 -0
  754. package/node_modules/minipass/dist/esm/index.js +1020 -0
  755. package/node_modules/minipass/dist/esm/index.js.map +1 -0
  756. package/node_modules/minipass/dist/esm/package.json +3 -0
  757. package/node_modules/minipass/package.json +77 -0
  758. package/node_modules/minipass-collect/LICENSE +15 -0
  759. package/node_modules/minipass-collect/README.md +48 -0
  760. package/node_modules/minipass-collect/index.js +71 -0
  761. package/node_modules/minipass-collect/package.json +30 -0
  762. package/node_modules/minipass-fetch/LICENSE +28 -0
  763. package/node_modules/minipass-fetch/README.md +29 -0
  764. package/node_modules/minipass-fetch/lib/abort-error.js +17 -0
  765. package/node_modules/minipass-fetch/lib/blob.js +97 -0
  766. package/node_modules/minipass-fetch/lib/body.js +360 -0
  767. package/node_modules/minipass-fetch/lib/fetch-error.js +32 -0
  768. package/node_modules/minipass-fetch/lib/headers.js +267 -0
  769. package/node_modules/minipass-fetch/lib/index.js +376 -0
  770. package/node_modules/minipass-fetch/lib/request.js +282 -0
  771. package/node_modules/minipass-fetch/lib/response.js +90 -0
  772. package/node_modules/minipass-fetch/package.json +70 -0
  773. package/node_modules/minipass-flush/LICENSE.md +55 -0
  774. package/node_modules/minipass-flush/README.md +47 -0
  775. package/node_modules/minipass-flush/index.js +39 -0
  776. package/node_modules/minipass-flush/node_modules/minipass/LICENSE +15 -0
  777. package/node_modules/minipass-flush/node_modules/minipass/README.md +728 -0
  778. package/node_modules/minipass-flush/node_modules/minipass/index.d.ts +155 -0
  779. package/node_modules/minipass-flush/node_modules/minipass/index.js +649 -0
  780. package/node_modules/minipass-flush/node_modules/minipass/package.json +56 -0
  781. package/node_modules/minipass-flush/package.json +42 -0
  782. package/node_modules/minipass-pipeline/LICENSE +15 -0
  783. package/node_modules/minipass-pipeline/README.md +69 -0
  784. package/node_modules/minipass-pipeline/index.js +128 -0
  785. package/node_modules/minipass-pipeline/node_modules/minipass/LICENSE +15 -0
  786. package/node_modules/minipass-pipeline/node_modules/minipass/README.md +728 -0
  787. package/node_modules/minipass-pipeline/node_modules/minipass/index.d.ts +155 -0
  788. package/node_modules/minipass-pipeline/node_modules/minipass/index.js +649 -0
  789. package/node_modules/minipass-pipeline/node_modules/minipass/package.json +56 -0
  790. package/node_modules/minipass-pipeline/package.json +29 -0
  791. package/node_modules/minipass-sized/LICENSE +15 -0
  792. package/node_modules/minipass-sized/README.md +30 -0
  793. package/node_modules/minipass-sized/dist/commonjs/index.d.ts +21 -0
  794. package/node_modules/minipass-sized/dist/commonjs/index.d.ts.map +1 -0
  795. package/node_modules/minipass-sized/dist/commonjs/index.js +69 -0
  796. package/node_modules/minipass-sized/dist/commonjs/index.js.map +1 -0
  797. package/node_modules/minipass-sized/dist/commonjs/package.json +3 -0
  798. package/node_modules/minipass-sized/dist/esm/index.d.ts +21 -0
  799. package/node_modules/minipass-sized/dist/esm/index.d.ts.map +1 -0
  800. package/node_modules/minipass-sized/dist/esm/index.js +64 -0
  801. package/node_modules/minipass-sized/dist/esm/index.js.map +1 -0
  802. package/node_modules/minipass-sized/dist/esm/package.json +3 -0
  803. package/node_modules/minipass-sized/package.json +69 -0
  804. package/node_modules/minizlib/LICENSE +26 -0
  805. package/node_modules/minizlib/README.md +64 -0
  806. package/node_modules/minizlib/dist/commonjs/constants.d.ts +2 -0
  807. package/node_modules/minizlib/dist/commonjs/constants.d.ts.map +1 -0
  808. package/node_modules/minizlib/dist/commonjs/constants.js +123 -0
  809. package/node_modules/minizlib/dist/commonjs/constants.js.map +1 -0
  810. package/node_modules/minizlib/dist/commonjs/index.d.ts +99 -0
  811. package/node_modules/minizlib/dist/commonjs/index.d.ts.map +1 -0
  812. package/node_modules/minizlib/dist/commonjs/index.js +416 -0
  813. package/node_modules/minizlib/dist/commonjs/index.js.map +1 -0
  814. package/node_modules/minizlib/dist/commonjs/package.json +3 -0
  815. package/node_modules/minizlib/dist/esm/constants.d.ts +2 -0
  816. package/node_modules/minizlib/dist/esm/constants.d.ts.map +1 -0
  817. package/node_modules/minizlib/dist/esm/constants.js +117 -0
  818. package/node_modules/minizlib/dist/esm/constants.js.map +1 -0
  819. package/node_modules/minizlib/dist/esm/index.d.ts +99 -0
  820. package/node_modules/minizlib/dist/esm/index.d.ts.map +1 -0
  821. package/node_modules/minizlib/dist/esm/index.js +363 -0
  822. package/node_modules/minizlib/dist/esm/index.js.map +1 -0
  823. package/node_modules/minizlib/dist/esm/package.json +3 -0
  824. package/node_modules/minizlib/package.json +80 -0
  825. package/node_modules/ms/index.js +162 -0
  826. package/node_modules/ms/license.md +21 -0
  827. package/node_modules/ms/package.json +38 -0
  828. package/node_modules/ms/readme.md +59 -0
  829. package/node_modules/negotiator/LICENSE +24 -0
  830. package/node_modules/negotiator/README.md +212 -0
  831. package/node_modules/negotiator/index.js +83 -0
  832. package/node_modules/negotiator/lib/accept.js +54 -0
  833. package/node_modules/negotiator/lib/charset.js +145 -0
  834. package/node_modules/negotiator/lib/encoding.js +184 -0
  835. package/node_modules/negotiator/lib/language.js +158 -0
  836. package/node_modules/negotiator/lib/mediaType.js +176 -0
  837. package/node_modules/negotiator/package.json +49 -0
  838. package/node_modules/p-map/index.d.ts +392 -0
  839. package/node_modules/p-map/index.js +663 -0
  840. package/node_modules/p-map/license +9 -0
  841. package/node_modules/p-map/package.json +57 -0
  842. package/node_modules/p-map/readme.md +404 -0
  843. package/node_modules/path-scurry/LICENSE.md +55 -0
  844. package/node_modules/path-scurry/README.md +635 -0
  845. package/node_modules/path-scurry/dist/commonjs/index.d.ts +1122 -0
  846. package/node_modules/path-scurry/dist/commonjs/index.d.ts.map +1 -0
  847. package/node_modules/path-scurry/dist/commonjs/index.js +2056 -0
  848. package/node_modules/path-scurry/dist/commonjs/index.js.map +1 -0
  849. package/node_modules/path-scurry/dist/commonjs/package.json +3 -0
  850. package/node_modules/path-scurry/dist/esm/index.d.ts +1122 -0
  851. package/node_modules/path-scurry/dist/esm/index.d.ts.map +1 -0
  852. package/node_modules/path-scurry/dist/esm/index.js +2011 -0
  853. package/node_modules/path-scurry/dist/esm/index.js.map +1 -0
  854. package/node_modules/path-scurry/dist/esm/package.json +3 -0
  855. package/node_modules/path-scurry/package.json +72 -0
  856. package/node_modules/proc-log/LICENSE +15 -0
  857. package/node_modules/proc-log/README.md +226 -0
  858. package/node_modules/proc-log/lib/index.js +158 -0
  859. package/node_modules/proc-log/package.json +46 -0
  860. package/node_modules/proxy-agent-negotiate/dist/index.d.ts +14 -0
  861. package/node_modules/proxy-agent-negotiate/dist/index.d.ts.map +1 -0
  862. package/node_modules/proxy-agent-negotiate/dist/index.js +35 -0
  863. package/node_modules/proxy-agent-negotiate/dist/index.js.map +1 -0
  864. package/node_modules/proxy-agent-negotiate/package.json +47 -0
  865. package/node_modules/safer-buffer/LICENSE +21 -0
  866. package/node_modules/safer-buffer/Porting-Buffer.md +268 -0
  867. package/node_modules/safer-buffer/Readme.md +156 -0
  868. package/node_modules/safer-buffer/dangerous.js +58 -0
  869. package/node_modules/safer-buffer/package.json +34 -0
  870. package/node_modules/safer-buffer/safer.js +77 -0
  871. package/node_modules/safer-buffer/tests.js +406 -0
  872. package/node_modules/semver/LICENSE +15 -0
  873. package/node_modules/semver/README.md +680 -0
  874. package/node_modules/semver/bin/semver.js +195 -0
  875. package/node_modules/semver/classes/comparator.js +143 -0
  876. package/node_modules/semver/classes/index.js +7 -0
  877. package/node_modules/semver/classes/range.js +577 -0
  878. package/node_modules/semver/classes/semver.js +350 -0
  879. package/node_modules/semver/functions/clean.js +8 -0
  880. package/node_modules/semver/functions/cmp.js +54 -0
  881. package/node_modules/semver/functions/coerce.js +62 -0
  882. package/node_modules/semver/functions/compare-build.js +9 -0
  883. package/node_modules/semver/functions/compare-loose.js +5 -0
  884. package/node_modules/semver/functions/compare.js +7 -0
  885. package/node_modules/semver/functions/diff.js +60 -0
  886. package/node_modules/semver/functions/eq.js +5 -0
  887. package/node_modules/semver/functions/gt.js +5 -0
  888. package/node_modules/semver/functions/gte.js +5 -0
  889. package/node_modules/semver/functions/inc.js +21 -0
  890. package/node_modules/semver/functions/lt.js +5 -0
  891. package/node_modules/semver/functions/lte.js +5 -0
  892. package/node_modules/semver/functions/major.js +5 -0
  893. package/node_modules/semver/functions/minor.js +5 -0
  894. package/node_modules/semver/functions/neq.js +5 -0
  895. package/node_modules/semver/functions/parse.js +18 -0
  896. package/node_modules/semver/functions/patch.js +5 -0
  897. package/node_modules/semver/functions/prerelease.js +8 -0
  898. package/node_modules/semver/functions/rcompare.js +5 -0
  899. package/node_modules/semver/functions/rsort.js +5 -0
  900. package/node_modules/semver/functions/satisfies.js +12 -0
  901. package/node_modules/semver/functions/sort.js +5 -0
  902. package/node_modules/semver/functions/truncate.js +48 -0
  903. package/node_modules/semver/functions/valid.js +8 -0
  904. package/node_modules/semver/index.js +93 -0
  905. package/node_modules/semver/internal/constants.js +67 -0
  906. package/node_modules/semver/internal/debug.js +11 -0
  907. package/node_modules/semver/internal/identifiers.js +29 -0
  908. package/node_modules/semver/internal/lrucache.js +42 -0
  909. package/node_modules/semver/internal/parse-options.js +17 -0
  910. package/node_modules/semver/internal/re.js +223 -0
  911. package/node_modules/semver/internal/trim-comparator-whitespace.js +438 -0
  912. package/node_modules/semver/package.json +78 -0
  913. package/node_modules/semver/preload.js +4 -0
  914. package/node_modules/semver/range.bnf +17 -0
  915. package/node_modules/semver/ranges/gtr.js +6 -0
  916. package/node_modules/semver/ranges/intersects.js +9 -0
  917. package/node_modules/semver/ranges/ltr.js +6 -0
  918. package/node_modules/semver/ranges/max-satisfying.js +27 -0
  919. package/node_modules/semver/ranges/min-satisfying.js +26 -0
  920. package/node_modules/semver/ranges/min-version.js +63 -0
  921. package/node_modules/semver/ranges/outside.js +82 -0
  922. package/node_modules/semver/ranges/simplify.js +49 -0
  923. package/node_modules/semver/ranges/subset.js +249 -0
  924. package/node_modules/semver/ranges/to-comparators.js +10 -0
  925. package/node_modules/semver/ranges/valid.js +13 -0
  926. package/node_modules/sigstore/LICENSE +202 -0
  927. package/node_modules/sigstore/README.md +219 -0
  928. package/node_modules/sigstore/dist/config.d.ts +38 -0
  929. package/node_modules/sigstore/dist/config.js +126 -0
  930. package/node_modules/sigstore/dist/index.d.ts +9 -0
  931. package/node_modules/sigstore/dist/index.js +34 -0
  932. package/node_modules/sigstore/dist/sigstore.d.ts +11 -0
  933. package/node_modules/sigstore/dist/sigstore.js +112 -0
  934. package/node_modules/sigstore/package.json +47 -0
  935. package/node_modules/smart-buffer/.prettierrc.yaml +5 -0
  936. package/node_modules/smart-buffer/.travis.yml +13 -0
  937. package/node_modules/smart-buffer/LICENSE +20 -0
  938. package/node_modules/smart-buffer/README.md +633 -0
  939. package/node_modules/smart-buffer/build/smartbuffer.js +1233 -0
  940. package/node_modules/smart-buffer/build/smartbuffer.js.map +1 -0
  941. package/node_modules/smart-buffer/build/utils.js +108 -0
  942. package/node_modules/smart-buffer/build/utils.js.map +1 -0
  943. package/node_modules/smart-buffer/docs/CHANGELOG.md +70 -0
  944. package/node_modules/smart-buffer/docs/README_v3.md +367 -0
  945. package/node_modules/smart-buffer/docs/ROADMAP.md +0 -0
  946. package/node_modules/smart-buffer/package.json +79 -0
  947. package/node_modules/smart-buffer/typings/smartbuffer.d.ts +755 -0
  948. package/node_modules/smart-buffer/typings/utils.d.ts +66 -0
  949. package/node_modules/socks/.prettierrc.yaml +7 -0
  950. package/node_modules/socks/LICENSE +20 -0
  951. package/node_modules/socks/README.md +686 -0
  952. package/node_modules/socks/build/client/socksclient.js +793 -0
  953. package/node_modules/socks/build/client/socksclient.js.map +1 -0
  954. package/node_modules/socks/build/common/constants.js +108 -0
  955. package/node_modules/socks/build/common/constants.js.map +1 -0
  956. package/node_modules/socks/build/common/helpers.js +166 -0
  957. package/node_modules/socks/build/common/helpers.js.map +1 -0
  958. package/node_modules/socks/build/common/receivebuffer.js +43 -0
  959. package/node_modules/socks/build/common/receivebuffer.js.map +1 -0
  960. package/node_modules/socks/build/common/util.js +25 -0
  961. package/node_modules/socks/build/common/util.js.map +1 -0
  962. package/node_modules/socks/build/index.js +18 -0
  963. package/node_modules/socks/build/index.js.map +1 -0
  964. package/node_modules/socks/docs/examples/index.md +17 -0
  965. package/node_modules/socks/docs/examples/javascript/associateExample.md +90 -0
  966. package/node_modules/socks/docs/examples/javascript/bindExample.md +83 -0
  967. package/node_modules/socks/docs/examples/javascript/connectExample.md +258 -0
  968. package/node_modules/socks/docs/examples/typescript/associateExample.md +93 -0
  969. package/node_modules/socks/docs/examples/typescript/bindExample.md +86 -0
  970. package/node_modules/socks/docs/examples/typescript/connectExample.md +265 -0
  971. package/node_modules/socks/docs/index.md +5 -0
  972. package/node_modules/socks/docs/migratingFromV1.md +86 -0
  973. package/node_modules/socks/package.json +58 -0
  974. package/node_modules/socks/typings/client/socksclient.d.ts +162 -0
  975. package/node_modules/socks/typings/common/constants.d.ts +151 -0
  976. package/node_modules/socks/typings/common/helpers.d.ts +17 -0
  977. package/node_modules/socks/typings/common/receiveBuffer.d.ts +12 -0
  978. package/node_modules/socks/typings/common/util.d.ts +14 -0
  979. package/node_modules/socks/typings/index.d.ts +1 -0
  980. package/node_modules/socks-proxy-agent/LICENSE +22 -0
  981. package/node_modules/socks-proxy-agent/README.md +50 -0
  982. package/node_modules/socks-proxy-agent/dist/index.d.ts +25 -0
  983. package/node_modules/socks-proxy-agent/dist/index.d.ts.map +1 -0
  984. package/node_modules/socks-proxy-agent/dist/index.js +169 -0
  985. package/node_modules/socks-proxy-agent/dist/index.js.map +1 -0
  986. package/node_modules/socks-proxy-agent/package.json +142 -0
  987. package/node_modules/ssri/LICENSE.md +16 -0
  988. package/node_modules/ssri/README.md +528 -0
  989. package/node_modules/ssri/lib/index.js +550 -0
  990. package/node_modules/ssri/package.json +66 -0
  991. package/node_modules/tuf-js/LICENSE +21 -0
  992. package/node_modules/tuf-js/README.md +3 -0
  993. package/node_modules/tuf-js/dist/config.d.ts +15 -0
  994. package/node_modules/tuf-js/dist/config.js +16 -0
  995. package/node_modules/tuf-js/dist/error.d.ts +22 -0
  996. package/node_modules/tuf-js/dist/error.js +49 -0
  997. package/node_modules/tuf-js/dist/fetcher.d.ts +25 -0
  998. package/node_modules/tuf-js/dist/fetcher.js +131 -0
  999. package/node_modules/tuf-js/dist/index.d.ts +6 -0
  1000. package/node_modules/tuf-js/dist/index.js +9 -0
  1001. package/node_modules/tuf-js/dist/store.d.ts +18 -0
  1002. package/node_modules/tuf-js/dist/store.js +219 -0
  1003. package/node_modules/tuf-js/dist/updater.d.ts +35 -0
  1004. package/node_modules/tuf-js/dist/updater.js +379 -0
  1005. package/node_modules/tuf-js/dist/utils/tmpfile.d.ts +3 -0
  1006. package/node_modules/tuf-js/dist/utils/tmpfile.js +25 -0
  1007. package/node_modules/tuf-js/dist/utils/url.d.ts +1 -0
  1008. package/node_modules/tuf-js/dist/utils/url.js +13 -0
  1009. package/node_modules/tuf-js/package.json +43 -0
  1010. package/node_modules/yallist/LICENSE +15 -0
  1011. package/node_modules/yallist/README.md +204 -0
  1012. package/node_modules/yallist/iterator.js +8 -0
  1013. package/node_modules/yallist/package.json +29 -0
  1014. package/node_modules/yallist/yallist.js +426 -0
  1015. package/npm-shrinkwrap.json +771 -0
  1016. package/package.json +56 -2
  1017. package/place_the_release/place_the_release.mjs +132 -0
  1018. package/read_the_release_registry/read_the_release_registry.mjs +255 -0
  1019. package/refuse_in_words/refuse_in_words.mjs +31 -0
  1020. package/signers.txt +11 -0
  1021. package/unpack_the_release_layer/unpack_the_release_layer.mjs +286 -0
  1022. package/verify_the_release_signature/verify_the_release_signature.mjs +174 -0
@@ -0,0 +1,1600 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.unescape = exports.escape = exports.Minimatch = exports.match = exports.braceExpand = exports.defaults = exports.filter = exports.GLOBSTAR = exports.sep = exports.minimatch = void 0;
4
+ const brace_expansion_1 = require("brace-expansion");
5
+ const nonrecursive_glob_match_1 = require("@isaacs/nonrecursive-glob-match");
6
+ const assert_valid_pattern_js_1 = require("./assert-valid-pattern.js");
7
+ const escape_js_1 = require("./escape.js");
8
+ const unescape_js_1 = require("./unescape.js");
9
+ const minimatch = (p, pattern, options = {}) => {
10
+ (0, assert_valid_pattern_js_1.assertValidPattern)(pattern);
11
+ // shortcut: comments match nothing.
12
+ if (!options.nocomment && pattern.charAt(0) === '#') {
13
+ return false;
14
+ }
15
+ return cachedMinimatch(pattern, options).match(p);
16
+ };
17
+ exports.minimatch = minimatch;
18
+ // The Minimatch objects that minimatch() used most recently. A Map
19
+ // keeps its keys in the order they were set, so the first key is the
20
+ // one used least recently.
21
+ const cache = new Map();
22
+ const cacheMax = 256;
23
+ const cachedMinimatch = (pattern, options) => {
24
+ const key = pattern + '\0' + JSON.stringify(options);
25
+ let mm = cache.get(key);
26
+ if (mm) {
27
+ cache.delete(key);
28
+ }
29
+ else {
30
+ // a copy, so a later change to the options can not change it
31
+ mm = new Minimatch(pattern, { ...options });
32
+ if (cache.size >= cacheMax) {
33
+ cache.delete(cache.keys().next().value);
34
+ }
35
+ }
36
+ cache.set(key, mm);
37
+ return mm;
38
+ };
39
+ /* c8 ignore start */
40
+ const defaultPlatform = (typeof process === 'object' && process ?
41
+ process.env?.__MINIMATCH_TESTING_PLATFORM__ || process.platform
42
+ : 'posix');
43
+ const path = {
44
+ win32: { sep: '\\' },
45
+ posix: { sep: '/' },
46
+ };
47
+ /* c8 ignore stop */
48
+ exports.sep = defaultPlatform === 'win32' ? path.win32.sep : path.posix.sep;
49
+ exports.minimatch.sep = exports.sep;
50
+ exports.GLOBSTAR = Symbol('globstar **');
51
+ exports.minimatch.GLOBSTAR = exports.GLOBSTAR;
52
+ const filter = (pattern, options = {}) => (p) => (0, exports.minimatch)(p, pattern, options);
53
+ exports.filter = filter;
54
+ exports.minimatch.filter = exports.filter;
55
+ const ext = (a, b = {}) => Object.assign({}, a, b);
56
+ const defaults = (def) => {
57
+ if (!def || typeof def !== 'object' || !Object.keys(def).length) {
58
+ return exports.minimatch;
59
+ }
60
+ const orig = exports.minimatch;
61
+ const m = (p, pattern, options = {}) => orig(p, pattern, ext(def, options));
62
+ return Object.assign(m, {
63
+ Minimatch: class Minimatch extends orig.Minimatch {
64
+ constructor(pattern, options = {}) {
65
+ super(pattern, ext(def, options));
66
+ }
67
+ static defaults(options) {
68
+ return orig.defaults(ext(def, options)).Minimatch;
69
+ }
70
+ },
71
+ unescape: (s, options = {}) => orig.unescape(s, ext(def, options)),
72
+ escape: (s, options = {}) => orig.escape(s, ext(def, options)),
73
+ filter: (pattern, options = {}) => orig.filter(pattern, ext(def, options)),
74
+ defaults: (options) => orig.defaults(ext(def, options)),
75
+ braceExpand: (pattern, options = {}) => orig.braceExpand(pattern, ext(def, options)),
76
+ match: (list, pattern, options = {}) => orig.match(list, pattern, ext(def, options)),
77
+ sep: orig.sep,
78
+ GLOBSTAR: exports.GLOBSTAR,
79
+ });
80
+ };
81
+ exports.defaults = defaults;
82
+ exports.minimatch.defaults = exports.defaults;
83
+ // Brace expansion:
84
+ // a{b,c}d -> abd acd
85
+ // a{b,}c -> abc ac
86
+ // a{0..3}d -> a0d a1d a2d a3d
87
+ // a{b,c{d,e}f}g -> abg acdfg acefg
88
+ // a{b,c}d{e,f}g -> abdeg acdeg abdeg abdfg
89
+ //
90
+ // Invalid sets are not expanded.
91
+ // a{2..}b -> a{2..}b
92
+ // a{b}c -> a{b}c
93
+ const braceExpand = (pattern, options = {}) => {
94
+ (0, assert_valid_pattern_js_1.assertValidPattern)(pattern);
95
+ // Thanks to Yeting Li <https://github.com/yetingli> for
96
+ // improving this regexp to avoid a ReDOS vulnerability.
97
+ if (options.nobrace || !/\{(?:(?!\{).)*\}/.test(pattern)) {
98
+ // shortcut. no need to expand.
99
+ return [pattern];
100
+ }
101
+ return (0, brace_expansion_1.expand)(pattern, { max: options.braceExpandMax });
102
+ };
103
+ exports.braceExpand = braceExpand;
104
+ exports.minimatch.braceExpand = exports.braceExpand;
105
+ // A numeric range with at least this many values is matched as one
106
+ // pattern portion, rather than expanded. For a glob walk, that is
107
+ // one directory read, in place of a stat for each value.
108
+ const RANGE_MIN = 100;
109
+ // a {lo..hi} range that is not escaped, and not a ${...} variable
110
+ const rangeRe = /(?<![\\$])\{(-?\d+)\.\.(-?\d+)\}/g;
111
+ const match = (list, pattern, options = {}) => {
112
+ const mm = new Minimatch(pattern, options);
113
+ list = list.filter(f => mm.match(f));
114
+ if (mm.options.nonull && !list.length) {
115
+ list.push(pattern);
116
+ }
117
+ return list;
118
+ };
119
+ exports.match = match;
120
+ exports.minimatch.match = exports.match;
121
+ const globMagic = /[?*]|[+@!]\(.*?\)|\[|\]/;
122
+ // Index of the `]` that closes the class that starts at `start`,
123
+ // or -1 if it is not closed. Posix classes such as `[:alpha:]` are
124
+ // not skipped, so this can find a `]` before the real end. That
125
+ // only makes a class look less like a literal.
126
+ const classEnd = (pattern, start) => {
127
+ let i = start + 1;
128
+ if (pattern.charAt(i) === '!' || pattern.charAt(i) === '^')
129
+ i++;
130
+ let sawStart = false;
131
+ for (; i < pattern.length; i++) {
132
+ const c = pattern.charAt(i);
133
+ if (c === ']' && sawStart)
134
+ return i;
135
+ sawStart = true;
136
+ if (c === '\\')
137
+ i++;
138
+ }
139
+ return -1;
140
+ };
141
+ // If a path portion pattern has no magic, return the string it
142
+ // matches. Otherwise, return undefined. This can report magic for
143
+ // a pattern that is in fact literal (eg, `[]`), but never the
144
+ // reverse, so a string result is always safe to compare directly.
145
+ const literal = (pattern, noext) => {
146
+ if (!noext && (pattern === '+()' || pattern === '@()'))
147
+ return pattern;
148
+ let lit = '';
149
+ for (let i = 0; i < pattern.length; i++) {
150
+ const c = pattern.charAt(i);
151
+ if (c === '\\') {
152
+ // a trailing \ is a literal \
153
+ lit += pattern.charAt(++i) || c;
154
+ }
155
+ else if (c === '*' || c === '?') {
156
+ return undefined;
157
+ }
158
+ else if (c === '[') {
159
+ const close = classEnd(pattern, i);
160
+ if (close === -1) {
161
+ // not closed, so the [ is a literal
162
+ lit += c;
163
+ continue;
164
+ }
165
+ // a class of one char, such as `[*]` or `[\b]`, is a literal
166
+ let body = pattern.slice(i + 1, close);
167
+ if (body.startsWith('\\'))
168
+ body = body.slice(1);
169
+ if ([...body].length !== 1 || '!^'.includes(pattern.charAt(i + 1))) {
170
+ return undefined;
171
+ }
172
+ lit += body;
173
+ i = close;
174
+ }
175
+ else if (!noext &&
176
+ '+@!'.includes(c) &&
177
+ pattern.charAt(i + 1) === '(' &&
178
+ pattern.includes(')', i + 2)) {
179
+ return undefined;
180
+ }
181
+ else {
182
+ lit += c;
183
+ }
184
+ }
185
+ return lit;
186
+ };
187
+ // True if the portion pattern has the same meaning as an alternative
188
+ // inside `@(...)`. It must not have a `|` or `)` that is not in a
189
+ // closed extglob (those are literal at the top level), an extglob
190
+ // that is not closed (the `)` of the `@(...)` would close it), or a
191
+ // trailing `\` (it would escape the next `|`). A pattern that is
192
+ // only an empty extglob, such as `?()`, is literal on its own, but
193
+ // not in `@(...)`. Posix classes such as `[:alpha:]` can hide a `]`
194
+ // from classEnd, so patterns with them are not merged.
195
+ const extSafe = (pattern) => {
196
+ if (/^[?*+@]\(\)$/.test(pattern) || pattern.includes('[:'))
197
+ return false;
198
+ let depth = 0;
199
+ for (let i = 0; i < pattern.length; i++) {
200
+ const c = pattern.charAt(i);
201
+ if (c === '\\') {
202
+ if (++i === pattern.length)
203
+ return false;
204
+ }
205
+ else if (c === '[') {
206
+ const close = classEnd(pattern, i);
207
+ if (close !== -1)
208
+ i = close;
209
+ }
210
+ else if ('+@!?*'.includes(c) && pattern.charAt(i + 1) === '(') {
211
+ depth++;
212
+ i++;
213
+ }
214
+ else if (c === ')') {
215
+ if (!depth--)
216
+ return false;
217
+ }
218
+ else if (c === '|' && !depth) {
219
+ return false;
220
+ }
221
+ }
222
+ return !depth;
223
+ };
224
+ // The last path that Minimatch#match split, and its parts. A path is
225
+ // often tested against many patterns in a row (such as a list of
226
+ // ignore patterns), so this saves splitting it again. The parts are
227
+ // never changed, so they can be shared.
228
+ let lastSplit;
229
+ // The last path that Minimatch#match checked before splitting it. If
230
+ // the same path is checked again, it is being tested against many
231
+ // patterns, so it is split and the parts are kept for the others.
232
+ let lastChecked;
233
+ // true if a pattern portion that is not ** matches a path portion.
234
+ // An empty path portion only matches an empty pattern portion. A path
235
+ // portion never has a `/`, so the Matcher does not need to check it.
236
+ const portionMatch = (p, f) => typeof p === 'string' ? f === p : f !== '' && p.testUnchecked(f);
237
+ // Where the last portion of a row matches in a path: the start of the
238
+ // last portion of the path, or of the one before a trailing `/`. -1 if
239
+ // it matches neither.
240
+ const endIndex = (p, last, lastStart, prev, prevStart) => portionMatch(p, last) ? lastStart
241
+ : prev !== undefined && portionMatch(p, prev) ? prevStart
242
+ : -1;
243
+ const isDots = (p) => p === '.' || p === '..';
244
+ // a Windows drive letter portion, like `c:`
245
+ const isDrive = (p) => typeof p === 'string' && /^[a-z]:$/i.test(p);
246
+ // true for the `UNC` portion of a long UNC root, //?/UNC/host/share
247
+ const isLongUNC = (p) => typeof p === 'string' && /^unc$/i.test(p);
248
+ // The index of the host in a row or split path that starts with a
249
+ // Windows UNC root: 2 for `//host/share`, and 4 for
250
+ // `//?/UNC/host/share`. Otherwise -1. `//?/c:` is not one.
251
+ const uncHost = (p) => {
252
+ if (p[0] !== '' || p[1] !== '')
253
+ return -1;
254
+ const h = p[2] !== '?' ? 2
255
+ : isLongUNC(p[3]) ? 4
256
+ : -1;
257
+ const host = p[h];
258
+ const share = p[h + 1];
259
+ return (h !== -1 &&
260
+ host !== undefined &&
261
+ host !== '' &&
262
+ host !== exports.GLOBSTAR &&
263
+ share !== undefined &&
264
+ share !== '' &&
265
+ share !== exports.GLOBSTAR) ?
266
+ h
267
+ : -1;
268
+ };
269
+ // true if ** can walk the path portion: not `.` or `..`, and not a
270
+ // dotfile unless `dot` is set
271
+ const walkable = (p, dot) => !isDots(p) && (dot || !p.startsWith('.'));
272
+ // True if a portion of the path from `start` to `end` can not be
273
+ // walked by **: one that starts with `.`, or with `dot`, one that is
274
+ // `.` or `..`. `start` is the start of a portion, and `end` is the end
275
+ // of the path, or just after a separator.
276
+ const dotPortion = (f, start, end, dot, sep) => {
277
+ for (let k = start; k < end;) {
278
+ if (f.charCodeAt(k) === 46) {
279
+ if (!dot)
280
+ return true;
281
+ const n = f.charCodeAt(k + 1) === 46 ? k + 2 : k + 1;
282
+ if (n >= end || isSep(f.charCodeAt(n), sep))
283
+ return true;
284
+ }
285
+ // the start of the next portion, after any run of separators
286
+ const s = nextSep(f, k, sep);
287
+ if (s === -1)
288
+ return false;
289
+ k = s + 1;
290
+ while (k < end && isSep(f.charCodeAt(k), sep))
291
+ k++;
292
+ }
293
+ return false;
294
+ };
295
+ const isSep = (c, sep) => sep === '/' ? c === 47
296
+ : sep === '\\' ? c === 92
297
+ : c === 47 || c === 92;
298
+ // the index of the first separator at or after `from`, or -1
299
+ const nextSep = (f, from, sep) => {
300
+ if (sep !== 'both')
301
+ return f.indexOf(sep, from);
302
+ const s = f.indexOf('/', from);
303
+ const b = f.indexOf('\\', from);
304
+ return (s === -1 ? b
305
+ : b === -1 ? s
306
+ : Math.min(s, b));
307
+ };
308
+ // the index of the last separator at or before `from`, or -1
309
+ const lastSep = (f, from, sep) => sep !== 'both' ?
310
+ f.lastIndexOf(sep, from)
311
+ : Math.max(f.lastIndexOf('/', from), f.lastIndexOf('\\', from));
312
+ // What parse() returns in place of a Matcher while make() builds and
313
+ // merges the rows. Most of the Matchers in rows that are merged would
314
+ // never be used, so they are only made for the rows that are left.
315
+ const PENDING = {};
316
+ class Minimatch {
317
+ options;
318
+ set;
319
+ pattern;
320
+ windowsPathsNoEscape;
321
+ nonegate;
322
+ negate;
323
+ comment;
324
+ empty;
325
+ preserveMultipleSlashes;
326
+ partial;
327
+ globSet;
328
+ globParts;
329
+ nocase;
330
+ isWindows;
331
+ platform;
332
+ windowsNoMagicRoot;
333
+ maxGlobstarRecursion;
334
+ // the path can be checked against the last portion, and the string
335
+ // portions, of each row before it is split. See #canMatch.
336
+ #endCheck;
337
+ #literalCheck;
338
+ // level 2 resolves `.` and `..` portions in the path
339
+ #level2;
340
+ // the unicode normalization form, if any
341
+ #form;
342
+ // the string portions of each row in the set
343
+ #literals = [];
344
+ // the rows that #canMatch can match without splitting the path
345
+ #shapes = [];
346
+ // the rows whose last portion can be checked against the path's
347
+ #endRows = [];
348
+ // brace expansion can make the same portion in many rows, so they
349
+ // share one Matcher, and the states that it caches
350
+ #matchers = new Map();
351
+ // parse() returns PENDING in place of a Matcher
352
+ #pending = false;
353
+ // the char that marks numeric ranges in globSet, if any
354
+ #rangeMark;
355
+ // the GlobstarParts of each pattern row, by start index and partial
356
+ #globstarParts = new WeakMap();
357
+ constructor(pattern, options = {}) {
358
+ (0, assert_valid_pattern_js_1.assertValidPattern)(pattern);
359
+ options = options || {};
360
+ this.options = options;
361
+ this.maxGlobstarRecursion = options.maxGlobstarRecursion ?? 200;
362
+ this.pattern = pattern;
363
+ this.platform = options.platform || defaultPlatform;
364
+ this.isWindows = this.platform === 'win32';
365
+ // avoid the annoying deprecation flag lol
366
+ const awe = ('allowWindow' + 'sEscape');
367
+ this.windowsPathsNoEscape =
368
+ !!options.windowsPathsNoEscape || options[awe] === false;
369
+ if (this.windowsPathsNoEscape) {
370
+ this.pattern = this.pattern.replace(/\\/g, '/');
371
+ }
372
+ this.preserveMultipleSlashes = !!options.preserveMultipleSlashes;
373
+ this.negate = false;
374
+ this.nonegate = !!options.nonegate;
375
+ this.comment = false;
376
+ this.empty = false;
377
+ this.partial = !!options.partial;
378
+ this.nocase = !!this.options.nocase;
379
+ this.windowsNoMagicRoot =
380
+ options.windowsNoMagicRoot !== undefined ?
381
+ options.windowsNoMagicRoot
382
+ : !!(this.isWindows && this.nocase);
383
+ this.globSet = [];
384
+ this.globParts = [];
385
+ this.set = [];
386
+ this.#endCheck = !this.preserveMultipleSlashes;
387
+ this.#level2 = (options.optimizationLevel ?? 1) >= 2;
388
+ const n = options.normalize;
389
+ this.#form = n === true ? 'NFC' : n || undefined;
390
+ // make the set of Matchers etc.
391
+ this.make();
392
+ // On Windows, the portions of a row up to its drive letter or UNC
393
+ // share are skipped or compared without case, if the path has one
394
+ // too. So the checks only use the portions after it.
395
+ const drives = this.set.map(row => this.#rootIndex(row));
396
+ this.#endRows = this.set.map((row, r) => this.#endCheck && row.length - 1 > drives[r]);
397
+ // with the end check, the last portion is already checked
398
+ this.#literals = this.set.map((row, r) => {
399
+ const end = this.#endRows[r] ? row.length - 1 : row.length;
400
+ const lits = row
401
+ .slice(drives[r] + 1, end)
402
+ .filter((p) => typeof p === 'string' && !!p);
403
+ return [...new Set(lits)];
404
+ });
405
+ this.#literalCheck = this.#literals.some(l => l.length);
406
+ this.#shapes = this.set.map((row, r) => {
407
+ const [p0, p1, p2] = row;
408
+ if (this.#endRows[r] && row.length === 2) {
409
+ if (p0 === exports.GLOBSTAR && p1 !== exports.GLOBSTAR)
410
+ return 'tail';
411
+ }
412
+ // the basename of a path that is split on / is its last portion,
413
+ // or the one before a trailing /, the same as the end check
414
+ if (this.#endRows[r] &&
415
+ options.matchBase &&
416
+ row.length === 1 &&
417
+ p0 !== exports.GLOBSTAR &&
418
+ p0 !== '') {
419
+ return 'base';
420
+ }
421
+ // the portion must not be a root, or '', which can be a
422
+ // different portion on Windows (where //x paths get an extra '')
423
+ if (!this.#endCheck || drives[r] !== -1)
424
+ return undefined;
425
+ if (row.length === 3 &&
426
+ p0 === exports.GLOBSTAR &&
427
+ p2 === exports.GLOBSTAR &&
428
+ p1 !== exports.GLOBSTAR &&
429
+ p1 !== '' &&
430
+ // the portion between is only matched below this limit
431
+ this.maxGlobstarRecursion > 0) {
432
+ return 'mid';
433
+ }
434
+ if (row.length === 2 &&
435
+ p1 === exports.GLOBSTAR &&
436
+ p0 !== exports.GLOBSTAR &&
437
+ p0 !== '') {
438
+ return 'head';
439
+ }
440
+ return undefined;
441
+ });
442
+ }
443
+ // a string portion of a pattern, normalized if the option is set
444
+ #norm(p) {
445
+ return this.#form ? p.normalize(this.#form) : p;
446
+ }
447
+ // On Windows, the index of the last root portion of a row, as
448
+ // #matchRow finds it: 0 for `c:/...`, 3 for `//?/c:/...` and
449
+ // `//host/share/...`, and 5 for `//?/UNC/host/share/...`. Otherwise
450
+ // -1.
451
+ #rootIndex(row) {
452
+ if (!this.isWindows)
453
+ return -1;
454
+ if (isDrive(row[0]))
455
+ return 0;
456
+ const uncDrive = row[0] === '' && row[1] === '' && row[2] === '?' && isDrive(row[3]);
457
+ if (uncDrive)
458
+ return 3;
459
+ const h = uncHost(row);
460
+ return h === -1 ? -1 : h + 1;
461
+ }
462
+ hasMagic() {
463
+ if (this.options.magicalBraces && this.set.length > 1) {
464
+ return true;
465
+ }
466
+ for (const pattern of this.set) {
467
+ for (const part of pattern) {
468
+ if (typeof part !== 'string')
469
+ return true;
470
+ }
471
+ }
472
+ return false;
473
+ }
474
+ make() {
475
+ const pattern = this.pattern;
476
+ const options = this.options;
477
+ // empty patterns and comments match nothing.
478
+ if (!options.nocomment && pattern.charAt(0) === '#') {
479
+ this.comment = true;
480
+ return;
481
+ }
482
+ if (!pattern) {
483
+ this.empty = true;
484
+ return;
485
+ }
486
+ // step 1: figure out negation, etc.
487
+ this.parseNegate();
488
+ // step 2: expand braces
489
+ this.globSet = [...new Set(this.#expandBraces())];
490
+ // step 3: now we have a set, so turn each one into a series of
491
+ // path-portion matching patterns.
492
+ // These will be Matchers, except in the case of "**", which is
493
+ // set to the GLOBSTAR object for globstar behavior,
494
+ // and will not contain any / characters
495
+ //
496
+ // First, we preprocess to make the glob pattern sets a bit simpler
497
+ // and deduped. There are some perf-killing patterns that can cause
498
+ // problems with a glob walk, but we can simplify them down a bit.
499
+ const rawGlobParts = this.globSet.map(s => this.#slashSplit(s));
500
+ this.globParts = this.preprocess(rawGlobParts);
501
+ // glob --> Matchers
502
+ this.#pending = true;
503
+ let set = this.globParts.map((s, _, __) => {
504
+ if (this.isWindows && this.windowsNoMagicRoot) {
505
+ // check if it's a drive or unc path. The root of a long UNC
506
+ // path, //?/UNC/host/share, is 6 portions.
507
+ const n = s[2] === '?' && isLongUNC(s[3]) ? 6 : 4;
508
+ const isUNC = s[0] === '' &&
509
+ s[1] === '' &&
510
+ (s[2] === '?' || !globMagic.test(s[2])) &&
511
+ s.slice(3, n).every(p => !globMagic.test(p));
512
+ const isDrive = /^[a-z]:/i.test(s[0]);
513
+ if (isUNC) {
514
+ return [
515
+ ...s.slice(0, n).map(p => this.#norm(p)),
516
+ ...s.slice(n).map(ss => this.parse(ss)),
517
+ ];
518
+ }
519
+ else if (isDrive) {
520
+ return [
521
+ this.#norm(s[0]),
522
+ ...s.slice(1).map(ss => this.parse(ss)),
523
+ ];
524
+ }
525
+ }
526
+ return s.map(ss => this.parse(ss));
527
+ });
528
+ // filter out everything that didn't compile properly.
529
+ this.set = set.filter(s => s.indexOf(false) === -1);
530
+ // do not treat the ? in UNC paths as magic
531
+ if (this.isWindows) {
532
+ for (let i = 0; i < this.set.length; i++) {
533
+ const p = this.set[i];
534
+ if (p[0] === '' &&
535
+ p[1] === '' &&
536
+ this.globParts[i][2] === '?' &&
537
+ (isDrive(p[3]) || isLongUNC(this.globParts[i][3]))) {
538
+ if (isLongUNC(this.globParts[i][3]))
539
+ p[3] = 'UNC';
540
+ p[2] = '?';
541
+ }
542
+ }
543
+ }
544
+ // with noext, `@(...)` would be literal
545
+ if (!options.noext)
546
+ this.mergeRows();
547
+ this.#pending = false;
548
+ this.set.forEach((row, i) => {
549
+ for (let k = 0; k < row.length; k++) {
550
+ if (row[k] === PENDING) {
551
+ row[k] = this.parse(this.globParts[i][k]);
552
+ }
553
+ }
554
+ });
555
+ }
556
+ // Merge rows that only differ in one portion, where each of them
557
+ // is a Matcher, into one row that matches any of them with
558
+ // `@(a|b|...)`. Then a path is only walked once for all of them,
559
+ // for example with `**/*.{js,ts}`.
560
+ mergeRows() {
561
+ let merged = true;
562
+ while (merged) {
563
+ merged = false;
564
+ const len = Math.max(0, ...this.set.map(r => r.length));
565
+ for (let k = 0; k < len; k++) {
566
+ // the rows that are the same other than at portion k
567
+ const groups = new Map();
568
+ this.set.forEach((row, i) => {
569
+ if (!(row[k] instanceof nonrecursive_glob_match_1.Matcher || row[k] === PENDING) ||
570
+ !extSafe(this.globParts[i][k])) {
571
+ return;
572
+ }
573
+ const parts = [...this.globParts[i]];
574
+ parts[k] = '';
575
+ const key = `${row.length}/${parts.join('/')}`;
576
+ const g = groups.get(key);
577
+ if (g)
578
+ g.push(i);
579
+ else
580
+ groups.set(key, [i]);
581
+ });
582
+ const drop = new Set();
583
+ for (const g of groups.values()) {
584
+ if (g.length < 2)
585
+ continue;
586
+ const [first, ...rest] = g;
587
+ const alts = g.map(i => this.globParts[i][k]);
588
+ const glob = `@(${alts.join('|')})`;
589
+ this.globParts[first][k] = glob;
590
+ this.set[first][k] = this.parse(glob);
591
+ for (const i of rest)
592
+ drop.add(i);
593
+ }
594
+ if (drop.size) {
595
+ merged = true;
596
+ this.set = this.set.filter((_, i) => !drop.has(i));
597
+ this.globParts = this.globParts.filter((_, i) => !drop.has(i));
598
+ }
599
+ }
600
+ }
601
+ }
602
+ // various transforms to equivalent pattern sets that are
603
+ // faster to process in a filesystem walk. The goal is to
604
+ // eliminate what we can, and push all ** patterns as far
605
+ // to the right as possible, even if it increases the number
606
+ // of patterns that we have to process.
607
+ preprocess(globParts) {
608
+ // if we're not in globstar mode, then turn ** into *
609
+ if (this.options.noglobstar) {
610
+ for (const partset of globParts) {
611
+ for (let j = 0; j < partset.length; j++) {
612
+ if (partset[j] === '**') {
613
+ partset[j] = '*';
614
+ }
615
+ }
616
+ }
617
+ }
618
+ const { optimizationLevel = 1 } = this.options;
619
+ if (optimizationLevel >= 2) {
620
+ // aggressive optimization for the purpose of fs walking
621
+ globParts = this.firstPhasePreProcess(globParts);
622
+ globParts = this.secondPhasePreProcess(globParts);
623
+ }
624
+ else if (optimizationLevel >= 1) {
625
+ // just basic optimizations to remove some .. parts
626
+ globParts = this.levelOneOptimize(globParts);
627
+ }
628
+ else {
629
+ // just collapse multiple ** portions into one
630
+ globParts = this.adjascentGlobstarOptimize(globParts);
631
+ }
632
+ return globParts;
633
+ }
634
+ // just get rid of adjascent ** portions
635
+ adjascentGlobstarOptimize(globParts) {
636
+ return globParts.map(parts => {
637
+ let gs = -1;
638
+ while (-1 !== (gs = parts.indexOf('**', gs + 1))) {
639
+ let i = gs;
640
+ while (parts[i + 1] === '**') {
641
+ i++;
642
+ }
643
+ if (i !== gs) {
644
+ parts.splice(gs, i - gs);
645
+ }
646
+ }
647
+ return parts;
648
+ });
649
+ }
650
+ // get rid of adjascent ** and resolve .. portions
651
+ levelOneOptimize(globParts) {
652
+ return globParts.map(parts => {
653
+ // .. can not remove the root of a Windows path
654
+ const root = this.#rootIndex(parts) + 1;
655
+ parts = parts.reduce((set, part) => {
656
+ const prev = set[set.length - 1];
657
+ if (part === '**' && prev === '**') {
658
+ return set;
659
+ }
660
+ if (part === '..') {
661
+ if (set.length > root &&
662
+ prev &&
663
+ prev !== '..' &&
664
+ prev !== '.' &&
665
+ prev !== '**') {
666
+ set.pop();
667
+ return set;
668
+ }
669
+ }
670
+ set.push(part);
671
+ return set;
672
+ }, []);
673
+ return parts.length === 0 ? [''] : parts;
674
+ });
675
+ }
676
+ // Check the path against each row before it is split. 'no' if no
677
+ // row can match, so it does not need to be split. 'yes' if a row of
678
+ // `**` and one more portion matches. 'maybe' if it must be split to
679
+ // know. None of this applies with partial, where the path can end
680
+ // before the row does.
681
+ //
682
+ // On Windows, `\` is a separator in the path too, and the portions of
683
+ // a row up to its drive letter or UNC share are not checked (see
684
+ // #rootIndex).
685
+ //
686
+ // Each string portion of a row must be a portion of the path, so the
687
+ // path must contain it. Level 2 can only take portions out of the
688
+ // path, so this is still true then.
689
+ //
690
+ // The last portion of a row must match the last portion of the path,
691
+ // or the one before a trailing `/` (as a/* and a/**/* match a/b/).
692
+ // This does not apply to rows that end in **, rows that end in a
693
+ // root, or preserveMultipleSlashes (which can leave more
694
+ // than one '' at the end). At level 2, it does not apply if that
695
+ // portion is `.` or `..`, which can be
696
+ // resolved away. Level 2 only takes other portions out of the
697
+ // middle of the path.
698
+ //
699
+ // A row of `**/x` then matches if the ** can walk the portions
700
+ // before the one that x matches, the same as #matchGlobstar. At
701
+ // level 2, this is only known if none of them are `.` or `..`, so
702
+ // that the path does not change when it is resolved.
703
+ #canMatch(f) {
704
+ const sep = !this.isWindows || !f.includes('\\') ? '/'
705
+ : f.includes('/') ? 'both'
706
+ : '\\';
707
+ // the portions that f.split(/\/+/) would end with, and where they
708
+ // start in f, found when a row needs them. `ends` is 0 until they
709
+ // are found, then 1, or -1 if they can not be used.
710
+ let ends = this.#endCheck ? 0 : -1;
711
+ let last = '';
712
+ let lastStart = 0;
713
+ let prev;
714
+ let prevStart = 0;
715
+ const dot = !!this.options.dot;
716
+ // A string compare is cheaper than includes(), and a Matcher test
717
+ // costs more, so the cheaper check goes first.
718
+ ROWS: for (let r = 0; r < this.set.length; r++) {
719
+ const row = this.set[r];
720
+ const p = row[row.length - 1];
721
+ let end = ends !== -1 && this.#endRows[r] && p !== exports.GLOBSTAR;
722
+ if (end && ends === 0) {
723
+ const i = lastSep(f, f.length, sep);
724
+ lastStart = i + 1;
725
+ last = f.slice(lastStart);
726
+ if (last === '' && i >= 0) {
727
+ let j = i;
728
+ while (j > 0 && isSep(f.charCodeAt(j - 1), sep))
729
+ j--;
730
+ prevStart = j === 0 ? 0 : lastSep(f, j - 1, sep) + 1;
731
+ prev = f.slice(prevStart, j);
732
+ }
733
+ const resolves = this.#level2 &&
734
+ (isDots(last) ||
735
+ (last === '' && prev !== undefined && isDots(prev)));
736
+ ends = resolves ? -1 : 1;
737
+ end = !resolves;
738
+ }
739
+ let tailStart = -1;
740
+ if (end && typeof p === 'string') {
741
+ tailStart = endIndex(p, last, lastStart, prev, prevStart);
742
+ if (tailStart === -1)
743
+ continue;
744
+ }
745
+ if (this.#literalCheck) {
746
+ for (const l of this.#literals[r]) {
747
+ if (!f.includes(l))
748
+ continue ROWS;
749
+ }
750
+ }
751
+ if (end && typeof p === 'object') {
752
+ tailStart = endIndex(p, last, lastStart, prev, prevStart);
753
+ if (tailStart === -1)
754
+ continue;
755
+ }
756
+ const shape = this.#shapes[r];
757
+ if (shape === 'base' && end)
758
+ return 'yes';
759
+ if (shape === 'tail' && end) {
760
+ if (this.#level2 && dotPortion(f, 0, tailStart, true, sep)) {
761
+ return 'maybe';
762
+ }
763
+ if (!dotPortion(f, 0, tailStart, dot, sep))
764
+ return 'yes';
765
+ continue;
766
+ }
767
+ if (shape === 'mid' || shape === 'head') {
768
+ const m = this.#walk(f, row, shape === 'head', dot, sep);
769
+ if (m !== 'no')
770
+ return m;
771
+ continue;
772
+ }
773
+ return 'maybe';
774
+ }
775
+ return 'no';
776
+ }
777
+ // Match a row of a known shape against the split path, the same as
778
+ // #matchGlobstar and #matchGlobStarBodySections do. None of these
779
+ // rows have a drive letter, so they start at the first portion.
780
+ #matchShape(file, row, shape) {
781
+ const dot = !!this.options.dot;
782
+ const n = file.length;
783
+ if (shape === 'head') {
784
+ // x, then at least one portion that ** can walk
785
+ if (n < 2 || !portionMatch(row[0], file[0])) {
786
+ return false;
787
+ }
788
+ for (let i = 1; i < n; i++)
789
+ if (!walkable(file[i], dot))
790
+ return false;
791
+ return true;
792
+ }
793
+ const x = row[1];
794
+ if (shape === 'tail') {
795
+ // x is the last portion, or the one before a trailing ''
796
+ let t = n - 1;
797
+ if (!portionMatch(x, file[t])) {
798
+ if (file[t] !== '' || n === 1 || !portionMatch(x, file[--t])) {
799
+ return false;
800
+ }
801
+ }
802
+ for (let i = 0; i < t; i++)
803
+ if (!walkable(file[i], dot))
804
+ return false;
805
+ return true;
806
+ }
807
+ // mid: the first x that ** can walk to, with a portion after it,
808
+ // and ** can walk all of those
809
+ for (let k = 0; k < n; k++) {
810
+ if (portionMatch(x, file[k]) && k + 1 < n) {
811
+ let i = k + 1;
812
+ while (i < n && walkable(file[i], dot))
813
+ i++;
814
+ if (i === n)
815
+ return true;
816
+ }
817
+ if (!walkable(file[k], dot))
818
+ return false;
819
+ }
820
+ return false;
821
+ }
822
+ // Match a row of `**/x/**` or `x/**` against the path, the same as
823
+ // #matchGlobstar and #matchGlobStarBodySections do once it is split.
824
+ // x must match a portion (the first one, for `x/**`), the ** before
825
+ // it must be able to walk the portions before that one, and there
826
+ // must be a portion after it, which the ** after it can walk. At
827
+ // level 2, this is only known if no portion is `.` or `..`.
828
+ #walk(f, row, head, dot, sep) {
829
+ if (this.#level2 && dotPortion(f, 0, f.length, true, sep))
830
+ return 'maybe';
831
+ const x = row[head ? 0 : 1];
832
+ // the last portion has none after it, so it can not be x
833
+ let s = 0;
834
+ for (let e = nextSep(f, s, sep); e !== -1; e = nextSep(f, s, sep)) {
835
+ // the start of the next portion
836
+ let next = e + 1;
837
+ while (next < f.length && isSep(f.charCodeAt(next), sep))
838
+ next++;
839
+ const hit = typeof x === 'string' ?
840
+ e - s === x.length && f.startsWith(x, s)
841
+ : e > s && x.testUnchecked(f.slice(s, e));
842
+ if (hit && !dotPortion(f, next, f.length, dot, sep))
843
+ return 'yes';
844
+ if (head || dotPortion(f, s, next, dot, sep))
845
+ return 'no';
846
+ s = next;
847
+ }
848
+ return 'no';
849
+ }
850
+ // the last split, if it was the same path with the same split
851
+ // settings
852
+ #cachedSplit(f) {
853
+ const last = lastSplit;
854
+ return (last?.f === f &&
855
+ last.isWindows === this.isWindows &&
856
+ last.preserveMultipleSlashes === this.preserveMultipleSlashes &&
857
+ last.normalize === this.#form) ?
858
+ last
859
+ : undefined;
860
+ }
861
+ // split a path for match(), and keep the parts for the next call
862
+ #split(f) {
863
+ const { isWindows, preserveMultipleSlashes } = this;
864
+ // windows: need to use /, not \
865
+ let parts = this.#slashSplit(isWindows ? f.split('\\').join('/') : f);
866
+ // normalize each portion, so that a char that normalizes to `/`
867
+ // does not make a new portion
868
+ const normalize = this.#form;
869
+ if (normalize)
870
+ parts = parts.map(p => p.normalize(normalize));
871
+ lastSplit = {
872
+ f,
873
+ isWindows,
874
+ preserveMultipleSlashes,
875
+ normalize,
876
+ parts,
877
+ };
878
+ return lastSplit;
879
+ }
880
+ // resolve `.` and `..` portions of a path, for level 2
881
+ #levelTwoFileOptimize(file) {
882
+ // work on a copy, so that the cached parts do not change
883
+ const parts = [...file];
884
+ let didSomething = false;
885
+ do {
886
+ didSomething = false;
887
+ // <pre>/<e>/<rest> -> <pre>/<rest>
888
+ if (!this.preserveMultipleSlashes) {
889
+ for (let i = 1; i < parts.length - 1; i++) {
890
+ const p = parts[i];
891
+ // don't squeeze out UNC patterns
892
+ if (i === 1 && p === '' && parts[0] === '')
893
+ continue;
894
+ if (p === '.' || p === '') {
895
+ didSomething = true;
896
+ parts.splice(i, 1);
897
+ i--;
898
+ }
899
+ }
900
+ if (parts[0] === '.' &&
901
+ parts.length === 2 &&
902
+ (parts[1] === '.' || parts[1] === '')) {
903
+ didSomething = true;
904
+ parts.pop();
905
+ }
906
+ }
907
+ // <pre>/<p>/../<rest> -> <pre>/<rest>
908
+ // .. can not remove the root of a Windows path
909
+ const root = this.#rootIndex(parts) + 1;
910
+ let dd = root;
911
+ while (-1 !== (dd = parts.indexOf('..', dd + 1))) {
912
+ const p = parts[dd - 1];
913
+ if (p && p !== '.' && p !== '..' && p !== '**') {
914
+ didSomething = true;
915
+ parts.splice(dd - 1, 2);
916
+ dd = Math.max(dd - 2, root);
917
+ }
918
+ }
919
+ } while (didSomething);
920
+ return parts.length === 0 ? [''] : parts;
921
+ }
922
+ // First phase: single-pattern processing
923
+ // <pre> is 1 or more portions
924
+ // <rest> is 1 or more portions
925
+ // <p> is any portion other than ., .., '', or **
926
+ // <e> is . or ''
927
+ //
928
+ // **/.. is *brutal* for filesystem walking performance, because
929
+ // it effectively resets the recursive walk each time it occurs,
930
+ // and ** cannot be reduced out by a .. pattern part like a regexp
931
+ // or most strings (other than .., ., and '') can be.
932
+ //
933
+ // <pre>/**/../<p>/<p>/<rest> -> {<pre>/../<p>/<p>/<rest>,<pre>/**/<p>/<p>/<rest>}
934
+ // <pre>/<e>/<rest> -> <pre>/<rest>
935
+ // <pre>/<p>/../<rest> -> <pre>/<rest>
936
+ // **/**/<rest> -> **/<rest>
937
+ //
938
+ // **/*/<rest> -> */**/<rest> <== not valid because ** doesn't follow
939
+ // this WOULD be allowed if ** did follow symlinks, or * didn't
940
+ firstPhasePreProcess(globParts) {
941
+ // each **/.. split doubles the patterns, and adds a copy of the
942
+ // whole pattern. Throw if either gets too large. A partial split
943
+ // would match some paths and not others, depending on which rows
944
+ // the pass reached first.
945
+ const { braceExpandMax = 100_000 } = this.options;
946
+ let splitCells = 0;
947
+ const maxSplitCells = 1_000_000;
948
+ let didSomething = false;
949
+ do {
950
+ didSomething = false;
951
+ // <pre>/**/../<p>/<p>/<rest> -> {<pre>/../<p>/<p>/<rest>,<pre>/**/<p>/<p>/<rest>}
952
+ for (let parts of globParts) {
953
+ let gs = -1;
954
+ while (-1 !== (gs = parts.indexOf('**', gs + 1))) {
955
+ let gss = gs;
956
+ while (parts[gss + 1] === '**') {
957
+ // <pre>/**/**/<rest> -> <pre>/**/<rest>
958
+ gss++;
959
+ }
960
+ // eg, if gs is 2 and gss is 4, that means we have 3 **
961
+ // parts, and can remove 2 of them.
962
+ if (gss > gs) {
963
+ parts.splice(gs + 1, gss - gs);
964
+ }
965
+ let next = parts[gs + 1];
966
+ const p = parts[gs + 2];
967
+ const p2 = parts[gs + 3];
968
+ if (next !== '..')
969
+ continue;
970
+ if (!p ||
971
+ p === '.' ||
972
+ p === '..' ||
973
+ !p2 ||
974
+ p2 === '.' ||
975
+ p2 === '..') {
976
+ continue;
977
+ }
978
+ // Check before changing parts or allocating the new row.
979
+ const addedCells = parts.length - 1;
980
+ if (globParts.length >= braceExpandMax ||
981
+ splitCells + addedCells > maxSplitCells) {
982
+ throw new RangeError(`optimizationLevel 2: too many patterns from '**/..'`);
983
+ }
984
+ didSomething = true;
985
+ // edit parts in place, and push the new one
986
+ parts.splice(gs, 1);
987
+ const other = parts.slice(0);
988
+ other[gs] = '**';
989
+ splitCells += addedCells;
990
+ globParts.push(other);
991
+ gs--;
992
+ }
993
+ // <pre>/<e>/<rest> -> <pre>/<rest>
994
+ if (!this.preserveMultipleSlashes) {
995
+ for (let i = 1; i < parts.length - 1; i++) {
996
+ const p = parts[i];
997
+ // don't squeeze out UNC patterns
998
+ if (i === 1 && p === '' && parts[0] === '')
999
+ continue;
1000
+ if (p === '.' || p === '') {
1001
+ didSomething = true;
1002
+ parts.splice(i, 1);
1003
+ i--;
1004
+ }
1005
+ }
1006
+ if (parts[0] === '.' &&
1007
+ parts.length === 2 &&
1008
+ (parts[1] === '.' || parts[1] === '')) {
1009
+ didSomething = true;
1010
+ parts.pop();
1011
+ }
1012
+ }
1013
+ // <pre>/<p>/../<rest> -> <pre>/<rest>
1014
+ // .. can not remove the root of a Windows path
1015
+ const root = this.#rootIndex(parts) + 1;
1016
+ let dd = root;
1017
+ while (-1 !== (dd = parts.indexOf('..', dd + 1))) {
1018
+ const p = parts[dd - 1];
1019
+ if (p && p !== '.' && p !== '..' && p !== '**') {
1020
+ didSomething = true;
1021
+ const needDot = dd === 1 && parts[dd + 1] === '**';
1022
+ const splin = needDot ? ['.'] : [];
1023
+ parts.splice(dd - 1, 2, ...splin);
1024
+ if (parts.length === 0)
1025
+ parts.push('');
1026
+ dd = Math.max(dd - 2, root);
1027
+ }
1028
+ }
1029
+ }
1030
+ } while (didSomething);
1031
+ return globParts;
1032
+ }
1033
+ // second phase: multi-pattern dedupes
1034
+ // {<pre>/<rest>,<pre>/<rest>} -> <pre>/<rest>
1035
+ // {<pre>/*/<rest>,<pre>/<p>/<rest>} -> <pre>/*/<rest>
1036
+ secondPhasePreProcess(globParts) {
1037
+ const keys = new Set();
1038
+ const rows = globParts.filter(parts => {
1039
+ const key = parts.join('/');
1040
+ if (keys.has(key))
1041
+ return false;
1042
+ keys.add(key);
1043
+ return true;
1044
+ });
1045
+ // A row is covered by another row that has `*` at some positions,
1046
+ // and is the same at all others. Collect each distinct set of `*`
1047
+ // positions, then look up each row with `*` put at those positions.
1048
+ const stars = new Map();
1049
+ for (const parts of rows) {
1050
+ const s = [];
1051
+ for (let i = 0; i < parts.length; i++) {
1052
+ if (parts[i] === '*')
1053
+ s.push(i);
1054
+ }
1055
+ if (s.length)
1056
+ stars.set(s.join(','), s);
1057
+ }
1058
+ // Each row is checked against each set of `*` positions, so skip
1059
+ // this if there are too many. The patterns match the same paths
1060
+ // either way.
1061
+ if (!stars.size || rows.length * stars.size > 100_000)
1062
+ return rows;
1063
+ const { dot } = this.options;
1064
+ return rows.filter(parts => {
1065
+ for (const s of stars.values()) {
1066
+ if (s[s.length - 1] >= parts.length)
1067
+ continue;
1068
+ const c = [...parts];
1069
+ let ok = true;
1070
+ let changed = false;
1071
+ for (const i of s) {
1072
+ const p = parts[i];
1073
+ if (p === '*')
1074
+ continue;
1075
+ if (!p || p === '**' || (!dot && p.startsWith('.'))) {
1076
+ ok = false;
1077
+ break;
1078
+ }
1079
+ c[i] = '*';
1080
+ changed = true;
1081
+ }
1082
+ if (ok && changed && keys.has(c.join('/')))
1083
+ return false;
1084
+ }
1085
+ return true;
1086
+ });
1087
+ }
1088
+ parseNegate() {
1089
+ if (this.nonegate)
1090
+ return;
1091
+ const pattern = this.pattern;
1092
+ let negate = false;
1093
+ let negateOffset = 0;
1094
+ for (let i = 0; i < pattern.length && pattern.charAt(i) === '!'; i++) {
1095
+ negate = !negate;
1096
+ negateOffset++;
1097
+ }
1098
+ if (negateOffset)
1099
+ this.pattern = pattern.slice(negateOffset);
1100
+ this.negate = negate;
1101
+ }
1102
+ // Match the parts of a path against one row of the set. `resolved`
1103
+ // is the parts after level 2 resolves `.` and `..` in them, or the
1104
+ // same parts below level 2. Set partial to true to test if, for
1105
+ // example, "/a/b" matches the start of "/*/b/*/d". Partial means, if
1106
+ // you run out of file before you run out of pattern, then that's
1107
+ // fine, as long as all the parts match.
1108
+ #matchRow(file, resolved, pattern, partial) {
1109
+ let fileStartIndex = 0;
1110
+ let patternStartIndex = 0;
1111
+ // UNC paths like //?/X:/... can match X:/... and vice versa, and
1112
+ // //?/UNC/host/share/... can match //host/share/... and vice versa.
1113
+ // Drive letters in absolute drive or unc paths, and the host and
1114
+ // share of UNC paths, are always compared case-insensitively.
1115
+ const fh = this.isWindows ? uncHost(resolved) : -1;
1116
+ const ph = fh === -1 ? -1 : uncHost(pattern);
1117
+ if (ph !== -1) {
1118
+ const host = pattern[ph];
1119
+ const share = pattern[ph + 1];
1120
+ if (typeof host !== 'string' || typeof share !== 'string') {
1121
+ // a host or share with magic is matched as usual
1122
+ fileStartIndex = fh;
1123
+ patternStartIndex = ph;
1124
+ }
1125
+ else if (resolved[fh].toLowerCase() === host.toLowerCase() &&
1126
+ resolved[fh + 1].toLowerCase() === share.toLowerCase()) {
1127
+ fileStartIndex = fh + 2;
1128
+ patternStartIndex = ph + 2;
1129
+ }
1130
+ }
1131
+ else if (this.isWindows) {
1132
+ const fileDrive = typeof file[0] === 'string' && /^[a-z]:$/i.test(file[0]);
1133
+ const fileUNC = !fileDrive &&
1134
+ file[0] === '' &&
1135
+ file[1] === '' &&
1136
+ file[2] === '?' &&
1137
+ /^[a-z]:$/i.test(file[3]);
1138
+ const patternDrive = typeof pattern[0] === 'string' && /^[a-z]:$/i.test(pattern[0]);
1139
+ const patternUNC = !patternDrive &&
1140
+ pattern[0] === '' &&
1141
+ pattern[1] === '' &&
1142
+ pattern[2] === '?' &&
1143
+ typeof pattern[3] === 'string' &&
1144
+ /^[a-z]:$/i.test(pattern[3]);
1145
+ const fdi = fileUNC ? 3
1146
+ : fileDrive ? 0
1147
+ : undefined;
1148
+ const pdi = patternUNC ? 3
1149
+ : patternDrive ? 0
1150
+ : undefined;
1151
+ if (typeof fdi === 'number' && typeof pdi === 'number') {
1152
+ const [fd, pd] = [
1153
+ file[fdi],
1154
+ pattern[pdi],
1155
+ ];
1156
+ // the drives match, so start matching after them
1157
+ if (fd.toLowerCase() === pd.toLowerCase()) {
1158
+ patternStartIndex = pdi + 1;
1159
+ fileStartIndex = fdi + 1;
1160
+ }
1161
+ }
1162
+ }
1163
+ // the drive letters are found in the parts before level 2 resolves
1164
+ // them, and the match uses the resolved parts
1165
+ file = resolved;
1166
+ if (pattern.includes(exports.GLOBSTAR)) {
1167
+ return this.#matchGlobstar(file, pattern, partial, fileStartIndex, patternStartIndex);
1168
+ }
1169
+ return this.#matchOne(file, pattern, partial, fileStartIndex, patternStartIndex);
1170
+ }
1171
+ #matchGlobstar(file, pattern, partial, fileIndex, patternIndex) {
1172
+ const { head, body, tail, segments } = this.#getGlobstarParts(pattern, partial, patternIndex);
1173
+ // check the head, from the current file/pattern index.
1174
+ if (head.length) {
1175
+ const headEnd = fileIndex + head.length;
1176
+ if (!this.#matchOne(file, head, partial, fileIndex, 0, headEnd)) {
1177
+ return false;
1178
+ }
1179
+ fileIndex += head.length;
1180
+ patternIndex += head.length;
1181
+ }
1182
+ // now we know the head matches!
1183
+ // if the last portion is not empty, it MUST match the end
1184
+ // check the tail
1185
+ let fileTailMatch = 0;
1186
+ if (tail.length) {
1187
+ // if head + tail > file, then we cannot possibly match
1188
+ if (tail.length + fileIndex > file.length)
1189
+ return false;
1190
+ // try to match the tail
1191
+ let tailStart = file.length - tail.length;
1192
+ if (this.#matchOne(file, tail, partial, tailStart, 0)) {
1193
+ fileTailMatch = tail.length;
1194
+ }
1195
+ else {
1196
+ // affordance for stuff like a/**/* matching a/b/
1197
+ // if the last file portion is '', and there's more to the pattern
1198
+ // then try without the '' bit.
1199
+ if (file[file.length - 1] !== '' ||
1200
+ fileIndex + tail.length === file.length) {
1201
+ return false;
1202
+ }
1203
+ tailStart--;
1204
+ if (!this.#matchOne(file, tail, partial, tailStart, 0)) {
1205
+ return false;
1206
+ }
1207
+ fileTailMatch = tail.length + 1;
1208
+ }
1209
+ }
1210
+ // now we know the tail matches!
1211
+ // the middle is zero or more portions wrapped in **, possibly
1212
+ // containing more ** sections.
1213
+ // so a/**/b/**/c/**/d has become **/b/**/c/**
1214
+ // if it's empty, it means a/**/b, just verify we have no bad dots
1215
+ // if there's no tail, so it ends on /**, then we must have *something*
1216
+ // after the head, or it's not a matc
1217
+ if (!body.length) {
1218
+ let sawSome = !!fileTailMatch;
1219
+ for (let i = fileIndex; i < file.length - fileTailMatch; i++) {
1220
+ const f = String(file[i]);
1221
+ sawSome = true;
1222
+ if (f === '.' ||
1223
+ f === '..' ||
1224
+ (!this.options.dot && f.startsWith('.'))) {
1225
+ return false;
1226
+ }
1227
+ }
1228
+ // in partial mode, we just need to get past all file parts
1229
+ return partial || sawSome;
1230
+ }
1231
+ // now we know that there's one or more body sections, which can
1232
+ // be matched anywhere from the 0 index (because the head was pruned)
1233
+ // through to the length-fileTailMatch index.
1234
+ return !!this.#matchGlobStarBodySections(file, segments, file.length - fileTailMatch, fileIndex, 0, partial, 0, !!fileTailMatch, new Set());
1235
+ }
1236
+ // Split the pattern into head, tail, and middle of ** delimited
1237
+ // parts. The tail has to be at the end, and the others just have to
1238
+ // be found in order from the head. These only depend on the pattern
1239
+ // row, so they are kept for the next path.
1240
+ #getGlobstarParts(pattern, partial, patternIndex) {
1241
+ let byStart = this.#globstarParts.get(pattern);
1242
+ if (!byStart) {
1243
+ byStart = [];
1244
+ this.#globstarParts.set(pattern, byStart);
1245
+ }
1246
+ const key = patternIndex * 2 + (partial ? 1 : 0);
1247
+ const found = byStart[key];
1248
+ if (found)
1249
+ return found;
1250
+ const firstgs = pattern.indexOf(exports.GLOBSTAR, patternIndex);
1251
+ const lastgs = pattern.lastIndexOf(exports.GLOBSTAR);
1252
+ const head = pattern.slice(patternIndex, firstgs);
1253
+ const body = pattern.slice(firstgs + 1, partial ? undefined : lastgs);
1254
+ const tail = partial ? [] : pattern.slice(lastgs + 1);
1255
+ // split the body up into sections, and note the number of
1256
+ // portions that must come after the start of each one
1257
+ const segments = [[[], 0]];
1258
+ let current = segments[0];
1259
+ let nonGsParts = 0;
1260
+ const nonGsPartsSums = [0];
1261
+ for (const b of body) {
1262
+ if (b === exports.GLOBSTAR) {
1263
+ nonGsPartsSums.push(nonGsParts);
1264
+ current = [[], 0];
1265
+ segments.push(current);
1266
+ }
1267
+ else {
1268
+ current[0].push(b);
1269
+ nonGsParts++;
1270
+ }
1271
+ }
1272
+ // the portions in this section and the ones after it
1273
+ segments.forEach((b, i) => {
1274
+ b[1] = nonGsParts - nonGsPartsSums[i];
1275
+ });
1276
+ const parts = { head, body, tail, segments };
1277
+ byStart[key] = parts;
1278
+ return parts;
1279
+ }
1280
+ // return false for "nope, not matching"
1281
+ // return null for "not matching, cannot keep trying"
1282
+ #matchGlobStarBodySections(file,
1283
+ // pattern section, and the portions that it and the rest need
1284
+ bodySegments,
1285
+ // the end of the file portions that the body can match
1286
+ fileLength, fileIndex, bodyIndex, partial, globStarDepth, sawTail,
1287
+ // the places that a walk has already tried, as
1288
+ // bodyIndex * (file.length + 1) + fileIndex. A walk from a place
1289
+ // does the same no matter how it got there, and it only comes back
1290
+ // if it found no match, so a walk that gets to one stops.
1291
+ tried) {
1292
+ // take the first body segment, and walk from fileIndex to its "after"
1293
+ // value at the end
1294
+ // If it doesn't match at that position, we increment, until we hit
1295
+ // that final possible position, and give up.
1296
+ // If it does match, then advance and try to rest.
1297
+ // If any of them fail we keep walking forward.
1298
+ // this is still a bit recursively painful, but it's more constrained
1299
+ // than previous implementations, because we never test something that
1300
+ // can't possibly be a valid matching condition.
1301
+ const bs = bodySegments[bodyIndex];
1302
+ if (!bs) {
1303
+ // with partial, the body is the rest of the pattern, so it
1304
+ // matches if no portions are left, or only the '' of a trailing
1305
+ // / (as a/* matches a/b/). A ** at the end walks them as its own
1306
+ // empty section.
1307
+ if (partial) {
1308
+ return (fileIndex >= fileLength ||
1309
+ (fileIndex === fileLength - 1 && file[fileIndex] === ''));
1310
+ }
1311
+ // just make sure that there's no bad dots before the tail
1312
+ for (let i = fileIndex; i < fileLength; i++) {
1313
+ sawTail = true;
1314
+ const f = file[i];
1315
+ if (f === '.' ||
1316
+ f === '..' ||
1317
+ (!this.options.dot && f.startsWith('.'))) {
1318
+ return false;
1319
+ }
1320
+ }
1321
+ return sawTail;
1322
+ }
1323
+ // have a non-globstar body section to test, up to the last index
1324
+ // where it can start
1325
+ const [body, need] = bs;
1326
+ // with partial, the path can end before the body does
1327
+ const after = partial ? fileLength : fileLength - need;
1328
+ while (fileIndex <= after) {
1329
+ const key = bodyIndex * (file.length + 1) + fileIndex;
1330
+ if (tried.has(key))
1331
+ return false;
1332
+ tried.add(key);
1333
+ const m = this.#matchOne(file, body, partial, fileIndex, 0, fileIndex + body.length);
1334
+ // if limit exceeded, no match. intentional false negative,
1335
+ // acceptable break in correctness for security.
1336
+ if (m && globStarDepth < this.maxGlobstarRecursion) {
1337
+ // match! see if the rest match. if so, we're done!
1338
+ const sub = this.#matchGlobStarBodySections(file, bodySegments, fileLength, fileIndex + body.length, bodyIndex + 1, partial, globStarDepth + 1, sawTail, tried);
1339
+ if (sub !== false) {
1340
+ return sub;
1341
+ }
1342
+ }
1343
+ // the ** does not walk past the last place the body can start
1344
+ if (fileIndex === after)
1345
+ break;
1346
+ const f = file[fileIndex];
1347
+ if (f === '.' ||
1348
+ f === '..' ||
1349
+ (!this.options.dot && f.startsWith('.'))) {
1350
+ return false;
1351
+ }
1352
+ fileIndex++;
1353
+ }
1354
+ // walked off. no point continuing
1355
+ return partial || null;
1356
+ }
1357
+ #matchOne(file, pattern, partial, fileIndex, patternIndex,
1358
+ // only match the file portions before this index
1359
+ fileEnd = file.length) {
1360
+ let fi;
1361
+ let pi;
1362
+ let pl;
1363
+ let fl;
1364
+ for (fi = fileIndex,
1365
+ pi = patternIndex,
1366
+ fl = Math.min(fileEnd, file.length),
1367
+ pl = pattern.length; fi < fl && pi < pl; fi++, pi++) {
1368
+ let p = pattern[pi];
1369
+ let f = file[fi];
1370
+ // should be impossible.
1371
+ /* c8 ignore start */
1372
+ if (p === false || p === exports.GLOBSTAR) {
1373
+ return false;
1374
+ }
1375
+ /* c8 ignore stop */
1376
+ // something other than **
1377
+ // non-magic patterns just have to match exactly
1378
+ // patterns with magic have been turned into Matchers.
1379
+ if (!portionMatch(p, f))
1380
+ return false;
1381
+ }
1382
+ // Note: ending in / means that we'll get a final ""
1383
+ // at the end of the pattern. This can only match a
1384
+ // corresponding "" at the end of the file.
1385
+ // If the file ends in /, then it can only match a
1386
+ // a pattern that ends in /, unless the pattern just
1387
+ // doesn't have any more for it. But, a/b/ should *not*
1388
+ // match "a/b/*", even though * can match "", except in
1389
+ // partial mode, where it might simply not be reached yet.
1390
+ // However, a/b/ should still satisfy a/*
1391
+ // now either we fell off the end of the pattern, or we're done.
1392
+ if (fi === fl && pi === pl) {
1393
+ // ran out of pattern and filename at the same time.
1394
+ // an exact hit!
1395
+ return true;
1396
+ }
1397
+ else if (fi === fl) {
1398
+ // ran out of file, but still had pattern left.
1399
+ // this is ok if we're doing the match as part of
1400
+ // a glob fs traversal.
1401
+ return partial;
1402
+ }
1403
+ else if (pi === pl) {
1404
+ // ran out of pattern, still have file left.
1405
+ // this is only acceptable if we're on the very last
1406
+ // empty segment of a file with a trailing slash.
1407
+ // a/* should match a/b/
1408
+ return fi === fl - 1 && file[fi] === '';
1409
+ /* c8 ignore start */
1410
+ }
1411
+ else {
1412
+ // should be unreachable.
1413
+ throw new Error('wtf?');
1414
+ }
1415
+ /* c8 ignore stop */
1416
+ }
1417
+ braceExpand() {
1418
+ return (0, exports.braceExpand)(this.pattern, this.options);
1419
+ }
1420
+ // Expand braces, except numeric ranges such as {0..999} with at
1421
+ // least RANGE_MIN values. Each of those stays in its pattern as
1422
+ // `<mark>0..999<mark>`, for the Matcher to test. If a range might
1423
+ // be inside a [...] class, expand all of them instead.
1424
+ #expandBraces() {
1425
+ const { pattern } = this;
1426
+ if (this.options.nobrace)
1427
+ return this.braceExpand();
1428
+ let code = 0xe000;
1429
+ while (pattern.includes(String.fromCharCode(code))) {
1430
+ if (++code > 0xf8ff)
1431
+ return this.braceExpand();
1432
+ }
1433
+ const mark = String.fromCharCode(code);
1434
+ let found = false;
1435
+ const marked = pattern.replace(rangeRe, (m, lo, hi) => {
1436
+ const a = Number(lo);
1437
+ const b = Number(hi);
1438
+ if (!Number.isSafeInteger(a) ||
1439
+ !Number.isSafeInteger(b) ||
1440
+ Math.abs(a - b) + 1 < RANGE_MIN) {
1441
+ return m;
1442
+ }
1443
+ found = true;
1444
+ return `${mark}${lo}..${hi}${mark}`;
1445
+ });
1446
+ if (!found)
1447
+ return this.braceExpand();
1448
+ const set = (0, exports.braceExpand)(marked, this.options);
1449
+ for (const p of set) {
1450
+ for (const portion of p.split('/')) {
1451
+ const c = portion.indexOf('[');
1452
+ if (c !== -1 && c < portion.lastIndexOf(mark)) {
1453
+ return this.braceExpand();
1454
+ }
1455
+ }
1456
+ }
1457
+ this.#rangeMark = mark;
1458
+ return set;
1459
+ }
1460
+ parse(pattern) {
1461
+ (0, assert_valid_pattern_js_1.assertValidPattern)(pattern);
1462
+ const options = this.options;
1463
+ // shortcuts
1464
+ if (pattern === '**')
1465
+ return exports.GLOBSTAR;
1466
+ if (pattern === '')
1467
+ return '';
1468
+ const { nocase, nocaseMagicOnly, noext = false, dot, normalize, } = options;
1469
+ const rangeMark = this.#rangeMark;
1470
+ const lit = rangeMark && pattern.includes(rangeMark) ?
1471
+ undefined
1472
+ : literal(pattern, noext);
1473
+ // in nocase mode, a literal with cased chars still needs a
1474
+ // Matcher, unless nocaseMagicOnly is set.
1475
+ if (lit !== undefined &&
1476
+ !(nocase &&
1477
+ !nocaseMagicOnly &&
1478
+ pattern.toUpperCase() !== pattern.toLowerCase())) {
1479
+ return this.#norm(lit);
1480
+ }
1481
+ if (this.#pending)
1482
+ return PENDING;
1483
+ let m = this.#matchers.get(pattern);
1484
+ if (!m) {
1485
+ m = new nonrecursive_glob_match_1.Matcher(pattern, {
1486
+ nocase,
1487
+ noext,
1488
+ dot,
1489
+ normalize,
1490
+ ...(rangeMark && { rangeMark }),
1491
+ });
1492
+ this.#matchers.set(pattern, m);
1493
+ }
1494
+ return m;
1495
+ }
1496
+ #slashSplit(p) {
1497
+ // if p starts with // on windows, we preserve that
1498
+ // so that UNC paths aren't broken. Otherwise, any number of
1499
+ // / characters are coalesced into one, unless
1500
+ // preserveMultipleSlashes is set to true.
1501
+ if (this.preserveMultipleSlashes) {
1502
+ return p.split('/');
1503
+ }
1504
+ else if (this.isWindows && /^\/\/[^/]+/.test(p)) {
1505
+ // add an extra '' for the one we lose
1506
+ return ['', ...p.split(/\/+/)];
1507
+ }
1508
+ else {
1509
+ return p.split(/\/+/);
1510
+ }
1511
+ }
1512
+ match(f, partial = this.partial) {
1513
+ // short-circuit in the case of busted things.
1514
+ // comments, etc.
1515
+ if (this.comment) {
1516
+ return false;
1517
+ }
1518
+ if (this.empty) {
1519
+ return f === '';
1520
+ }
1521
+ if (f === '/' && partial) {
1522
+ return true;
1523
+ }
1524
+ const options = this.options;
1525
+ // treat the test path as a set of pathparts. If it was not just
1526
+ // split or checked, check that it can match before splitting it.
1527
+ let split = this.#cachedSplit(f);
1528
+ if (!split) {
1529
+ // the checks look at the path as given, so not if it is
1530
+ // normalized
1531
+ if (!partial &&
1532
+ !this.#form &&
1533
+ (this.#endCheck || this.#literalCheck) &&
1534
+ lastChecked !== f) {
1535
+ lastChecked = f;
1536
+ const can = this.#canMatch(f);
1537
+ if (can === 'no')
1538
+ return options.flipNegate ? false : this.negate;
1539
+ if (can === 'yes')
1540
+ return options.flipNegate ? true : !this.negate;
1541
+ }
1542
+ split = this.#split(f);
1543
+ }
1544
+ const ff = split.parts;
1545
+ // the parts after level 2 resolves them, kept for the next pattern
1546
+ // that tests the same path
1547
+ const resolved = this.#level2 ?
1548
+ (split.resolved ??= this.#levelTwoFileOptimize(ff))
1549
+ : ff;
1550
+ // just ONE of the pattern sets in this.set needs to match
1551
+ // in order for it to be valid. If negating, then just one
1552
+ // match means that we have failed.
1553
+ // Either way, return on the first hit.
1554
+ const set = this.set;
1555
+ // Find the basename of the path by looking for the last non-empty segment
1556
+ let filename = ff[ff.length - 1];
1557
+ if (!filename) {
1558
+ for (let i = ff.length - 2; !filename && i >= 0; i--) {
1559
+ filename = ff[i];
1560
+ }
1561
+ }
1562
+ for (let r = 0; r < set.length; r++) {
1563
+ const pattern = set[r];
1564
+ const shape = partial ? undefined : this.#shapes[r];
1565
+ // level 2 does not change a path of one portion
1566
+ const hit = shape === 'base' ?
1567
+ portionMatch(pattern[0], filename)
1568
+ : shape ? this.#matchShape(resolved, pattern, shape)
1569
+ : options.matchBase && pattern.length === 1 ?
1570
+ this.#matchRow([filename], [filename], pattern, partial)
1571
+ : this.#matchRow(ff, resolved, pattern, partial);
1572
+ if (hit) {
1573
+ if (options.flipNegate) {
1574
+ return true;
1575
+ }
1576
+ return !this.negate;
1577
+ }
1578
+ }
1579
+ // didn't get any hits. this is success if it's a negative
1580
+ // pattern, failure otherwise.
1581
+ if (options.flipNegate) {
1582
+ return false;
1583
+ }
1584
+ return this.negate;
1585
+ }
1586
+ static defaults(def) {
1587
+ return exports.minimatch.defaults(def).Minimatch;
1588
+ }
1589
+ }
1590
+ exports.Minimatch = Minimatch;
1591
+ /* c8 ignore start */
1592
+ var escape_js_2 = require("./escape.js");
1593
+ Object.defineProperty(exports, "escape", { enumerable: true, get: function () { return escape_js_2.escape; } });
1594
+ var unescape_js_2 = require("./unescape.js");
1595
+ Object.defineProperty(exports, "unescape", { enumerable: true, get: function () { return unescape_js_2.unescape; } });
1596
+ /* c8 ignore stop */
1597
+ exports.minimatch.Minimatch = Minimatch;
1598
+ exports.minimatch.escape = escape_js_1.escape;
1599
+ exports.minimatch.unescape = unescape_js_1.unescape;
1600
+ //# sourceMappingURL=index.js.map