korext 0.7.0 → 0.8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (523) hide show
  1. package/README.md +102 -28
  2. package/bin/korext.js +251 -56
  3. package/package.json +21 -14
  4. package/CHANGELOG.md +0 -51
  5. package/dummy.pdf +0 -0
  6. package/korext.json +0 -11
  7. package/node_modules/ansi-regex/index.d.ts +0 -37
  8. package/node_modules/ansi-regex/index.js +0 -10
  9. package/node_modules/ansi-regex/license +0 -9
  10. package/node_modules/ansi-regex/package.json +0 -55
  11. package/node_modules/ansi-regex/readme.md +0 -78
  12. package/node_modules/ansi-styles/index.d.ts +0 -345
  13. package/node_modules/ansi-styles/index.js +0 -163
  14. package/node_modules/ansi-styles/license +0 -9
  15. package/node_modules/ansi-styles/package.json +0 -56
  16. package/node_modules/ansi-styles/readme.md +0 -152
  17. package/node_modules/balanced-match/LICENSE.md +0 -23
  18. package/node_modules/balanced-match/README.md +0 -57
  19. package/node_modules/balanced-match/dist/commonjs/index.d.ts +0 -9
  20. package/node_modules/balanced-match/dist/commonjs/index.d.ts.map +0 -1
  21. package/node_modules/balanced-match/dist/commonjs/index.js +0 -59
  22. package/node_modules/balanced-match/dist/commonjs/index.js.map +0 -1
  23. package/node_modules/balanced-match/dist/commonjs/package.json +0 -3
  24. package/node_modules/balanced-match/dist/esm/index.d.ts +0 -9
  25. package/node_modules/balanced-match/dist/esm/index.d.ts.map +0 -1
  26. package/node_modules/balanced-match/dist/esm/index.js +0 -54
  27. package/node_modules/balanced-match/dist/esm/index.js.map +0 -1
  28. package/node_modules/balanced-match/dist/esm/package.json +0 -3
  29. package/node_modules/balanced-match/package.json +0 -68
  30. package/node_modules/base64-js/LICENSE +0 -21
  31. package/node_modules/base64-js/README.md +0 -34
  32. package/node_modules/base64-js/base64js.min.js +0 -1
  33. package/node_modules/base64-js/index.d.ts +0 -3
  34. package/node_modules/base64-js/index.js +0 -150
  35. package/node_modules/base64-js/package.json +0 -47
  36. package/node_modules/bl/.travis.yml +0 -17
  37. package/node_modules/bl/BufferList.js +0 -396
  38. package/node_modules/bl/LICENSE.md +0 -13
  39. package/node_modules/bl/README.md +0 -247
  40. package/node_modules/bl/bl.js +0 -84
  41. package/node_modules/bl/package.json +0 -37
  42. package/node_modules/bl/test/convert.js +0 -21
  43. package/node_modules/bl/test/indexOf.js +0 -492
  44. package/node_modules/bl/test/isBufferList.js +0 -32
  45. package/node_modules/bl/test/test.js +0 -869
  46. package/node_modules/brace-expansion/LICENSE +0 -23
  47. package/node_modules/brace-expansion/README.md +0 -94
  48. package/node_modules/brace-expansion/dist/commonjs/index.d.ts +0 -6
  49. package/node_modules/brace-expansion/dist/commonjs/index.d.ts.map +0 -1
  50. package/node_modules/brace-expansion/dist/commonjs/index.js +0 -199
  51. package/node_modules/brace-expansion/dist/commonjs/index.js.map +0 -1
  52. package/node_modules/brace-expansion/dist/commonjs/package.json +0 -3
  53. package/node_modules/brace-expansion/dist/esm/index.d.ts +0 -6
  54. package/node_modules/brace-expansion/dist/esm/index.d.ts.map +0 -1
  55. package/node_modules/brace-expansion/dist/esm/index.js +0 -195
  56. package/node_modules/brace-expansion/dist/esm/index.js.map +0 -1
  57. package/node_modules/brace-expansion/dist/esm/package.json +0 -3
  58. package/node_modules/brace-expansion/package.json +0 -64
  59. package/node_modules/buffer/AUTHORS.md +0 -70
  60. package/node_modules/buffer/LICENSE +0 -21
  61. package/node_modules/buffer/README.md +0 -410
  62. package/node_modules/buffer/index.d.ts +0 -186
  63. package/node_modules/buffer/index.js +0 -1817
  64. package/node_modules/buffer/package.json +0 -96
  65. package/node_modules/chalk/index.d.ts +0 -415
  66. package/node_modules/chalk/license +0 -9
  67. package/node_modules/chalk/package.json +0 -68
  68. package/node_modules/chalk/readme.md +0 -341
  69. package/node_modules/chalk/source/index.js +0 -229
  70. package/node_modules/chalk/source/templates.js +0 -134
  71. package/node_modules/chalk/source/util.js +0 -39
  72. package/node_modules/cli-cursor/index.d.ts +0 -45
  73. package/node_modules/cli-cursor/index.js +0 -35
  74. package/node_modules/cli-cursor/license +0 -9
  75. package/node_modules/cli-cursor/package.json +0 -46
  76. package/node_modules/cli-cursor/readme.md +0 -55
  77. package/node_modules/cli-spinners/index.d.ts +0 -128
  78. package/node_modules/cli-spinners/index.js +0 -15
  79. package/node_modules/cli-spinners/license +0 -9
  80. package/node_modules/cli-spinners/package.json +0 -50
  81. package/node_modules/cli-spinners/readme.md +0 -54
  82. package/node_modules/cli-spinners/spinners.json +0 -1622
  83. package/node_modules/clone/.npmignore +0 -4
  84. package/node_modules/clone/LICENSE +0 -18
  85. package/node_modules/clone/README.md +0 -126
  86. package/node_modules/clone/clone.iml +0 -10
  87. package/node_modules/clone/clone.js +0 -166
  88. package/node_modules/clone/package.json +0 -51
  89. package/node_modules/color-convert/CHANGELOG.md +0 -54
  90. package/node_modules/color-convert/LICENSE +0 -21
  91. package/node_modules/color-convert/README.md +0 -68
  92. package/node_modules/color-convert/conversions.js +0 -839
  93. package/node_modules/color-convert/index.js +0 -81
  94. package/node_modules/color-convert/package.json +0 -48
  95. package/node_modules/color-convert/route.js +0 -97
  96. package/node_modules/color-name/LICENSE +0 -8
  97. package/node_modules/color-name/README.md +0 -11
  98. package/node_modules/color-name/index.js +0 -152
  99. package/node_modules/color-name/package.json +0 -28
  100. package/node_modules/commander/LICENSE +0 -22
  101. package/node_modules/commander/Readme.md +0 -1176
  102. package/node_modules/commander/esm.mjs +0 -16
  103. package/node_modules/commander/index.js +0 -24
  104. package/node_modules/commander/lib/argument.js +0 -150
  105. package/node_modules/commander/lib/command.js +0 -2777
  106. package/node_modules/commander/lib/error.js +0 -39
  107. package/node_modules/commander/lib/help.js +0 -747
  108. package/node_modules/commander/lib/option.js +0 -380
  109. package/node_modules/commander/lib/suggestSimilar.js +0 -101
  110. package/node_modules/commander/package-support.json +0 -19
  111. package/node_modules/commander/package.json +0 -82
  112. package/node_modules/commander/typings/esm.d.mts +0 -3
  113. package/node_modules/commander/typings/index.d.ts +0 -1113
  114. package/node_modules/data-uri-to-buffer/README.md +0 -88
  115. package/node_modules/data-uri-to-buffer/dist/index.d.ts +0 -15
  116. package/node_modules/data-uri-to-buffer/dist/index.js +0 -53
  117. package/node_modules/data-uri-to-buffer/dist/index.js.map +0 -1
  118. package/node_modules/data-uri-to-buffer/package.json +0 -62
  119. package/node_modules/data-uri-to-buffer/src/index.ts +0 -68
  120. package/node_modules/defaults/LICENSE +0 -22
  121. package/node_modules/defaults/README.md +0 -39
  122. package/node_modules/defaults/index.js +0 -13
  123. package/node_modules/defaults/package.json +0 -33
  124. package/node_modules/defaults/test.js +0 -34
  125. package/node_modules/fetch-blob/LICENSE +0 -21
  126. package/node_modules/fetch-blob/README.md +0 -106
  127. package/node_modules/fetch-blob/file.d.ts +0 -2
  128. package/node_modules/fetch-blob/file.js +0 -49
  129. package/node_modules/fetch-blob/from.d.ts +0 -26
  130. package/node_modules/fetch-blob/from.js +0 -100
  131. package/node_modules/fetch-blob/index.d.ts +0 -3
  132. package/node_modules/fetch-blob/index.js +0 -250
  133. package/node_modules/fetch-blob/package.json +0 -56
  134. package/node_modules/fetch-blob/streams.cjs +0 -51
  135. package/node_modules/formdata-polyfill/FormData.js +0 -441
  136. package/node_modules/formdata-polyfill/LICENSE +0 -21
  137. package/node_modules/formdata-polyfill/README.md +0 -145
  138. package/node_modules/formdata-polyfill/esm.min.d.ts +0 -5
  139. package/node_modules/formdata-polyfill/esm.min.js +0 -40
  140. package/node_modules/formdata-polyfill/formdata-to-blob.js +0 -39
  141. package/node_modules/formdata-polyfill/formdata.min.js +0 -21
  142. package/node_modules/formdata-polyfill/package.json +0 -50
  143. package/node_modules/glob/LICENSE.md +0 -63
  144. package/node_modules/glob/README.md +0 -1203
  145. package/node_modules/glob/dist/commonjs/glob.d.ts +0 -396
  146. package/node_modules/glob/dist/commonjs/glob.d.ts.map +0 -1
  147. package/node_modules/glob/dist/commonjs/glob.js +0 -248
  148. package/node_modules/glob/dist/commonjs/glob.js.map +0 -1
  149. package/node_modules/glob/dist/commonjs/has-magic.d.ts +0 -14
  150. package/node_modules/glob/dist/commonjs/has-magic.d.ts.map +0 -1
  151. package/node_modules/glob/dist/commonjs/has-magic.js +0 -27
  152. package/node_modules/glob/dist/commonjs/has-magic.js.map +0 -1
  153. package/node_modules/glob/dist/commonjs/ignore.d.ts +0 -24
  154. package/node_modules/glob/dist/commonjs/ignore.d.ts.map +0 -1
  155. package/node_modules/glob/dist/commonjs/ignore.js +0 -119
  156. package/node_modules/glob/dist/commonjs/ignore.js.map +0 -1
  157. package/node_modules/glob/dist/commonjs/index.d.ts +0 -97
  158. package/node_modules/glob/dist/commonjs/index.d.ts.map +0 -1
  159. package/node_modules/glob/dist/commonjs/index.js +0 -68
  160. package/node_modules/glob/dist/commonjs/index.js.map +0 -1
  161. package/node_modules/glob/dist/commonjs/index.min.js +0 -4
  162. package/node_modules/glob/dist/commonjs/index.min.js.map +0 -7
  163. package/node_modules/glob/dist/commonjs/package.json +0 -3
  164. package/node_modules/glob/dist/commonjs/pattern.d.ts +0 -79
  165. package/node_modules/glob/dist/commonjs/pattern.d.ts.map +0 -1
  166. package/node_modules/glob/dist/commonjs/pattern.js +0 -223
  167. package/node_modules/glob/dist/commonjs/pattern.js.map +0 -1
  168. package/node_modules/glob/dist/commonjs/processor.d.ts +0 -59
  169. package/node_modules/glob/dist/commonjs/processor.d.ts.map +0 -1
  170. package/node_modules/glob/dist/commonjs/processor.js +0 -301
  171. package/node_modules/glob/dist/commonjs/processor.js.map +0 -1
  172. package/node_modules/glob/dist/commonjs/walker.d.ts +0 -97
  173. package/node_modules/glob/dist/commonjs/walker.d.ts.map +0 -1
  174. package/node_modules/glob/dist/commonjs/walker.js +0 -387
  175. package/node_modules/glob/dist/commonjs/walker.js.map +0 -1
  176. package/node_modules/glob/dist/esm/glob.d.ts +0 -396
  177. package/node_modules/glob/dist/esm/glob.d.ts.map +0 -1
  178. package/node_modules/glob/dist/esm/glob.js +0 -244
  179. package/node_modules/glob/dist/esm/glob.js.map +0 -1
  180. package/node_modules/glob/dist/esm/has-magic.d.ts +0 -14
  181. package/node_modules/glob/dist/esm/has-magic.d.ts.map +0 -1
  182. package/node_modules/glob/dist/esm/has-magic.js +0 -23
  183. package/node_modules/glob/dist/esm/has-magic.js.map +0 -1
  184. package/node_modules/glob/dist/esm/ignore.d.ts +0 -24
  185. package/node_modules/glob/dist/esm/ignore.d.ts.map +0 -1
  186. package/node_modules/glob/dist/esm/ignore.js +0 -115
  187. package/node_modules/glob/dist/esm/ignore.js.map +0 -1
  188. package/node_modules/glob/dist/esm/index.d.ts +0 -97
  189. package/node_modules/glob/dist/esm/index.d.ts.map +0 -1
  190. package/node_modules/glob/dist/esm/index.js +0 -55
  191. package/node_modules/glob/dist/esm/index.js.map +0 -1
  192. package/node_modules/glob/dist/esm/index.min.js +0 -4
  193. package/node_modules/glob/dist/esm/index.min.js.map +0 -7
  194. package/node_modules/glob/dist/esm/package.json +0 -3
  195. package/node_modules/glob/dist/esm/pattern.d.ts +0 -79
  196. package/node_modules/glob/dist/esm/pattern.d.ts.map +0 -1
  197. package/node_modules/glob/dist/esm/pattern.js +0 -219
  198. package/node_modules/glob/dist/esm/pattern.js.map +0 -1
  199. package/node_modules/glob/dist/esm/processor.d.ts +0 -59
  200. package/node_modules/glob/dist/esm/processor.d.ts.map +0 -1
  201. package/node_modules/glob/dist/esm/processor.js +0 -294
  202. package/node_modules/glob/dist/esm/processor.js.map +0 -1
  203. package/node_modules/glob/dist/esm/walker.d.ts +0 -97
  204. package/node_modules/glob/dist/esm/walker.d.ts.map +0 -1
  205. package/node_modules/glob/dist/esm/walker.js +0 -381
  206. package/node_modules/glob/dist/esm/walker.js.map +0 -1
  207. package/node_modules/glob/package.json +0 -98
  208. package/node_modules/has-flag/index.d.ts +0 -39
  209. package/node_modules/has-flag/index.js +0 -8
  210. package/node_modules/has-flag/license +0 -9
  211. package/node_modules/has-flag/package.json +0 -46
  212. package/node_modules/has-flag/readme.md +0 -89
  213. package/node_modules/ieee754/LICENSE +0 -11
  214. package/node_modules/ieee754/README.md +0 -51
  215. package/node_modules/ieee754/index.d.ts +0 -10
  216. package/node_modules/ieee754/index.js +0 -85
  217. package/node_modules/ieee754/package.json +0 -52
  218. package/node_modules/inherits/LICENSE +0 -16
  219. package/node_modules/inherits/README.md +0 -42
  220. package/node_modules/inherits/inherits.js +0 -9
  221. package/node_modules/inherits/inherits_browser.js +0 -27
  222. package/node_modules/inherits/package.json +0 -29
  223. package/node_modules/is-interactive/index.d.ts +0 -31
  224. package/node_modules/is-interactive/index.js +0 -9
  225. package/node_modules/is-interactive/license +0 -9
  226. package/node_modules/is-interactive/package.json +0 -38
  227. package/node_modules/is-interactive/readme.md +0 -51
  228. package/node_modules/is-unicode-supported/index.d.ts +0 -14
  229. package/node_modules/is-unicode-supported/index.js +0 -13
  230. package/node_modules/is-unicode-supported/license +0 -9
  231. package/node_modules/is-unicode-supported/package.json +0 -41
  232. package/node_modules/is-unicode-supported/readme.md +0 -35
  233. package/node_modules/log-symbols/browser.js +0 -8
  234. package/node_modules/log-symbols/index.d.ts +0 -25
  235. package/node_modules/log-symbols/index.js +0 -19
  236. package/node_modules/log-symbols/license +0 -9
  237. package/node_modules/log-symbols/package.json +0 -52
  238. package/node_modules/log-symbols/readme.md +0 -51
  239. package/node_modules/lru-cache/LICENSE.md +0 -55
  240. package/node_modules/lru-cache/README.md +0 -383
  241. package/node_modules/lru-cache/dist/commonjs/index.d.ts +0 -1323
  242. package/node_modules/lru-cache/dist/commonjs/index.d.ts.map +0 -1
  243. package/node_modules/lru-cache/dist/commonjs/index.js +0 -1595
  244. package/node_modules/lru-cache/dist/commonjs/index.js.map +0 -1
  245. package/node_modules/lru-cache/dist/commonjs/index.min.js +0 -2
  246. package/node_modules/lru-cache/dist/commonjs/index.min.js.map +0 -7
  247. package/node_modules/lru-cache/dist/commonjs/package.json +0 -3
  248. package/node_modules/lru-cache/dist/esm/index.d.ts +0 -1323
  249. package/node_modules/lru-cache/dist/esm/index.d.ts.map +0 -1
  250. package/node_modules/lru-cache/dist/esm/index.js +0 -1591
  251. package/node_modules/lru-cache/dist/esm/index.js.map +0 -1
  252. package/node_modules/lru-cache/dist/esm/index.min.js +0 -2
  253. package/node_modules/lru-cache/dist/esm/index.min.js.map +0 -7
  254. package/node_modules/lru-cache/dist/esm/package.json +0 -3
  255. package/node_modules/lru-cache/package.json +0 -93
  256. package/node_modules/mimic-fn/index.d.ts +0 -54
  257. package/node_modules/mimic-fn/index.js +0 -13
  258. package/node_modules/mimic-fn/license +0 -9
  259. package/node_modules/mimic-fn/package.json +0 -42
  260. package/node_modules/mimic-fn/readme.md +0 -69
  261. package/node_modules/minimatch/LICENSE.md +0 -55
  262. package/node_modules/minimatch/README.md +0 -528
  263. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.d.ts +0 -2
  264. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.d.ts.map +0 -1
  265. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js +0 -14
  266. package/node_modules/minimatch/dist/commonjs/assert-valid-pattern.js.map +0 -1
  267. package/node_modules/minimatch/dist/commonjs/ast.d.ts +0 -22
  268. package/node_modules/minimatch/dist/commonjs/ast.d.ts.map +0 -1
  269. package/node_modules/minimatch/dist/commonjs/ast.js +0 -846
  270. package/node_modules/minimatch/dist/commonjs/ast.js.map +0 -1
  271. package/node_modules/minimatch/dist/commonjs/brace-expressions.d.ts +0 -8
  272. package/node_modules/minimatch/dist/commonjs/brace-expressions.d.ts.map +0 -1
  273. package/node_modules/minimatch/dist/commonjs/brace-expressions.js +0 -150
  274. package/node_modules/minimatch/dist/commonjs/brace-expressions.js.map +0 -1
  275. package/node_modules/minimatch/dist/commonjs/escape.d.ts +0 -15
  276. package/node_modules/minimatch/dist/commonjs/escape.d.ts.map +0 -1
  277. package/node_modules/minimatch/dist/commonjs/escape.js +0 -30
  278. package/node_modules/minimatch/dist/commonjs/escape.js.map +0 -1
  279. package/node_modules/minimatch/dist/commonjs/index.d.ts +0 -174
  280. package/node_modules/minimatch/dist/commonjs/index.d.ts.map +0 -1
  281. package/node_modules/minimatch/dist/commonjs/index.js +0 -1121
  282. package/node_modules/minimatch/dist/commonjs/index.js.map +0 -1
  283. package/node_modules/minimatch/dist/commonjs/package.json +0 -3
  284. package/node_modules/minimatch/dist/commonjs/unescape.d.ts +0 -22
  285. package/node_modules/minimatch/dist/commonjs/unescape.d.ts.map +0 -1
  286. package/node_modules/minimatch/dist/commonjs/unescape.js +0 -38
  287. package/node_modules/minimatch/dist/commonjs/unescape.js.map +0 -1
  288. package/node_modules/minimatch/dist/esm/assert-valid-pattern.d.ts +0 -2
  289. package/node_modules/minimatch/dist/esm/assert-valid-pattern.d.ts.map +0 -1
  290. package/node_modules/minimatch/dist/esm/assert-valid-pattern.js +0 -10
  291. package/node_modules/minimatch/dist/esm/assert-valid-pattern.js.map +0 -1
  292. package/node_modules/minimatch/dist/esm/ast.d.ts +0 -22
  293. package/node_modules/minimatch/dist/esm/ast.d.ts.map +0 -1
  294. package/node_modules/minimatch/dist/esm/ast.js +0 -842
  295. package/node_modules/minimatch/dist/esm/ast.js.map +0 -1
  296. package/node_modules/minimatch/dist/esm/brace-expressions.d.ts +0 -8
  297. package/node_modules/minimatch/dist/esm/brace-expressions.d.ts.map +0 -1
  298. package/node_modules/minimatch/dist/esm/brace-expressions.js +0 -146
  299. package/node_modules/minimatch/dist/esm/brace-expressions.js.map +0 -1
  300. package/node_modules/minimatch/dist/esm/escape.d.ts +0 -15
  301. package/node_modules/minimatch/dist/esm/escape.d.ts.map +0 -1
  302. package/node_modules/minimatch/dist/esm/escape.js +0 -26
  303. package/node_modules/minimatch/dist/esm/escape.js.map +0 -1
  304. package/node_modules/minimatch/dist/esm/index.d.ts +0 -174
  305. package/node_modules/minimatch/dist/esm/index.d.ts.map +0 -1
  306. package/node_modules/minimatch/dist/esm/index.js +0 -1108
  307. package/node_modules/minimatch/dist/esm/index.js.map +0 -1
  308. package/node_modules/minimatch/dist/esm/package.json +0 -3
  309. package/node_modules/minimatch/dist/esm/unescape.d.ts +0 -22
  310. package/node_modules/minimatch/dist/esm/unescape.d.ts.map +0 -1
  311. package/node_modules/minimatch/dist/esm/unescape.js +0 -34
  312. package/node_modules/minimatch/dist/esm/unescape.js.map +0 -1
  313. package/node_modules/minimatch/package.json +0 -67
  314. package/node_modules/minipass/LICENSE.md +0 -55
  315. package/node_modules/minipass/README.md +0 -825
  316. package/node_modules/minipass/dist/commonjs/index.d.ts +0 -545
  317. package/node_modules/minipass/dist/commonjs/index.d.ts.map +0 -1
  318. package/node_modules/minipass/dist/commonjs/index.js +0 -1038
  319. package/node_modules/minipass/dist/commonjs/index.js.map +0 -1
  320. package/node_modules/minipass/dist/commonjs/package.json +0 -3
  321. package/node_modules/minipass/dist/esm/index.d.ts +0 -545
  322. package/node_modules/minipass/dist/esm/index.d.ts.map +0 -1
  323. package/node_modules/minipass/dist/esm/index.js +0 -1020
  324. package/node_modules/minipass/dist/esm/index.js.map +0 -1
  325. package/node_modules/minipass/dist/esm/package.json +0 -3
  326. package/node_modules/minipass/package.json +0 -77
  327. package/node_modules/node-domexception/.history/README_20210527203617.md +0 -2
  328. package/node_modules/node-domexception/.history/README_20210527212714.md +0 -41
  329. package/node_modules/node-domexception/.history/README_20210527213345.md +0 -36
  330. package/node_modules/node-domexception/.history/README_20210527213411.md +0 -36
  331. package/node_modules/node-domexception/.history/README_20210527213803.md +0 -36
  332. package/node_modules/node-domexception/.history/README_20210527214323.md +0 -38
  333. package/node_modules/node-domexception/.history/README_20210527214408.md +0 -38
  334. package/node_modules/node-domexception/.history/index_20210527203842.js +0 -0
  335. package/node_modules/node-domexception/.history/index_20210527203947.js +0 -8
  336. package/node_modules/node-domexception/.history/index_20210527204259.js +0 -9
  337. package/node_modules/node-domexception/.history/index_20210527204418.js +0 -9
  338. package/node_modules/node-domexception/.history/index_20210527204756.js +0 -11
  339. package/node_modules/node-domexception/.history/index_20210527204833.js +0 -11
  340. package/node_modules/node-domexception/.history/index_20210527211208.js +0 -15
  341. package/node_modules/node-domexception/.history/index_20210527211248.js +0 -15
  342. package/node_modules/node-domexception/.history/index_20210527212722.js +0 -23
  343. package/node_modules/node-domexception/.history/index_20210527212731.js +0 -23
  344. package/node_modules/node-domexception/.history/index_20210527212746.js +0 -15
  345. package/node_modules/node-domexception/.history/index_20210527212900.js +0 -16
  346. package/node_modules/node-domexception/.history/index_20210527213022.js +0 -16
  347. package/node_modules/node-domexception/.history/index_20210527213822.js +0 -16
  348. package/node_modules/node-domexception/.history/index_20210527213843.js +0 -17
  349. package/node_modules/node-domexception/.history/index_20210527213852.js +0 -17
  350. package/node_modules/node-domexception/.history/index_20210527213910.js +0 -16
  351. package/node_modules/node-domexception/.history/index_20210527214034.js +0 -16
  352. package/node_modules/node-domexception/.history/index_20210527214643.js +0 -41
  353. package/node_modules/node-domexception/.history/index_20210527214654.js +0 -41
  354. package/node_modules/node-domexception/.history/index_20210527214700.js +0 -16
  355. package/node_modules/node-domexception/.history/package_20210527203733.json +0 -19
  356. package/node_modules/node-domexception/.history/package_20210527203825.json +0 -16
  357. package/node_modules/node-domexception/.history/package_20210527204621.json +0 -19
  358. package/node_modules/node-domexception/.history/package_20210527204913.json +0 -25
  359. package/node_modules/node-domexception/.history/package_20210527204925.json +0 -25
  360. package/node_modules/node-domexception/.history/package_20210527205145.json +0 -29
  361. package/node_modules/node-domexception/.history/package_20210527205156.json +0 -29
  362. package/node_modules/node-domexception/.history/test_20210527205603.js +0 -0
  363. package/node_modules/node-domexception/.history/test_20210527205957.js +0 -3
  364. package/node_modules/node-domexception/.history/test_20210527210021.js +0 -3
  365. package/node_modules/node-domexception/LICENSE +0 -21
  366. package/node_modules/node-domexception/README.md +0 -46
  367. package/node_modules/node-domexception/index.js +0 -16
  368. package/node_modules/node-domexception/package.json +0 -29
  369. package/node_modules/node-fetch/@types/index.d.ts +0 -219
  370. package/node_modules/node-fetch/LICENSE.md +0 -22
  371. package/node_modules/node-fetch/README.md +0 -872
  372. package/node_modules/node-fetch/package.json +0 -131
  373. package/node_modules/node-fetch/src/body.js +0 -397
  374. package/node_modules/node-fetch/src/errors/abort-error.js +0 -10
  375. package/node_modules/node-fetch/src/errors/base.js +0 -17
  376. package/node_modules/node-fetch/src/errors/fetch-error.js +0 -26
  377. package/node_modules/node-fetch/src/headers.js +0 -267
  378. package/node_modules/node-fetch/src/index.js +0 -417
  379. package/node_modules/node-fetch/src/request.js +0 -313
  380. package/node_modules/node-fetch/src/response.js +0 -160
  381. package/node_modules/node-fetch/src/utils/get-search.js +0 -9
  382. package/node_modules/node-fetch/src/utils/is-redirect.js +0 -11
  383. package/node_modules/node-fetch/src/utils/is.js +0 -87
  384. package/node_modules/node-fetch/src/utils/multipart-parser.js +0 -432
  385. package/node_modules/node-fetch/src/utils/referrer.js +0 -340
  386. package/node_modules/onetime/index.d.ts +0 -64
  387. package/node_modules/onetime/index.js +0 -44
  388. package/node_modules/onetime/license +0 -9
  389. package/node_modules/onetime/package.json +0 -43
  390. package/node_modules/onetime/readme.md +0 -94
  391. package/node_modules/ora/index.d.ts +0 -277
  392. package/node_modules/ora/index.js +0 -407
  393. package/node_modules/ora/license +0 -9
  394. package/node_modules/ora/package.json +0 -57
  395. package/node_modules/ora/readme.md +0 -264
  396. package/node_modules/path-scurry/LICENSE.md +0 -55
  397. package/node_modules/path-scurry/README.md +0 -636
  398. package/node_modules/path-scurry/dist/commonjs/index.d.ts +0 -1115
  399. package/node_modules/path-scurry/dist/commonjs/index.d.ts.map +0 -1
  400. package/node_modules/path-scurry/dist/commonjs/index.js +0 -2018
  401. package/node_modules/path-scurry/dist/commonjs/index.js.map +0 -1
  402. package/node_modules/path-scurry/dist/commonjs/package.json +0 -3
  403. package/node_modules/path-scurry/dist/esm/index.d.ts +0 -1115
  404. package/node_modules/path-scurry/dist/esm/index.d.ts.map +0 -1
  405. package/node_modules/path-scurry/dist/esm/index.js +0 -1983
  406. package/node_modules/path-scurry/dist/esm/index.js.map +0 -1
  407. package/node_modules/path-scurry/dist/esm/package.json +0 -3
  408. package/node_modules/path-scurry/package.json +0 -72
  409. package/node_modules/readable-stream/CONTRIBUTING.md +0 -38
  410. package/node_modules/readable-stream/GOVERNANCE.md +0 -136
  411. package/node_modules/readable-stream/LICENSE +0 -47
  412. package/node_modules/readable-stream/README.md +0 -106
  413. package/node_modules/readable-stream/errors-browser.js +0 -127
  414. package/node_modules/readable-stream/errors.js +0 -116
  415. package/node_modules/readable-stream/experimentalWarning.js +0 -17
  416. package/node_modules/readable-stream/lib/_stream_duplex.js +0 -126
  417. package/node_modules/readable-stream/lib/_stream_passthrough.js +0 -37
  418. package/node_modules/readable-stream/lib/_stream_readable.js +0 -1027
  419. package/node_modules/readable-stream/lib/_stream_transform.js +0 -190
  420. package/node_modules/readable-stream/lib/_stream_writable.js +0 -641
  421. package/node_modules/readable-stream/lib/internal/streams/async_iterator.js +0 -180
  422. package/node_modules/readable-stream/lib/internal/streams/buffer_list.js +0 -183
  423. package/node_modules/readable-stream/lib/internal/streams/destroy.js +0 -96
  424. package/node_modules/readable-stream/lib/internal/streams/end-of-stream.js +0 -86
  425. package/node_modules/readable-stream/lib/internal/streams/from-browser.js +0 -3
  426. package/node_modules/readable-stream/lib/internal/streams/from.js +0 -52
  427. package/node_modules/readable-stream/lib/internal/streams/pipeline.js +0 -86
  428. package/node_modules/readable-stream/lib/internal/streams/state.js +0 -22
  429. package/node_modules/readable-stream/lib/internal/streams/stream-browser.js +0 -1
  430. package/node_modules/readable-stream/lib/internal/streams/stream.js +0 -1
  431. package/node_modules/readable-stream/package.json +0 -68
  432. package/node_modules/readable-stream/readable-browser.js +0 -9
  433. package/node_modules/readable-stream/readable.js +0 -16
  434. package/node_modules/restore-cursor/index.d.ts +0 -13
  435. package/node_modules/restore-cursor/index.js +0 -9
  436. package/node_modules/restore-cursor/license +0 -9
  437. package/node_modules/restore-cursor/package.json +0 -52
  438. package/node_modules/restore-cursor/readme.md +0 -26
  439. package/node_modules/safe-buffer/LICENSE +0 -21
  440. package/node_modules/safe-buffer/README.md +0 -584
  441. package/node_modules/safe-buffer/index.d.ts +0 -187
  442. package/node_modules/safe-buffer/index.js +0 -65
  443. package/node_modules/safe-buffer/package.json +0 -51
  444. package/node_modules/signal-exit/LICENSE.txt +0 -16
  445. package/node_modules/signal-exit/README.md +0 -39
  446. package/node_modules/signal-exit/index.js +0 -202
  447. package/node_modules/signal-exit/package.json +0 -38
  448. package/node_modules/signal-exit/signals.js +0 -53
  449. package/node_modules/string_decoder/LICENSE +0 -48
  450. package/node_modules/string_decoder/README.md +0 -47
  451. package/node_modules/string_decoder/lib/string_decoder.js +0 -296
  452. package/node_modules/string_decoder/package.json +0 -34
  453. package/node_modules/strip-ansi/index.d.ts +0 -17
  454. package/node_modules/strip-ansi/index.js +0 -4
  455. package/node_modules/strip-ansi/license +0 -9
  456. package/node_modules/strip-ansi/package.json +0 -54
  457. package/node_modules/strip-ansi/readme.md +0 -46
  458. package/node_modules/supports-color/browser.js +0 -5
  459. package/node_modules/supports-color/index.js +0 -135
  460. package/node_modules/supports-color/license +0 -9
  461. package/node_modules/supports-color/package.json +0 -53
  462. package/node_modules/supports-color/readme.md +0 -76
  463. package/node_modules/util-deprecate/History.md +0 -16
  464. package/node_modules/util-deprecate/LICENSE +0 -24
  465. package/node_modules/util-deprecate/README.md +0 -53
  466. package/node_modules/util-deprecate/browser.js +0 -67
  467. package/node_modules/util-deprecate/node.js +0 -6
  468. package/node_modules/util-deprecate/package.json +0 -27
  469. package/node_modules/wcwidth/.npmignore +0 -1
  470. package/node_modules/wcwidth/LICENSE +0 -30
  471. package/node_modules/wcwidth/Readme.md +0 -33
  472. package/node_modules/wcwidth/combining.js +0 -50
  473. package/node_modules/wcwidth/docs/index.md +0 -65
  474. package/node_modules/wcwidth/index.js +0 -99
  475. package/node_modules/wcwidth/package.json +0 -42
  476. package/node_modules/wcwidth/test/index.js +0 -64
  477. package/node_modules/web-streams-polyfill/LICENSE +0 -22
  478. package/node_modules/web-streams-polyfill/README.md +0 -110
  479. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.js +0 -4765
  480. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.js.map +0 -1
  481. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.min.js +0 -9
  482. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.min.js.map +0 -1
  483. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.mjs +0 -4745
  484. package/node_modules/web-streams-polyfill/dist/polyfill.es2018.mjs.map +0 -1
  485. package/node_modules/web-streams-polyfill/dist/polyfill.es6.js +0 -4838
  486. package/node_modules/web-streams-polyfill/dist/polyfill.es6.js.map +0 -1
  487. package/node_modules/web-streams-polyfill/dist/polyfill.es6.min.js +0 -9
  488. package/node_modules/web-streams-polyfill/dist/polyfill.es6.min.js.map +0 -1
  489. package/node_modules/web-streams-polyfill/dist/polyfill.es6.mjs +0 -4818
  490. package/node_modules/web-streams-polyfill/dist/polyfill.es6.mjs.map +0 -1
  491. package/node_modules/web-streams-polyfill/dist/polyfill.js +0 -5011
  492. package/node_modules/web-streams-polyfill/dist/polyfill.js.map +0 -1
  493. package/node_modules/web-streams-polyfill/dist/polyfill.min.js +0 -9
  494. package/node_modules/web-streams-polyfill/dist/polyfill.min.js.map +0 -1
  495. package/node_modules/web-streams-polyfill/dist/polyfill.mjs +0 -4991
  496. package/node_modules/web-streams-polyfill/dist/polyfill.mjs.map +0 -1
  497. package/node_modules/web-streams-polyfill/dist/ponyfill.es2018.js +0 -4737
  498. package/node_modules/web-streams-polyfill/dist/ponyfill.es2018.js.map +0 -1
  499. package/node_modules/web-streams-polyfill/dist/ponyfill.es2018.mjs +0 -4717
  500. package/node_modules/web-streams-polyfill/dist/ponyfill.es2018.mjs.map +0 -1
  501. package/node_modules/web-streams-polyfill/dist/ponyfill.es6.js +0 -4810
  502. package/node_modules/web-streams-polyfill/dist/ponyfill.es6.js.map +0 -1
  503. package/node_modules/web-streams-polyfill/dist/ponyfill.es6.mjs +0 -4790
  504. package/node_modules/web-streams-polyfill/dist/ponyfill.es6.mjs.map +0 -1
  505. package/node_modules/web-streams-polyfill/dist/ponyfill.js +0 -4983
  506. package/node_modules/web-streams-polyfill/dist/ponyfill.js.map +0 -1
  507. package/node_modules/web-streams-polyfill/dist/ponyfill.mjs +0 -4963
  508. package/node_modules/web-streams-polyfill/dist/ponyfill.mjs.map +0 -1
  509. package/node_modules/web-streams-polyfill/dist/types/polyfill.d.ts +0 -24
  510. package/node_modules/web-streams-polyfill/dist/types/ponyfill.d.ts +0 -780
  511. package/node_modules/web-streams-polyfill/dist/types/ts3.6/polyfill.d.ts +0 -28
  512. package/node_modules/web-streams-polyfill/dist/types/ts3.6/ponyfill.d.ts +0 -821
  513. package/node_modules/web-streams-polyfill/dist/types/tsdoc-metadata.json +0 -11
  514. package/node_modules/web-streams-polyfill/es2018/package.json +0 -14
  515. package/node_modules/web-streams-polyfill/es6/package.json +0 -14
  516. package/node_modules/web-streams-polyfill/package.json +0 -83
  517. package/node_modules/web-streams-polyfill/ponyfill/es2018/package.json +0 -13
  518. package/node_modules/web-streams-polyfill/ponyfill/es6/package.json +0 -13
  519. package/node_modules/web-streams-polyfill/ponyfill/package.json +0 -13
  520. package/src/commands/policy.ts +0 -146
  521. package/test-policy.md +0 -55
  522. package/test_cli.ts +0 -16
  523. package/version.json +0 -18
@@ -1,1113 +0,0 @@
1
- // Type definitions for commander
2
- // Original definitions by: Alan Agius <https://github.com/alan-agius4>, Marcelo Dezem <https://github.com/mdezem>, vvakame <https://github.com/vvakame>, Jules Randolph <https://github.com/sveinburne>
3
-
4
- /* eslint-disable @typescript-eslint/no-explicit-any */
5
-
6
- // This is a trick to encourage editor to suggest the known literals while still
7
- // allowing any BaseType value.
8
- // References:
9
- // - https://github.com/microsoft/TypeScript/issues/29729
10
- // - https://github.com/sindresorhus/type-fest/blob/main/source/literal-union.d.ts
11
- // - https://github.com/sindresorhus/type-fest/blob/main/source/primitive.d.ts
12
- type LiteralUnion<LiteralType, BaseType extends string | number> =
13
- | LiteralType
14
- | (BaseType & Record<never, never>);
15
-
16
- export class CommanderError extends Error {
17
- code: string;
18
- exitCode: number;
19
- message: string;
20
- nestedError?: string;
21
-
22
- /**
23
- * Constructs the CommanderError class
24
- * @param exitCode - suggested exit code which could be used with process.exit
25
- * @param code - an id string representing the error
26
- * @param message - human-readable description of the error
27
- */
28
- constructor(exitCode: number, code: string, message: string);
29
- }
30
-
31
- export class InvalidArgumentError extends CommanderError {
32
- /**
33
- * Constructs the InvalidArgumentError class
34
- * @param message - explanation of why argument is invalid
35
- */
36
- constructor(message: string);
37
- }
38
- export { InvalidArgumentError as InvalidOptionArgumentError }; // deprecated old name
39
-
40
- export interface ErrorOptions {
41
- // optional parameter for error()
42
- /** an id string representing the error */
43
- code?: string;
44
- /** suggested exit code which could be used with process.exit */
45
- exitCode?: number;
46
- }
47
-
48
- export class Argument {
49
- description: string;
50
- required: boolean;
51
- variadic: boolean;
52
- defaultValue?: any;
53
- defaultValueDescription?: string;
54
- parseArg?: <T>(value: string, previous: T) => T;
55
- argChoices?: string[];
56
-
57
- /**
58
- * Initialize a new command argument with the given name and description.
59
- * The default is that the argument is required, and you can explicitly
60
- * indicate this with <> around the name. Put [] around the name for an optional argument.
61
- */
62
- constructor(arg: string, description?: string);
63
-
64
- /**
65
- * Return argument name.
66
- */
67
- name(): string;
68
-
69
- /**
70
- * Set the default value, and optionally supply the description to be displayed in the help.
71
- */
72
- default(value: unknown, description?: string): this;
73
-
74
- /**
75
- * Set the custom handler for processing CLI command arguments into argument values.
76
- */
77
- argParser<T>(fn: (value: string, previous: T) => T): this;
78
-
79
- /**
80
- * Only allow argument value to be one of choices.
81
- */
82
- choices(values: readonly string[]): this;
83
-
84
- /**
85
- * Make argument required.
86
- */
87
- argRequired(): this;
88
-
89
- /**
90
- * Make argument optional.
91
- */
92
- argOptional(): this;
93
- }
94
-
95
- export class Option {
96
- flags: string;
97
- description: string;
98
-
99
- required: boolean; // A value must be supplied when the option is specified.
100
- optional: boolean; // A value is optional when the option is specified.
101
- variadic: boolean;
102
- mandatory: boolean; // The option must have a value after parsing, which usually means it must be specified on command line.
103
- short?: string;
104
- long?: string;
105
- negate: boolean;
106
- defaultValue?: any;
107
- defaultValueDescription?: string;
108
- presetArg?: unknown;
109
- envVar?: string;
110
- parseArg?: <T>(value: string, previous: T) => T;
111
- hidden: boolean;
112
- argChoices?: string[];
113
- helpGroupHeading?: string;
114
-
115
- constructor(flags: string, description?: string);
116
-
117
- /**
118
- * Set the default value, and optionally supply the description to be displayed in the help.
119
- */
120
- default(value: unknown, description?: string): this;
121
-
122
- /**
123
- * Preset to use when option used without option-argument, especially optional but also boolean and negated.
124
- * The custom processing (parseArg) is called.
125
- *
126
- * @example
127
- * ```ts
128
- * new Option('--color').default('GREYSCALE').preset('RGB');
129
- * new Option('--donate [amount]').preset('20').argParser(parseFloat);
130
- * ```
131
- */
132
- preset(arg: unknown): this;
133
-
134
- /**
135
- * Add option name(s) that conflict with this option.
136
- * An error will be displayed if conflicting options are found during parsing.
137
- *
138
- * @example
139
- * ```ts
140
- * new Option('--rgb').conflicts('cmyk');
141
- * new Option('--js').conflicts(['ts', 'jsx']);
142
- * ```
143
- */
144
- conflicts(names: string | string[]): this;
145
-
146
- /**
147
- * Specify implied option values for when this option is set and the implied options are not.
148
- *
149
- * The custom processing (parseArg) is not called on the implied values.
150
- *
151
- * @example
152
- * program
153
- * .addOption(new Option('--log', 'write logging information to file'))
154
- * .addOption(new Option('--trace', 'log extra details').implies({ log: 'trace.txt' }));
155
- */
156
- implies(optionValues: OptionValues): this;
157
-
158
- /**
159
- * Set environment variable to check for option value.
160
- *
161
- * An environment variables is only used if when processed the current option value is
162
- * undefined, or the source of the current value is 'default' or 'config' or 'env'.
163
- */
164
- env(name: string): this;
165
-
166
- /**
167
- * Set the custom handler for processing CLI option arguments into option values.
168
- */
169
- argParser<T>(fn: (value: string, previous: T) => T): this;
170
-
171
- /**
172
- * Whether the option is mandatory and must have a value after parsing.
173
- */
174
- makeOptionMandatory(mandatory?: boolean): this;
175
-
176
- /**
177
- * Hide option in help.
178
- */
179
- hideHelp(hide?: boolean): this;
180
-
181
- /**
182
- * Only allow option value to be one of choices.
183
- */
184
- choices(values: readonly string[]): this;
185
-
186
- /**
187
- * Return option name.
188
- */
189
- name(): string;
190
-
191
- /**
192
- * Return option name, in a camelcase format that can be used
193
- * as an object attribute key.
194
- */
195
- attributeName(): string;
196
-
197
- /**
198
- * Set the help group heading.
199
- */
200
- helpGroup(heading: string): this;
201
-
202
- /**
203
- * Return whether a boolean option.
204
- *
205
- * Options are one of boolean, negated, required argument, or optional argument.
206
- */
207
- isBoolean(): boolean;
208
- }
209
-
210
- export class Help {
211
- /** output helpWidth, long lines are wrapped to fit */
212
- helpWidth?: number;
213
- minWidthToWrap: number;
214
- sortSubcommands: boolean;
215
- sortOptions: boolean;
216
- showGlobalOptions: boolean;
217
-
218
- constructor();
219
-
220
- /*
221
- * prepareContext is called by Commander after applying overrides from `Command.configureHelp()`
222
- * and just before calling `formatHelp()`.
223
- *
224
- * Commander just uses the helpWidth and the others are provided for subclasses.
225
- */
226
- prepareContext(contextOptions: {
227
- error?: boolean;
228
- helpWidth?: number;
229
- outputHasColors?: boolean;
230
- }): void;
231
-
232
- /** Get the command term to show in the list of subcommands. */
233
- subcommandTerm(cmd: Command): string;
234
- /** Get the command summary to show in the list of subcommands. */
235
- subcommandDescription(cmd: Command): string;
236
- /** Get the option term to show in the list of options. */
237
- optionTerm(option: Option): string;
238
- /** Get the option description to show in the list of options. */
239
- optionDescription(option: Option): string;
240
- /** Get the argument term to show in the list of arguments. */
241
- argumentTerm(argument: Argument): string;
242
- /** Get the argument description to show in the list of arguments. */
243
- argumentDescription(argument: Argument): string;
244
-
245
- /** Get the command usage to be displayed at the top of the built-in help. */
246
- commandUsage(cmd: Command): string;
247
- /** Get the description for the command. */
248
- commandDescription(cmd: Command): string;
249
-
250
- /** Get an array of the visible subcommands. Includes a placeholder for the implicit help command, if there is one. */
251
- visibleCommands(cmd: Command): Command[];
252
- /** Get an array of the visible options. Includes a placeholder for the implicit help option, if there is one. */
253
- visibleOptions(cmd: Command): Option[];
254
- /** Get an array of the visible global options. (Not including help.) */
255
- visibleGlobalOptions(cmd: Command): Option[];
256
- /** Get an array of the arguments which have descriptions. */
257
- visibleArguments(cmd: Command): Argument[];
258
-
259
- /** Get the longest command term length. */
260
- longestSubcommandTermLength(cmd: Command, helper: Help): number;
261
- /** Get the longest option term length. */
262
- longestOptionTermLength(cmd: Command, helper: Help): number;
263
- /** Get the longest global option term length. */
264
- longestGlobalOptionTermLength(cmd: Command, helper: Help): number;
265
- /** Get the longest argument term length. */
266
- longestArgumentTermLength(cmd: Command, helper: Help): number;
267
-
268
- /** Return display width of string, ignoring ANSI escape sequences. Used in padding and wrapping calculations. */
269
- displayWidth(str: string): number;
270
-
271
- /** Style the titles. Called with 'Usage:', 'Options:', etc. */
272
- styleTitle(title: string): string;
273
-
274
- /** Usage: <str> */
275
- styleUsage(str: string): string;
276
- /** Style for command name in usage string. */
277
- styleCommandText(str: string): string;
278
-
279
- styleCommandDescription(str: string): string;
280
- styleOptionDescription(str: string): string;
281
- styleSubcommandDescription(str: string): string;
282
- styleArgumentDescription(str: string): string;
283
- /** Base style used by descriptions. */
284
- styleDescriptionText(str: string): string;
285
-
286
- styleOptionTerm(str: string): string;
287
- styleSubcommandTerm(str: string): string;
288
- styleArgumentTerm(str: string): string;
289
-
290
- /** Base style used in terms and usage for options. */
291
- styleOptionText(str: string): string;
292
- /** Base style used in terms and usage for subcommands. */
293
- styleSubcommandText(str: string): string;
294
- /** Base style used in terms and usage for arguments. */
295
- styleArgumentText(str: string): string;
296
-
297
- /** Calculate the pad width from the maximum term length. */
298
- padWidth(cmd: Command, helper: Help): number;
299
-
300
- /**
301
- * Wrap a string at whitespace, preserving existing line breaks.
302
- * Wrapping is skipped if the width is less than `minWidthToWrap`.
303
- */
304
- boxWrap(str: string, width: number): string;
305
-
306
- /** Detect manually wrapped and indented strings by checking for line break followed by whitespace. */
307
- preformatted(str: string): boolean;
308
-
309
- /**
310
- * Format the "item", which consists of a term and description. Pad the term and wrap the description, indenting the following lines.
311
- *
312
- * So "TTT", 5, "DDD DDDD DD DDD" might be formatted for this.helpWidth=17 like so:
313
- * TTT DDD DDDD
314
- * DD DDD
315
- */
316
- formatItem(
317
- term: string,
318
- termWidth: number,
319
- description: string,
320
- helper: Help,
321
- ): string;
322
-
323
- /**
324
- * Format a list of items, given a heading and an array of formatted items.
325
- */
326
- formatItemList(heading: string, items: string[], helper: Help): string[];
327
-
328
- /**
329
- * Group items by their help group heading.
330
- */
331
- groupItems<T extends Command | Option>(
332
- unsortedItems: T[],
333
- visibleItems: T[],
334
- getGroup: (item: T) => string,
335
- ): Map<string, T[]>;
336
-
337
- /** Generate the built-in help text. */
338
- formatHelp(cmd: Command, helper: Help): string;
339
- }
340
- export type HelpConfiguration = Partial<Help>;
341
-
342
- export interface ParseOptions {
343
- from: 'node' | 'electron' | 'user';
344
- }
345
- export interface HelpContext {
346
- // optional parameter for .help() and .outputHelp()
347
- error: boolean;
348
- }
349
- export interface AddHelpTextContext {
350
- // passed to text function used with .addHelpText()
351
- error: boolean;
352
- command: Command;
353
- }
354
- export interface OutputConfiguration {
355
- writeOut?(str: string): void;
356
- writeErr?(str: string): void;
357
- outputError?(str: string, write: (str: string) => void): void;
358
-
359
- getOutHelpWidth?(): number;
360
- getErrHelpWidth?(): number;
361
-
362
- getOutHasColors?(): boolean;
363
- getErrHasColors?(): boolean;
364
- stripColor?(str: string): string;
365
- }
366
-
367
- export type AddHelpTextPosition = 'beforeAll' | 'before' | 'after' | 'afterAll';
368
- export type HookEvent = 'preSubcommand' | 'preAction' | 'postAction';
369
- // The source is a string so author can define their own too.
370
- export type OptionValueSource =
371
- | LiteralUnion<'default' | 'config' | 'env' | 'cli' | 'implied', string>
372
- | undefined;
373
-
374
- export type OptionValues = Record<string, any>;
375
-
376
- export class Command {
377
- args: string[];
378
- processedArgs: any[];
379
- readonly commands: readonly Command[];
380
- readonly options: readonly Option[];
381
- readonly registeredArguments: readonly Argument[];
382
- parent: Command | null;
383
-
384
- constructor(name?: string);
385
-
386
- /**
387
- * Set the program version to `str`.
388
- *
389
- * This method auto-registers the "-V, --version" flag
390
- * which will print the version number when passed.
391
- *
392
- * You can optionally supply the flags and description to override the defaults.
393
- */
394
- version(str: string, flags?: string, description?: string): this;
395
- /**
396
- * Get the program version.
397
- */
398
- version(): string | undefined;
399
-
400
- /**
401
- * Define a command, implemented using an action handler.
402
- *
403
- * @remarks
404
- * The command description is supplied using `.description`, not as a parameter to `.command`.
405
- *
406
- * @example
407
- * ```ts
408
- * program
409
- * .command('clone <source> [destination]')
410
- * .description('clone a repository into a newly created directory')
411
- * .action((source, destination) => {
412
- * console.log('clone command called');
413
- * });
414
- * ```
415
- *
416
- * @param nameAndArgs - command name and arguments, args are `<required>` or `[optional]` and last may also be `variadic...`
417
- * @param opts - configuration options
418
- * @returns new command
419
- */
420
- command(
421
- nameAndArgs: string,
422
- opts?: CommandOptions,
423
- ): ReturnType<this['createCommand']>;
424
- /**
425
- * Define a command, implemented in a separate executable file.
426
- *
427
- * @remarks
428
- * The command description is supplied as the second parameter to `.command`.
429
- *
430
- * @example
431
- * ```ts
432
- * program
433
- * .command('start <service>', 'start named service')
434
- * .command('stop [service]', 'stop named service, or all if no name supplied');
435
- * ```
436
- *
437
- * @param nameAndArgs - command name and arguments, args are `<required>` or `[optional]` and last may also be `variadic...`
438
- * @param description - description of executable command
439
- * @param opts - configuration options
440
- * @returns `this` command for chaining
441
- */
442
- command(
443
- nameAndArgs: string,
444
- description: string,
445
- opts?: ExecutableCommandOptions,
446
- ): this;
447
-
448
- /**
449
- * Factory routine to create a new unattached command.
450
- *
451
- * See .command() for creating an attached subcommand, which uses this routine to
452
- * create the command. You can override createCommand to customise subcommands.
453
- */
454
- createCommand(name?: string): Command;
455
-
456
- /**
457
- * Add a prepared subcommand.
458
- *
459
- * See .command() for creating an attached subcommand which inherits settings from its parent.
460
- *
461
- * @returns `this` command for chaining
462
- */
463
- addCommand(cmd: Command, opts?: CommandOptions): this;
464
-
465
- /**
466
- * Factory routine to create a new unattached argument.
467
- *
468
- * See .argument() for creating an attached argument, which uses this routine to
469
- * create the argument. You can override createArgument to return a custom argument.
470
- */
471
- createArgument(name: string, description?: string): Argument;
472
-
473
- /**
474
- * Define argument syntax for command.
475
- *
476
- * The default is that the argument is required, and you can explicitly
477
- * indicate this with <> around the name. Put [] around the name for an optional argument.
478
- *
479
- * @example
480
- * ```
481
- * program.argument('<input-file>');
482
- * program.argument('[output-file]');
483
- * ```
484
- *
485
- * @returns `this` command for chaining
486
- */
487
- argument<T>(
488
- flags: string,
489
- description: string,
490
- parseArg: (value: string, previous: T) => T,
491
- defaultValue?: T,
492
- ): this;
493
- argument(name: string, description?: string, defaultValue?: unknown): this;
494
-
495
- /**
496
- * Define argument syntax for command, adding a prepared argument.
497
- *
498
- * @returns `this` command for chaining
499
- */
500
- addArgument(arg: Argument): this;
501
-
502
- /**
503
- * Define argument syntax for command, adding multiple at once (without descriptions).
504
- *
505
- * See also .argument().
506
- *
507
- * @example
508
- * ```
509
- * program.arguments('<cmd> [env]');
510
- * ```
511
- *
512
- * @returns `this` command for chaining
513
- */
514
- arguments(names: string): this;
515
-
516
- /**
517
- * Customise or override default help command. By default a help command is automatically added if your command has subcommands.
518
- *
519
- * @example
520
- * ```ts
521
- * program.helpCommand('help [cmd]');
522
- * program.helpCommand('help [cmd]', 'show help');
523
- * program.helpCommand(false); // suppress default help command
524
- * program.helpCommand(true); // add help command even if no subcommands
525
- * ```
526
- */
527
- helpCommand(nameAndArgs: string, description?: string): this;
528
- helpCommand(enable: boolean): this;
529
-
530
- /**
531
- * Add prepared custom help command.
532
- */
533
- addHelpCommand(cmd: Command): this;
534
- /** @deprecated since v12, instead use helpCommand */
535
- addHelpCommand(nameAndArgs: string, description?: string): this;
536
- /** @deprecated since v12, instead use helpCommand */
537
- addHelpCommand(enable?: boolean): this;
538
-
539
- /**
540
- * Add hook for life cycle event.
541
- */
542
- hook(
543
- event: HookEvent,
544
- listener: (
545
- thisCommand: Command,
546
- actionCommand: Command,
547
- ) => void | Promise<void>,
548
- ): this;
549
-
550
- /**
551
- * Register callback to use as replacement for calling process.exit.
552
- */
553
- exitOverride(callback?: (err: CommanderError) => never | void): this;
554
-
555
- /**
556
- * Display error message and exit (or call exitOverride).
557
- */
558
- error(message: string, errorOptions?: ErrorOptions): never;
559
-
560
- /**
561
- * You can customise the help with a subclass of Help by overriding createHelp,
562
- * or by overriding Help properties using configureHelp().
563
- */
564
- createHelp(): Help;
565
-
566
- /**
567
- * You can customise the help by overriding Help properties using configureHelp(),
568
- * or with a subclass of Help by overriding createHelp().
569
- */
570
- configureHelp(configuration: HelpConfiguration): this;
571
- /** Get configuration */
572
- configureHelp(): HelpConfiguration;
573
-
574
- /**
575
- * The default output goes to stdout and stderr. You can customise this for special
576
- * applications. You can also customise the display of errors by overriding outputError.
577
- *
578
- * The configuration properties are all functions:
579
- * ```
580
- * // functions to change where being written, stdout and stderr
581
- * writeOut(str)
582
- * writeErr(str)
583
- * // matching functions to specify width for wrapping help
584
- * getOutHelpWidth()
585
- * getErrHelpWidth()
586
- * // functions based on what is being written out
587
- * outputError(str, write) // used for displaying errors, and not used for displaying help
588
- * ```
589
- */
590
- configureOutput(configuration: OutputConfiguration): this;
591
- /** Get configuration */
592
- configureOutput(): OutputConfiguration;
593
-
594
- /**
595
- * Copy settings that are useful to have in common across root command and subcommands.
596
- *
597
- * (Used internally when adding a command using `.command()` so subcommands inherit parent settings.)
598
- */
599
- copyInheritedSettings(sourceCommand: Command): this;
600
-
601
- /**
602
- * Display the help or a custom message after an error occurs.
603
- */
604
- showHelpAfterError(displayHelp?: boolean | string): this;
605
-
606
- /**
607
- * Display suggestion of similar commands for unknown commands, or options for unknown options.
608
- */
609
- showSuggestionAfterError(displaySuggestion?: boolean): this;
610
-
611
- /**
612
- * Register callback `fn` for the command.
613
- *
614
- * @example
615
- * ```
616
- * program
617
- * .command('serve')
618
- * .description('start service')
619
- * .action(function() {
620
- * // do work here
621
- * });
622
- * ```
623
- *
624
- * @returns `this` command for chaining
625
- */
626
- action(fn: (this: this, ...args: any[]) => void | Promise<void>): this;
627
-
628
- /**
629
- * Define option with `flags`, `description`, and optional argument parsing function or `defaultValue` or both.
630
- *
631
- * The `flags` string contains the short and/or long flags, separated by comma, a pipe or space. A required
632
- * option-argument is indicated by `<>` and an optional option-argument by `[]`.
633
- *
634
- * See the README for more details, and see also addOption() and requiredOption().
635
- *
636
- * @example
637
- *
638
- * ```js
639
- * program
640
- * .option('-p, --pepper', 'add pepper')
641
- * .option('--pt, --pizza-type <TYPE>', 'type of pizza') // required option-argument
642
- * .option('-c, --cheese [CHEESE]', 'add extra cheese', 'mozzarella') // optional option-argument with default
643
- * .option('-t, --tip <VALUE>', 'add tip to purchase cost', parseFloat) // custom parse function
644
- * ```
645
- *
646
- * @returns `this` command for chaining
647
- */
648
- option(
649
- flags: string,
650
- description?: string,
651
- defaultValue?: string | boolean | string[],
652
- ): this;
653
- option<T>(
654
- flags: string,
655
- description: string,
656
- parseArg: (value: string, previous: T) => T,
657
- defaultValue?: T,
658
- ): this;
659
- /** @deprecated since v7, instead use choices or a custom function */
660
- option(
661
- flags: string,
662
- description: string,
663
- regexp: RegExp,
664
- defaultValue?: string | boolean | string[],
665
- ): this;
666
-
667
- /**
668
- * Define a required option, which must have a value after parsing. This usually means
669
- * the option must be specified on the command line. (Otherwise the same as .option().)
670
- *
671
- * The `flags` string contains the short and/or long flags, separated by comma, a pipe or space.
672
- */
673
- requiredOption(
674
- flags: string,
675
- description?: string,
676
- defaultValue?: string | boolean | string[],
677
- ): this;
678
- requiredOption<T>(
679
- flags: string,
680
- description: string,
681
- parseArg: (value: string, previous: T) => T,
682
- defaultValue?: T,
683
- ): this;
684
- /** @deprecated since v7, instead use choices or a custom function */
685
- requiredOption(
686
- flags: string,
687
- description: string,
688
- regexp: RegExp,
689
- defaultValue?: string | boolean | string[],
690
- ): this;
691
-
692
- /**
693
- * Factory routine to create a new unattached option.
694
- *
695
- * See .option() for creating an attached option, which uses this routine to
696
- * create the option. You can override createOption to return a custom option.
697
- */
698
-
699
- createOption(flags: string, description?: string): Option;
700
-
701
- /**
702
- * Add a prepared Option.
703
- *
704
- * See .option() and .requiredOption() for creating and attaching an option in a single call.
705
- */
706
- addOption(option: Option): this;
707
-
708
- /**
709
- * Whether to store option values as properties on command object,
710
- * or store separately (specify false). In both cases the option values can be accessed using .opts().
711
- *
712
- * @returns `this` command for chaining
713
- */
714
- storeOptionsAsProperties<T extends OptionValues>(): this & T;
715
- storeOptionsAsProperties<T extends OptionValues>(
716
- storeAsProperties: true,
717
- ): this & T;
718
- storeOptionsAsProperties(storeAsProperties?: boolean): this;
719
-
720
- /**
721
- * Retrieve option value.
722
- */
723
- getOptionValue(key: string): any;
724
-
725
- /**
726
- * Store option value.
727
- */
728
- setOptionValue(key: string, value: unknown): this;
729
-
730
- /**
731
- * Store option value and where the value came from.
732
- */
733
- setOptionValueWithSource(
734
- key: string,
735
- value: unknown,
736
- source: OptionValueSource,
737
- ): this;
738
-
739
- /**
740
- * Get source of option value.
741
- */
742
- getOptionValueSource(key: string): OptionValueSource | undefined;
743
-
744
- /**
745
- * Get source of option value. See also .optsWithGlobals().
746
- */
747
- getOptionValueSourceWithGlobals(key: string): OptionValueSource | undefined;
748
-
749
- /**
750
- * Alter parsing of short flags with optional values.
751
- *
752
- * @example
753
- * ```
754
- * // for `.option('-f,--flag [value]'):
755
- * .combineFlagAndOptionalValue(true) // `-f80` is treated like `--flag=80`, this is the default behaviour
756
- * .combineFlagAndOptionalValue(false) // `-fb` is treated like `-f -b`
757
- * ```
758
- *
759
- * @returns `this` command for chaining
760
- */
761
- combineFlagAndOptionalValue(combine?: boolean): this;
762
-
763
- /**
764
- * Allow unknown options on the command line.
765
- *
766
- * @returns `this` command for chaining
767
- */
768
- allowUnknownOption(allowUnknown?: boolean): this;
769
-
770
- /**
771
- * Allow excess command-arguments on the command line. Pass false to make excess arguments an error.
772
- *
773
- * @returns `this` command for chaining
774
- */
775
- allowExcessArguments(allowExcess?: boolean): this;
776
-
777
- /**
778
- * Enable positional options. Positional means global options are specified before subcommands which lets
779
- * subcommands reuse the same option names, and also enables subcommands to turn on passThroughOptions.
780
- *
781
- * The default behaviour is non-positional and global options may appear anywhere on the command line.
782
- *
783
- * @returns `this` command for chaining
784
- */
785
- enablePositionalOptions(positional?: boolean): this;
786
-
787
- /**
788
- * Pass through options that come after command-arguments rather than treat them as command-options,
789
- * so actual command-options come before command-arguments. Turning this on for a subcommand requires
790
- * positional options to have been enabled on the program (parent commands).
791
- *
792
- * The default behaviour is non-positional and options may appear before or after command-arguments.
793
- *
794
- * @returns `this` command for chaining
795
- */
796
- passThroughOptions(passThrough?: boolean): this;
797
-
798
- /**
799
- * Parse `argv`, setting options and invoking commands when defined.
800
- *
801
- * Use parseAsync instead of parse if any of your action handlers are async.
802
- *
803
- * Call with no parameters to parse `process.argv`. Detects Electron and special node options like `node --eval`. Easy mode!
804
- *
805
- * Or call with an array of strings to parse, and optionally where the user arguments start by specifying where the arguments are `from`:
806
- * - `'node'`: default, `argv[0]` is the application and `argv[1]` is the script being run, with user arguments after that
807
- * - `'electron'`: `argv[0]` is the application and `argv[1]` varies depending on whether the electron application is packaged
808
- * - `'user'`: just user arguments
809
- *
810
- * @example
811
- * ```
812
- * program.parse(); // parse process.argv and auto-detect electron and special node flags
813
- * program.parse(process.argv); // assume argv[0] is app and argv[1] is script
814
- * program.parse(my-args, { from: 'user' }); // just user supplied arguments, nothing special about argv[0]
815
- * ```
816
- *
817
- * @returns `this` command for chaining
818
- */
819
- parse(argv?: readonly string[], parseOptions?: ParseOptions): this;
820
-
821
- /**
822
- * Parse `argv`, setting options and invoking commands when defined.
823
- *
824
- * Call with no parameters to parse `process.argv`. Detects Electron and special node options like `node --eval`. Easy mode!
825
- *
826
- * Or call with an array of strings to parse, and optionally where the user arguments start by specifying where the arguments are `from`:
827
- * - `'node'`: default, `argv[0]` is the application and `argv[1]` is the script being run, with user arguments after that
828
- * - `'electron'`: `argv[0]` is the application and `argv[1]` varies depending on whether the electron application is packaged
829
- * - `'user'`: just user arguments
830
- *
831
- * @example
832
- * ```
833
- * await program.parseAsync(); // parse process.argv and auto-detect electron and special node flags
834
- * await program.parseAsync(process.argv); // assume argv[0] is app and argv[1] is script
835
- * await program.parseAsync(my-args, { from: 'user' }); // just user supplied arguments, nothing special about argv[0]
836
- * ```
837
- *
838
- * @returns Promise
839
- */
840
- parseAsync(
841
- argv?: readonly string[],
842
- parseOptions?: ParseOptions,
843
- ): Promise<this>;
844
-
845
- /**
846
- * Called the first time parse is called to save state and allow a restore before subsequent calls to parse.
847
- * Not usually called directly, but available for subclasses to save their custom state.
848
- *
849
- * This is called in a lazy way. Only commands used in parsing chain will have state saved.
850
- */
851
- saveStateBeforeParse(): void;
852
-
853
- /**
854
- * Restore state before parse for calls after the first.
855
- * Not usually called directly, but available for subclasses to save their custom state.
856
- *
857
- * This is called in a lazy way. Only commands used in parsing chain will have state restored.
858
- */
859
- restoreStateBeforeParse(): void;
860
-
861
- /**
862
- * Parse options from `argv` removing known options,
863
- * and return argv split into operands and unknown arguments.
864
- *
865
- * Side effects: modifies command by storing options. Does not reset state if called again.
866
- *
867
- * argv => operands, unknown
868
- * --known kkk op => [op], []
869
- * op --known kkk => [op], []
870
- * sub --unknown uuu op => [sub], [--unknown uuu op]
871
- * sub -- --unknown uuu op => [sub --unknown uuu op], []
872
- */
873
- parseOptions(argv: string[]): ParseOptionsResult;
874
-
875
- /**
876
- * Return an object containing local option values as key-value pairs
877
- */
878
- opts<T extends OptionValues>(): T;
879
-
880
- /**
881
- * Return an object containing merged local and global option values as key-value pairs.
882
- */
883
- optsWithGlobals<T extends OptionValues>(): T;
884
-
885
- /**
886
- * Set the description.
887
- *
888
- * @returns `this` command for chaining
889
- */
890
-
891
- description(str: string): this;
892
- /** @deprecated since v8, instead use .argument to add command argument with description */
893
- description(str: string, argsDescription: Record<string, string>): this;
894
- /**
895
- * Get the description.
896
- */
897
- description(): string;
898
-
899
- /**
900
- * Set the summary. Used when listed as subcommand of parent.
901
- *
902
- * @returns `this` command for chaining
903
- */
904
-
905
- summary(str: string): this;
906
- /**
907
- * Get the summary.
908
- */
909
- summary(): string;
910
-
911
- /**
912
- * Set an alias for the command.
913
- *
914
- * You may call more than once to add multiple aliases. Only the first alias is shown in the auto-generated help.
915
- *
916
- * @returns `this` command for chaining
917
- */
918
- alias(alias: string): this;
919
- /**
920
- * Get alias for the command.
921
- */
922
- alias(): string;
923
-
924
- /**
925
- * Set aliases for the command.
926
- *
927
- * Only the first alias is shown in the auto-generated help.
928
- *
929
- * @returns `this` command for chaining
930
- */
931
- aliases(aliases: readonly string[]): this;
932
- /**
933
- * Get aliases for the command.
934
- */
935
- aliases(): string[];
936
-
937
- /**
938
- * Set the command usage.
939
- *
940
- * @returns `this` command for chaining
941
- */
942
- usage(str: string): this;
943
- /**
944
- * Get the command usage.
945
- */
946
- usage(): string;
947
-
948
- /**
949
- * Set the name of the command.
950
- *
951
- * @returns `this` command for chaining
952
- */
953
- name(str: string): this;
954
- /**
955
- * Get the name of the command.
956
- */
957
- name(): string;
958
-
959
- /**
960
- * Set the name of the command from script filename, such as process.argv[1],
961
- * or require.main.filename, or __filename.
962
- *
963
- * (Used internally and public although not documented in README.)
964
- *
965
- * @example
966
- * ```ts
967
- * program.nameFromFilename(require.main.filename);
968
- * ```
969
- *
970
- * @returns `this` command for chaining
971
- */
972
- nameFromFilename(filename: string): this;
973
-
974
- /**
975
- * Set the directory for searching for executable subcommands of this command.
976
- *
977
- * @example
978
- * ```ts
979
- * program.executableDir(__dirname);
980
- * // or
981
- * program.executableDir('subcommands');
982
- * ```
983
- *
984
- * @returns `this` command for chaining
985
- */
986
- executableDir(path: string): this;
987
- /**
988
- * Get the executable search directory.
989
- */
990
- executableDir(): string | null;
991
-
992
- /**
993
- * Set the help group heading for this subcommand in parent command's help.
994
- *
995
- * @returns `this` command for chaining
996
- */
997
- helpGroup(heading: string): this;
998
- /**
999
- * Get the help group heading for this subcommand in parent command's help.
1000
- */
1001
- helpGroup(): string;
1002
-
1003
- /**
1004
- * Set the default help group heading for subcommands added to this command.
1005
- * (This does not override a group set directly on the subcommand using .helpGroup().)
1006
- *
1007
- * @example
1008
- * program.commandsGroup('Development Commands:);
1009
- * program.command('watch')...
1010
- * program.command('lint')...
1011
- * ...
1012
- *
1013
- * @returns `this` command for chaining
1014
- */
1015
- commandsGroup(heading: string): this;
1016
- /**
1017
- * Get the default help group heading for subcommands added to this command.
1018
- */
1019
- commandsGroup(): string;
1020
-
1021
- /**
1022
- * Set the default help group heading for options added to this command.
1023
- * (This does not override a group set directly on the option using .helpGroup().)
1024
- *
1025
- * @example
1026
- * program
1027
- * .optionsGroup('Development Options:')
1028
- * .option('-d, --debug', 'output extra debugging')
1029
- * .option('-p, --profile', 'output profiling information')
1030
- *
1031
- * @returns `this` command for chaining
1032
- */
1033
- optionsGroup(heading: string): this;
1034
- /**
1035
- * Get the default help group heading for options added to this command.
1036
- */
1037
- optionsGroup(): string;
1038
-
1039
- /**
1040
- * Output help information for this command.
1041
- *
1042
- * Outputs built-in help, and custom text added using `.addHelpText()`.
1043
- *
1044
- */
1045
- outputHelp(context?: HelpContext): void;
1046
- /** @deprecated since v7 */
1047
- outputHelp(cb: (str: string) => string): void;
1048
-
1049
- /**
1050
- * Return command help documentation.
1051
- */
1052
- helpInformation(context?: HelpContext): string;
1053
-
1054
- /**
1055
- * You can pass in flags and a description to override the help
1056
- * flags and help description for your command. Pass in false
1057
- * to disable the built-in help option.
1058
- */
1059
- helpOption(flags?: string | boolean, description?: string): this;
1060
-
1061
- /**
1062
- * Supply your own option to use for the built-in help option.
1063
- * This is an alternative to using helpOption() to customise the flags and description etc.
1064
- */
1065
- addHelpOption(option: Option): this;
1066
-
1067
- /**
1068
- * Output help information and exit.
1069
- *
1070
- * Outputs built-in help, and custom text added using `.addHelpText()`.
1071
- */
1072
- help(context?: HelpContext): never;
1073
- /** @deprecated since v7 */
1074
- help(cb: (str: string) => string): never;
1075
-
1076
- /**
1077
- * Add additional text to be displayed with the built-in help.
1078
- *
1079
- * Position is 'before' or 'after' to affect just this command,
1080
- * and 'beforeAll' or 'afterAll' to affect this command and all its subcommands.
1081
- */
1082
- addHelpText(position: AddHelpTextPosition, text: string): this;
1083
- addHelpText(
1084
- position: AddHelpTextPosition,
1085
- text: (context: AddHelpTextContext) => string,
1086
- ): this;
1087
-
1088
- /**
1089
- * Add a listener (callback) for when events occur. (Implemented using EventEmitter.)
1090
- */
1091
- on(event: string | symbol, listener: (...args: any[]) => void): this;
1092
- }
1093
-
1094
- export interface CommandOptions {
1095
- hidden?: boolean;
1096
- isDefault?: boolean;
1097
- /** @deprecated since v7, replaced by hidden */
1098
- noHelp?: boolean;
1099
- }
1100
- export interface ExecutableCommandOptions extends CommandOptions {
1101
- executableFile?: string;
1102
- }
1103
-
1104
- export interface ParseOptionsResult {
1105
- operands: string[];
1106
- unknown: string[];
1107
- }
1108
-
1109
- export function createCommand(name?: string): Command;
1110
- export function createOption(flags: string, description?: string): Option;
1111
- export function createArgument(name: string, description?: string): Argument;
1112
-
1113
- export const program: Command;