@dotpi/tools 2.6.1 → 2.7.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 (514) hide show
  1. package/dotpi_root/dist/@dotpi/avahi-monitor-module/node_modules/.package-lock.json +7 -0
  2. package/dotpi_root/dist/@dotpi/javascript/index.js +6 -0
  3. package/dotpi_root/dist/@dotpi/javascript/node_modules/.package-lock.json +308 -0
  4. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/index.d.ts +27 -0
  5. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/index.js +28 -0
  6. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/command.js +20 -0
  7. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/cwd.js +39 -0
  8. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/encoding-option.js +50 -0
  9. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/escape.js +88 -0
  10. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/fd-options.js +108 -0
  11. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/file-url.js +25 -0
  12. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/options.js +96 -0
  13. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/arguments/specific.js +111 -0
  14. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/add.js +15 -0
  15. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/concurrent.js +33 -0
  16. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/duplex.js +69 -0
  17. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/iterable.js +34 -0
  18. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/readable.js +113 -0
  19. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/shared.js +46 -0
  20. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/convert/writable.js +90 -0
  21. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/contents.js +116 -0
  22. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/input-sync.js +44 -0
  23. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/iterate.js +110 -0
  24. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/max-buffer.js +89 -0
  25. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/output-async.js +80 -0
  26. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/output-sync.js +135 -0
  27. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/pipeline.js +48 -0
  28. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/io/strip-newline.js +12 -0
  29. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/array.js +4 -0
  30. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/buffer-messages.js +47 -0
  31. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/forward.js +56 -0
  32. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/get-each.js +89 -0
  33. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/get-one.js +69 -0
  34. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/graceful.js +72 -0
  35. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/incoming.js +79 -0
  36. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/ipc-input.js +44 -0
  37. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/methods.js +49 -0
  38. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/outgoing.js +47 -0
  39. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/reference.js +44 -0
  40. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/send.js +91 -0
  41. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/strict.js +113 -0
  42. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/ipc/validation.js +111 -0
  43. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/bind.js +23 -0
  44. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/command.js +43 -0
  45. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/create.js +65 -0
  46. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/main-async.js +193 -0
  47. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/main-sync.js +162 -0
  48. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/node.js +51 -0
  49. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/parameters.js +31 -0
  50. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/promise.js +15 -0
  51. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/script.js +22 -0
  52. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/methods/template.js +153 -0
  53. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/abort.js +20 -0
  54. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/pipe-arguments.js +91 -0
  55. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/sequence.js +24 -0
  56. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/setup.js +72 -0
  57. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/streaming.js +51 -0
  58. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/pipe/throw.js +58 -0
  59. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/all-async.js +46 -0
  60. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/all-sync.js +33 -0
  61. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/exit-async.js +54 -0
  62. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/exit-sync.js +25 -0
  63. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/stdio.js +47 -0
  64. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/wait-stream.js +96 -0
  65. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/resolve/wait-subprocess.js +146 -0
  66. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/duration.js +8 -0
  67. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/early-error.js +60 -0
  68. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/final-error.js +40 -0
  69. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/message.js +157 -0
  70. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/reject.js +13 -0
  71. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/return/result.js +186 -0
  72. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/direction.js +76 -0
  73. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/duplicate.js +116 -0
  74. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/handle-async.js +52 -0
  75. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/handle-sync.js +57 -0
  76. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/handle.js +214 -0
  77. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/input-option.js +50 -0
  78. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/native.js +106 -0
  79. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/stdio-option.js +60 -0
  80. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/stdio/type.js +173 -0
  81. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/cancel.js +20 -0
  82. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/cleanup.js +16 -0
  83. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/graceful.js +71 -0
  84. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/kill.js +93 -0
  85. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/signal.js +70 -0
  86. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/terminate/timeout.js +21 -0
  87. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/encoding-transform.js +51 -0
  88. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/generator.js +107 -0
  89. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/normalize.js +111 -0
  90. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/object-mode.js +41 -0
  91. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/run-async.js +60 -0
  92. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/run-sync.js +50 -0
  93. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/split.js +110 -0
  94. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/transform/validate.js +43 -0
  95. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/utils/abort-signal.js +8 -0
  96. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/utils/deferred.js +7 -0
  97. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/utils/max-listeners.js +14 -0
  98. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/utils/standard-stream.js +6 -0
  99. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/utils/uint-array.js +69 -0
  100. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/complete.js +24 -0
  101. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/custom.js +26 -0
  102. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/default.js +54 -0
  103. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/error.js +13 -0
  104. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/info.js +39 -0
  105. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/ipc.js +15 -0
  106. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/log.js +54 -0
  107. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/output.js +60 -0
  108. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/start.js +15 -0
  109. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/lib/verbose/values.js +33 -0
  110. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/license +9 -0
  111. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/package.json +104 -0
  112. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/readme.md +451 -0
  113. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/arguments/encoding-option.d.ts +19 -0
  114. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/arguments/fd-options.d.ts +8 -0
  115. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/arguments/options.d.ts +400 -0
  116. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/arguments/specific.d.ts +52 -0
  117. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/convert.d.ts +58 -0
  118. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/ipc.d.ts +156 -0
  119. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/command.d.ts +114 -0
  120. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/main-async.d.ts +379 -0
  121. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/main-sync.d.ts +59 -0
  122. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/node.d.ts +62 -0
  123. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/script.d.ts +115 -0
  124. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/methods/template.d.ts +18 -0
  125. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/pipe.d.ts +58 -0
  126. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/final-error.d.ts +51 -0
  127. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/ignore.d.ts +26 -0
  128. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/result-all.d.ts +30 -0
  129. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/result-ipc.d.ts +27 -0
  130. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/result-stdio.d.ts +17 -0
  131. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/result-stdout.d.ts +50 -0
  132. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/return/result.d.ts +203 -0
  133. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/stdio/array.d.ts +16 -0
  134. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/stdio/direction.d.ts +12 -0
  135. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/stdio/option.d.ts +40 -0
  136. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/stdio/type.d.ts +170 -0
  137. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/subprocess/all.d.ts +17 -0
  138. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/subprocess/stdio.d.ts +18 -0
  139. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/subprocess/stdout.d.ts +22 -0
  140. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/subprocess/subprocess.d.ts +117 -0
  141. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/transform/normalize.d.ts +57 -0
  142. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/transform/object-mode.d.ts +21 -0
  143. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/utils.d.ts +13 -0
  144. package/dotpi_root/dist/@dotpi/javascript/node_modules/execa/types/verbose.d.ts +98 -0
  145. package/dotpi_root/dist/@dotpi/javascript/node_modules/figures/index.d.ts +279 -0
  146. package/dotpi_root/dist/@dotpi/javascript/node_modules/figures/index.js +292 -0
  147. package/dotpi_root/dist/@dotpi/javascript/node_modules/figures/license +9 -0
  148. package/dotpi_root/dist/@dotpi/javascript/node_modules/figures/package.json +49 -0
  149. package/dotpi_root/dist/@dotpi/javascript/node_modules/figures/readme.md +337 -0
  150. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/license +9 -0
  151. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/package.json +60 -0
  152. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/readme.md +303 -0
  153. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/array-buffer.js +84 -0
  154. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/array.js +32 -0
  155. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/buffer.js +19 -0
  156. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/contents.js +121 -0
  157. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/exports.js +5 -0
  158. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/index.d.ts +121 -0
  159. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/index.js +13 -0
  160. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/stream.js +65 -0
  161. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/string.js +41 -0
  162. package/dotpi_root/dist/@dotpi/javascript/node_modules/get-stream/source/utils.js +11 -0
  163. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/LICENSE +201 -0
  164. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/README.md +180 -0
  165. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/build/src/core.js +273 -0
  166. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/build/src/main.d.ts +206 -0
  167. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/build/src/main.js +70 -0
  168. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/build/src/realtime.js +16 -0
  169. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/build/src/signals.js +34 -0
  170. package/dotpi_root/dist/@dotpi/javascript/node_modules/human-signals/package.json +64 -0
  171. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-plain-obj/index.d.ts +35 -0
  172. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-plain-obj/index.js +8 -0
  173. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-plain-obj/license +9 -0
  174. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-plain-obj/package.json +41 -0
  175. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-plain-obj/readme.md +58 -0
  176. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-stream/index.d.ts +90 -0
  177. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-stream/index.js +37 -0
  178. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-stream/license +9 -0
  179. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-stream/package.json +48 -0
  180. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-stream/readme.md +57 -0
  181. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-unicode-supported/index.d.ts +12 -0
  182. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-unicode-supported/index.js +21 -0
  183. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-unicode-supported/license +9 -0
  184. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-unicode-supported/package.json +47 -0
  185. package/dotpi_root/dist/@dotpi/javascript/node_modules/is-unicode-supported/readme.md +35 -0
  186. package/dotpi_root/dist/@dotpi/javascript/node_modules/npm-run-path/index.d.ts +90 -0
  187. package/dotpi_root/dist/@dotpi/javascript/node_modules/npm-run-path/index.js +55 -0
  188. package/dotpi_root/dist/@dotpi/javascript/node_modules/npm-run-path/license +9 -0
  189. package/dotpi_root/dist/@dotpi/javascript/node_modules/npm-run-path/package.json +52 -0
  190. package/dotpi_root/dist/@dotpi/javascript/node_modules/npm-run-path/readme.md +104 -0
  191. package/dotpi_root/dist/@dotpi/javascript/node_modules/path-key/index.d.ts +31 -0
  192. package/dotpi_root/dist/@dotpi/javascript/node_modules/path-key/index.js +12 -0
  193. package/dotpi_root/dist/@dotpi/javascript/node_modules/path-key/license +9 -0
  194. package/dotpi_root/dist/@dotpi/javascript/node_modules/path-key/package.json +41 -0
  195. package/dotpi_root/dist/@dotpi/javascript/node_modules/path-key/readme.md +57 -0
  196. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/LICENSE.txt +16 -0
  197. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/README.md +74 -0
  198. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/browser.d.ts +12 -0
  199. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/browser.d.ts.map +1 -0
  200. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/browser.js +10 -0
  201. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/browser.js.map +1 -0
  202. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/index.d.ts +48 -0
  203. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/index.d.ts.map +1 -0
  204. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/index.js +279 -0
  205. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/index.js.map +1 -0
  206. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/package.json +3 -0
  207. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/signals.d.ts +29 -0
  208. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/signals.d.ts.map +1 -0
  209. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/signals.js +42 -0
  210. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/cjs/signals.js.map +1 -0
  211. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/browser.d.ts +12 -0
  212. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/browser.d.ts.map +1 -0
  213. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/browser.js +4 -0
  214. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/browser.js.map +1 -0
  215. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/index.d.ts +48 -0
  216. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/index.d.ts.map +1 -0
  217. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/index.js +275 -0
  218. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/index.js.map +1 -0
  219. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/package.json +3 -0
  220. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/signals.d.ts +29 -0
  221. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/signals.d.ts.map +1 -0
  222. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/signals.js +39 -0
  223. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/dist/mjs/signals.js.map +1 -0
  224. package/dotpi_root/dist/@dotpi/javascript/node_modules/signal-exit/package.json +106 -0
  225. package/dotpi_root/dist/@dotpi/javascript/node_modules/strip-final-newline/index.d.ts +18 -0
  226. package/dotpi_root/dist/@dotpi/javascript/node_modules/strip-final-newline/index.js +26 -0
  227. package/dotpi_root/dist/@dotpi/javascript/node_modules/strip-final-newline/license +9 -0
  228. package/dotpi_root/dist/@dotpi/javascript/node_modules/strip-final-newline/package.json +49 -0
  229. package/dotpi_root/dist/@dotpi/javascript/node_modules/strip-final-newline/readme.md +34 -0
  230. package/dotpi_root/dist/@dotpi/javascript/package.json +5 -1
  231. package/dotpi_root/dist/@dotpi/module/node_modules/execa/index.d.ts +27 -0
  232. package/dotpi_root/dist/@dotpi/module/node_modules/execa/index.js +28 -0
  233. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/command.js +20 -0
  234. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/cwd.js +39 -0
  235. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/encoding-option.js +50 -0
  236. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/escape.js +88 -0
  237. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/fd-options.js +108 -0
  238. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/file-url.js +25 -0
  239. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/options.js +96 -0
  240. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/arguments/specific.js +111 -0
  241. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/add.js +15 -0
  242. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/concurrent.js +33 -0
  243. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/duplex.js +69 -0
  244. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/iterable.js +34 -0
  245. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/readable.js +113 -0
  246. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/shared.js +46 -0
  247. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/convert/writable.js +90 -0
  248. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/contents.js +116 -0
  249. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/input-sync.js +44 -0
  250. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/iterate.js +110 -0
  251. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/max-buffer.js +89 -0
  252. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/output-async.js +80 -0
  253. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/output-sync.js +135 -0
  254. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/pipeline.js +48 -0
  255. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/io/strip-newline.js +12 -0
  256. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/array.js +4 -0
  257. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/buffer-messages.js +47 -0
  258. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/forward.js +56 -0
  259. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/get-each.js +89 -0
  260. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/get-one.js +69 -0
  261. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/graceful.js +72 -0
  262. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/incoming.js +79 -0
  263. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/ipc-input.js +44 -0
  264. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/methods.js +49 -0
  265. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/outgoing.js +47 -0
  266. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/reference.js +44 -0
  267. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/send.js +91 -0
  268. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/strict.js +113 -0
  269. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/ipc/validation.js +111 -0
  270. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/bind.js +23 -0
  271. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/command.js +43 -0
  272. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/create.js +65 -0
  273. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/main-async.js +193 -0
  274. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/main-sync.js +162 -0
  275. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/node.js +51 -0
  276. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/parameters.js +31 -0
  277. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/promise.js +15 -0
  278. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/script.js +22 -0
  279. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/methods/template.js +153 -0
  280. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/abort.js +20 -0
  281. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/pipe-arguments.js +91 -0
  282. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/sequence.js +24 -0
  283. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/setup.js +72 -0
  284. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/streaming.js +51 -0
  285. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/pipe/throw.js +58 -0
  286. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/all-async.js +46 -0
  287. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/all-sync.js +33 -0
  288. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/exit-async.js +54 -0
  289. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/exit-sync.js +25 -0
  290. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/stdio.js +47 -0
  291. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/wait-stream.js +96 -0
  292. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/resolve/wait-subprocess.js +146 -0
  293. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/duration.js +8 -0
  294. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/early-error.js +60 -0
  295. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/final-error.js +40 -0
  296. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/message.js +157 -0
  297. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/reject.js +13 -0
  298. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/return/result.js +186 -0
  299. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/direction.js +76 -0
  300. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/duplicate.js +116 -0
  301. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/handle-async.js +52 -0
  302. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/handle-sync.js +57 -0
  303. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/handle.js +214 -0
  304. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/input-option.js +50 -0
  305. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/native.js +106 -0
  306. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/stdio-option.js +60 -0
  307. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/stdio/type.js +173 -0
  308. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/cancel.js +20 -0
  309. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/cleanup.js +16 -0
  310. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/graceful.js +71 -0
  311. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/kill.js +93 -0
  312. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/signal.js +70 -0
  313. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/terminate/timeout.js +21 -0
  314. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/encoding-transform.js +51 -0
  315. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/generator.js +107 -0
  316. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/normalize.js +111 -0
  317. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/object-mode.js +41 -0
  318. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/run-async.js +60 -0
  319. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/run-sync.js +50 -0
  320. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/split.js +110 -0
  321. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/transform/validate.js +43 -0
  322. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/utils/abort-signal.js +8 -0
  323. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/utils/deferred.js +7 -0
  324. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/utils/max-listeners.js +14 -0
  325. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/utils/standard-stream.js +6 -0
  326. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/utils/uint-array.js +69 -0
  327. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/complete.js +24 -0
  328. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/custom.js +26 -0
  329. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/default.js +54 -0
  330. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/error.js +13 -0
  331. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/info.js +39 -0
  332. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/ipc.js +15 -0
  333. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/log.js +54 -0
  334. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/output.js +60 -0
  335. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/start.js +15 -0
  336. package/dotpi_root/dist/@dotpi/module/node_modules/execa/lib/verbose/values.js +33 -0
  337. package/dotpi_root/dist/@dotpi/module/node_modules/execa/license +9 -0
  338. package/dotpi_root/dist/@dotpi/module/node_modules/execa/package.json +104 -0
  339. package/dotpi_root/dist/@dotpi/module/node_modules/execa/readme.md +451 -0
  340. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/arguments/encoding-option.d.ts +19 -0
  341. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/arguments/fd-options.d.ts +8 -0
  342. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/arguments/options.d.ts +400 -0
  343. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/arguments/specific.d.ts +52 -0
  344. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/convert.d.ts +58 -0
  345. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/ipc.d.ts +156 -0
  346. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/command.d.ts +114 -0
  347. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/main-async.d.ts +379 -0
  348. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/main-sync.d.ts +59 -0
  349. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/node.d.ts +62 -0
  350. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/script.d.ts +115 -0
  351. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/methods/template.d.ts +18 -0
  352. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/pipe.d.ts +58 -0
  353. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/final-error.d.ts +51 -0
  354. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/ignore.d.ts +26 -0
  355. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/result-all.d.ts +30 -0
  356. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/result-ipc.d.ts +27 -0
  357. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/result-stdio.d.ts +17 -0
  358. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/result-stdout.d.ts +50 -0
  359. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/return/result.d.ts +203 -0
  360. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/stdio/array.d.ts +16 -0
  361. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/stdio/direction.d.ts +12 -0
  362. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/stdio/option.d.ts +40 -0
  363. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/stdio/type.d.ts +170 -0
  364. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/subprocess/all.d.ts +17 -0
  365. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/subprocess/stdio.d.ts +18 -0
  366. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/subprocess/stdout.d.ts +22 -0
  367. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/subprocess/subprocess.d.ts +117 -0
  368. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/transform/normalize.d.ts +57 -0
  369. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/transform/object-mode.d.ts +21 -0
  370. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/utils.d.ts +13 -0
  371. package/dotpi_root/dist/@dotpi/module/node_modules/execa/types/verbose.d.ts +98 -0
  372. package/dotpi_root/dist/@dotpi/module/node_modules/figures/index.d.ts +279 -0
  373. package/dotpi_root/dist/@dotpi/module/node_modules/figures/index.js +292 -0
  374. package/dotpi_root/dist/@dotpi/module/node_modules/figures/license +9 -0
  375. package/dotpi_root/dist/@dotpi/module/node_modules/figures/package.json +49 -0
  376. package/dotpi_root/dist/@dotpi/module/node_modules/figures/readme.md +337 -0
  377. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/license +9 -0
  378. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/package.json +60 -0
  379. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/readme.md +303 -0
  380. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/array-buffer.js +84 -0
  381. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/array.js +32 -0
  382. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/buffer.js +19 -0
  383. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/contents.js +121 -0
  384. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/exports.js +5 -0
  385. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/index.d.ts +121 -0
  386. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/index.js +13 -0
  387. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/stream.js +65 -0
  388. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/string.js +41 -0
  389. package/dotpi_root/dist/@dotpi/module/node_modules/get-stream/source/utils.js +11 -0
  390. package/dotpi_root/dist/@dotpi/module/node_modules/globby/ignore.js +109 -0
  391. package/dotpi_root/dist/@dotpi/module/node_modules/globby/index.d.ts +207 -0
  392. package/dotpi_root/dist/@dotpi/module/node_modules/globby/index.js +264 -0
  393. package/dotpi_root/dist/@dotpi/module/node_modules/globby/license +9 -0
  394. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/@sindresorhus/merge-streams/index.d.ts +44 -0
  395. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/@sindresorhus/merge-streams/index.js +223 -0
  396. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/@sindresorhus/merge-streams/license +9 -0
  397. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/@sindresorhus/merge-streams/package.json +49 -0
  398. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/@sindresorhus/merge-streams/readme.md +53 -0
  399. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/default.js +14 -0
  400. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/index.d.ts +29 -0
  401. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/license +9 -0
  402. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/node.js +7 -0
  403. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/package.json +49 -0
  404. package/dotpi_root/dist/@dotpi/module/node_modules/globby/node_modules/unicorn-magic/readme.md +25 -0
  405. package/dotpi_root/dist/@dotpi/module/node_modules/globby/package.json +94 -0
  406. package/dotpi_root/dist/@dotpi/module/node_modules/globby/readme.md +177 -0
  407. package/dotpi_root/dist/@dotpi/module/node_modules/globby/utilities.js +1 -0
  408. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/LICENSE +201 -0
  409. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/README.md +180 -0
  410. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/build/src/core.js +273 -0
  411. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/build/src/main.d.ts +206 -0
  412. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/build/src/main.js +70 -0
  413. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/build/src/realtime.js +16 -0
  414. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/build/src/signals.js +34 -0
  415. package/dotpi_root/dist/@dotpi/module/node_modules/human-signals/package.json +64 -0
  416. package/dotpi_root/dist/@dotpi/module/node_modules/is-plain-obj/index.d.ts +35 -0
  417. package/dotpi_root/dist/@dotpi/module/node_modules/is-plain-obj/index.js +8 -0
  418. package/dotpi_root/dist/@dotpi/module/node_modules/is-plain-obj/license +9 -0
  419. package/dotpi_root/dist/@dotpi/module/node_modules/is-plain-obj/package.json +41 -0
  420. package/dotpi_root/dist/@dotpi/module/node_modules/is-plain-obj/readme.md +58 -0
  421. package/dotpi_root/dist/@dotpi/module/node_modules/is-stream/index.d.ts +90 -0
  422. package/dotpi_root/dist/@dotpi/module/node_modules/is-stream/index.js +37 -0
  423. package/dotpi_root/dist/@dotpi/module/node_modules/is-stream/license +9 -0
  424. package/dotpi_root/dist/@dotpi/module/node_modules/is-stream/package.json +48 -0
  425. package/dotpi_root/dist/@dotpi/module/node_modules/is-stream/readme.md +57 -0
  426. package/dotpi_root/dist/@dotpi/module/node_modules/is-unicode-supported/index.d.ts +12 -0
  427. package/dotpi_root/dist/@dotpi/module/node_modules/is-unicode-supported/index.js +21 -0
  428. package/dotpi_root/dist/@dotpi/module/node_modules/is-unicode-supported/license +9 -0
  429. package/dotpi_root/dist/@dotpi/module/node_modules/is-unicode-supported/package.json +47 -0
  430. package/dotpi_root/dist/@dotpi/module/node_modules/is-unicode-supported/readme.md +35 -0
  431. package/dotpi_root/dist/@dotpi/module/node_modules/npm-run-path/index.d.ts +90 -0
  432. package/dotpi_root/dist/@dotpi/module/node_modules/npm-run-path/index.js +55 -0
  433. package/dotpi_root/dist/@dotpi/module/node_modules/npm-run-path/license +9 -0
  434. package/dotpi_root/dist/@dotpi/module/node_modules/npm-run-path/package.json +52 -0
  435. package/dotpi_root/dist/@dotpi/module/node_modules/npm-run-path/readme.md +104 -0
  436. package/dotpi_root/dist/@dotpi/module/node_modules/path-key/index.d.ts +31 -0
  437. package/dotpi_root/dist/@dotpi/module/node_modules/path-key/index.js +12 -0
  438. package/dotpi_root/dist/@dotpi/module/node_modules/path-key/license +9 -0
  439. package/dotpi_root/dist/@dotpi/module/node_modules/path-key/package.json +41 -0
  440. package/dotpi_root/dist/@dotpi/module/node_modules/path-key/readme.md +57 -0
  441. package/dotpi_root/dist/@dotpi/module/node_modules/path-type/index.d.ts +51 -0
  442. package/dotpi_root/dist/@dotpi/module/node_modules/path-type/index.js +41 -0
  443. package/dotpi_root/dist/@dotpi/module/node_modules/path-type/license +9 -0
  444. package/dotpi_root/dist/@dotpi/module/node_modules/path-type/package.json +47 -0
  445. package/dotpi_root/dist/@dotpi/module/node_modules/path-type/readme.md +74 -0
  446. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/LICENSE.txt +16 -0
  447. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/README.md +74 -0
  448. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/browser.d.ts +12 -0
  449. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/browser.d.ts.map +1 -0
  450. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/browser.js +10 -0
  451. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/browser.js.map +1 -0
  452. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/index.d.ts +48 -0
  453. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/index.d.ts.map +1 -0
  454. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/index.js +279 -0
  455. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/index.js.map +1 -0
  456. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/package.json +3 -0
  457. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/signals.d.ts +29 -0
  458. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/signals.d.ts.map +1 -0
  459. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/signals.js +42 -0
  460. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/cjs/signals.js.map +1 -0
  461. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/browser.d.ts +12 -0
  462. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/browser.d.ts.map +1 -0
  463. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/browser.js +4 -0
  464. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/browser.js.map +1 -0
  465. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/index.d.ts +48 -0
  466. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/index.d.ts.map +1 -0
  467. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/index.js +275 -0
  468. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/index.js.map +1 -0
  469. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/package.json +3 -0
  470. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/signals.d.ts +29 -0
  471. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/signals.d.ts.map +1 -0
  472. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/signals.js +39 -0
  473. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/dist/mjs/signals.js.map +1 -0
  474. package/dotpi_root/dist/@dotpi/module/node_modules/signal-exit/package.json +106 -0
  475. package/dotpi_root/dist/@dotpi/module/node_modules/slash/index.d.ts +23 -0
  476. package/dotpi_root/dist/@dotpi/module/node_modules/slash/index.js +9 -0
  477. package/dotpi_root/dist/@dotpi/module/node_modules/slash/license +9 -0
  478. package/dotpi_root/dist/@dotpi/module/node_modules/slash/package.json +39 -0
  479. package/dotpi_root/dist/@dotpi/module/node_modules/slash/readme.md +36 -0
  480. package/dotpi_root/dist/@dotpi/module/node_modules/strip-final-newline/index.d.ts +18 -0
  481. package/dotpi_root/dist/@dotpi/module/node_modules/strip-final-newline/index.js +26 -0
  482. package/dotpi_root/dist/@dotpi/module/node_modules/strip-final-newline/license +9 -0
  483. package/dotpi_root/dist/@dotpi/module/node_modules/strip-final-newline/package.json +49 -0
  484. package/dotpi_root/dist/@dotpi/module/node_modules/strip-final-newline/readme.md +34 -0
  485. package/dotpi_root/dist/@dotpi/module/package.json +2 -2
  486. package/dotpi_root/dist/@dotpi/module-module/package.json +3 -4
  487. package/dotpi_root/etc/dotpi_modules.json +2 -1
  488. package/dotpi_root/share/dotpi_functions/dotpi_functions_audio_device.bash +25 -18
  489. package/package.json +16 -11
  490. package/.editorbackup/NOTES.md~ +0 -974
  491. package/.editorbackup/PIPEWIRE.md~ +0 -42
  492. package/.editorbackup/README.md~ +0 -335
  493. package/BACKUP-SANDO.command +0 -61
  494. package/BACKUP-SISIDO.command +0 -61
  495. package/DOC.md +0 -66
  496. package/NOTES.md +0 -121
  497. package/dotpi_root/dist/@dotpi/module-module/LICENSE +0 -28
  498. package/examples/example-development/configuration/dotpi_project.bash +0 -40
  499. package/examples/example-headphones/configuration/dotpi_project.bash +0 -18
  500. package/examples/example-hifiberry/configuration/dotpi_instance_012.bash +0 -4
  501. package/examples/example-hifiberry/configuration/dotpi_project.bash +0 -18
  502. package/examples/example-network/configuration/dotpi_project.bash +0 -21
  503. package/lerna.json +0 -4
  504. package/src/templates/README.md +0 -16
  505. package/src/templates/ap.nmconnection +0 -25
  506. package/src/templates/dotpi_project.bash +0 -29
  507. package/src/templates/dotpi_secrets.bash +0 -4
  508. package/src/templates/gitignore +0 -7
  509. package/src/templates/infrastructure.nmconnection +0 -29
  510. package/src/templates/ssh_config +0 -6
  511. package/test/constants.spec.js +0 -37
  512. package/test/create-project.test.js +0 -56
  513. package/test/install-rpi.test.js +0 -8
  514. package/test/utils.spec.js +0 -48
@@ -0,0 +1,71 @@
1
+ import {onAbortedSignal} from '../utils/abort-signal.js';
2
+ import {sendAbort} from '../ipc/graceful.js';
3
+ import {killOnTimeout} from './kill.js';
4
+
5
+ // Validate the `gracefulCancel` option
6
+ export const validateGracefulCancel = ({gracefulCancel, cancelSignal, ipc, serialization}) => {
7
+ if (!gracefulCancel) {
8
+ return;
9
+ }
10
+
11
+ if (cancelSignal === undefined) {
12
+ throw new Error('The `cancelSignal` option must be defined when setting the `gracefulCancel` option.');
13
+ }
14
+
15
+ if (!ipc) {
16
+ throw new Error('The `ipc` option cannot be false when setting the `gracefulCancel` option.');
17
+ }
18
+
19
+ if (serialization === 'json') {
20
+ throw new Error('The `serialization` option cannot be \'json\' when setting the `gracefulCancel` option.');
21
+ }
22
+ };
23
+
24
+ // Send abort reason to the subprocess when aborting the `cancelSignal` option and `gracefulCancel` is `true`
25
+ export const throwOnGracefulCancel = ({
26
+ subprocess,
27
+ cancelSignal,
28
+ gracefulCancel,
29
+ forceKillAfterDelay,
30
+ context,
31
+ controller,
32
+ }) => gracefulCancel
33
+ ? [sendOnAbort({
34
+ subprocess,
35
+ cancelSignal,
36
+ forceKillAfterDelay,
37
+ context,
38
+ controller,
39
+ })]
40
+ : [];
41
+
42
+ const sendOnAbort = async ({subprocess, cancelSignal, forceKillAfterDelay, context, controller: {signal}}) => {
43
+ await onAbortedSignal(cancelSignal, signal);
44
+ const reason = getReason(cancelSignal);
45
+ await sendAbort(subprocess, reason);
46
+ killOnTimeout({
47
+ kill: subprocess.kill,
48
+ forceKillAfterDelay,
49
+ context,
50
+ controllerSignal: signal,
51
+ });
52
+ context.terminationReason ??= 'gracefulCancel';
53
+ throw cancelSignal.reason;
54
+ };
55
+
56
+ // The default `reason` is a DOMException, which is not serializable with V8
57
+ // See https://github.com/nodejs/node/issues/53225
58
+ const getReason = ({reason}) => {
59
+ if (!(reason instanceof DOMException)) {
60
+ return reason;
61
+ }
62
+
63
+ const error = new Error(reason.message);
64
+ Object.defineProperty(error, 'stack', {
65
+ value: reason.stack,
66
+ enumerable: false,
67
+ configurable: true,
68
+ writable: true,
69
+ });
70
+ return error;
71
+ };
@@ -0,0 +1,93 @@
1
+ import {setTimeout} from 'node:timers/promises';
2
+ import {isErrorInstance} from '../return/final-error.js';
3
+ import {normalizeSignalArgument} from './signal.js';
4
+
5
+ // Normalize the `forceKillAfterDelay` option
6
+ export const normalizeForceKillAfterDelay = forceKillAfterDelay => {
7
+ if (forceKillAfterDelay === false) {
8
+ return forceKillAfterDelay;
9
+ }
10
+
11
+ if (forceKillAfterDelay === true) {
12
+ return DEFAULT_FORCE_KILL_TIMEOUT;
13
+ }
14
+
15
+ if (!Number.isFinite(forceKillAfterDelay) || forceKillAfterDelay < 0) {
16
+ throw new TypeError(`Expected the \`forceKillAfterDelay\` option to be a non-negative integer, got \`${forceKillAfterDelay}\` (${typeof forceKillAfterDelay})`);
17
+ }
18
+
19
+ return forceKillAfterDelay;
20
+ };
21
+
22
+ const DEFAULT_FORCE_KILL_TIMEOUT = 1000 * 5;
23
+
24
+ // Monkey-patches `subprocess.kill()` to add `forceKillAfterDelay` behavior and `.kill(error)`
25
+ export const subprocessKill = (
26
+ {kill, options: {forceKillAfterDelay, killSignal}, onInternalError, context, controller},
27
+ signalOrError,
28
+ errorArgument,
29
+ ) => {
30
+ const {signal, error} = parseKillArguments(signalOrError, errorArgument, killSignal);
31
+ emitKillError(error, onInternalError);
32
+ const killResult = kill(signal);
33
+ setKillTimeout({
34
+ kill,
35
+ signal,
36
+ forceKillAfterDelay,
37
+ killSignal,
38
+ killResult,
39
+ context,
40
+ controller,
41
+ });
42
+ return killResult;
43
+ };
44
+
45
+ const parseKillArguments = (signalOrError, errorArgument, killSignal) => {
46
+ const [signal = killSignal, error] = isErrorInstance(signalOrError)
47
+ ? [undefined, signalOrError]
48
+ : [signalOrError, errorArgument];
49
+
50
+ if (typeof signal !== 'string' && !Number.isInteger(signal)) {
51
+ throw new TypeError(`The first argument must be an error instance or a signal name string/integer: ${String(signal)}`);
52
+ }
53
+
54
+ if (error !== undefined && !isErrorInstance(error)) {
55
+ throw new TypeError(`The second argument is optional. If specified, it must be an error instance: ${error}`);
56
+ }
57
+
58
+ return {signal: normalizeSignalArgument(signal), error};
59
+ };
60
+
61
+ // Fails right away when calling `subprocess.kill(error)`.
62
+ // Does not wait for actual signal termination.
63
+ // Uses a deferred promise instead of the `error` event on the subprocess, as this is less intrusive.
64
+ const emitKillError = (error, onInternalError) => {
65
+ if (error !== undefined) {
66
+ onInternalError.reject(error);
67
+ }
68
+ };
69
+
70
+ const setKillTimeout = async ({kill, signal, forceKillAfterDelay, killSignal, killResult, context, controller}) => {
71
+ if (signal === killSignal && killResult) {
72
+ killOnTimeout({
73
+ kill,
74
+ forceKillAfterDelay,
75
+ context,
76
+ controllerSignal: controller.signal,
77
+ });
78
+ }
79
+ };
80
+
81
+ // Forcefully terminate a subprocess after a timeout
82
+ export const killOnTimeout = async ({kill, forceKillAfterDelay, context, controllerSignal}) => {
83
+ if (forceKillAfterDelay === false) {
84
+ return;
85
+ }
86
+
87
+ try {
88
+ await setTimeout(forceKillAfterDelay, undefined, {signal: controllerSignal});
89
+ if (kill('SIGKILL')) {
90
+ context.isForcefullyTerminated ??= true;
91
+ }
92
+ } catch {}
93
+ };
@@ -0,0 +1,70 @@
1
+ import {constants} from 'node:os';
2
+ import {signalsByName} from 'human-signals';
3
+
4
+ // Normalize signals for comparison purpose.
5
+ // Also validate the signal exists.
6
+ export const normalizeKillSignal = killSignal => {
7
+ const optionName = 'option `killSignal`';
8
+ if (killSignal === 0) {
9
+ throw new TypeError(`Invalid ${optionName}: 0 cannot be used.`);
10
+ }
11
+
12
+ return normalizeSignal(killSignal, optionName);
13
+ };
14
+
15
+ export const normalizeSignalArgument = signal => signal === 0
16
+ ? signal
17
+ : normalizeSignal(signal, '`subprocess.kill()`\'s argument');
18
+
19
+ const normalizeSignal = (signalNameOrInteger, optionName) => {
20
+ if (Number.isInteger(signalNameOrInteger)) {
21
+ return normalizeSignalInteger(signalNameOrInteger, optionName);
22
+ }
23
+
24
+ if (typeof signalNameOrInteger === 'string') {
25
+ return normalizeSignalName(signalNameOrInteger, optionName);
26
+ }
27
+
28
+ throw new TypeError(`Invalid ${optionName} ${String(signalNameOrInteger)}: it must be a string or an integer.\n${getAvailableSignals()}`);
29
+ };
30
+
31
+ const normalizeSignalInteger = (signalInteger, optionName) => {
32
+ if (signalsIntegerToName.has(signalInteger)) {
33
+ return signalsIntegerToName.get(signalInteger);
34
+ }
35
+
36
+ throw new TypeError(`Invalid ${optionName} ${signalInteger}: this signal integer does not exist.\n${getAvailableSignals()}`);
37
+ };
38
+
39
+ const getSignalsIntegerToName = () => new Map(Object.entries(constants.signals)
40
+ .reverse()
41
+ .map(([signalName, signalInteger]) => [signalInteger, signalName]));
42
+
43
+ const signalsIntegerToName = getSignalsIntegerToName();
44
+
45
+ const normalizeSignalName = (signalName, optionName) => {
46
+ if (signalName in constants.signals) {
47
+ return signalName;
48
+ }
49
+
50
+ if (signalName.toUpperCase() in constants.signals) {
51
+ throw new TypeError(`Invalid ${optionName} '${signalName}': please rename it to '${signalName.toUpperCase()}'.`);
52
+ }
53
+
54
+ throw new TypeError(`Invalid ${optionName} '${signalName}': this signal name does not exist.\n${getAvailableSignals()}`);
55
+ };
56
+
57
+ const getAvailableSignals = () => `Available signal names: ${getAvailableSignalNames()}.
58
+ Available signal numbers: ${getAvailableSignalIntegers()}.`;
59
+
60
+ const getAvailableSignalNames = () => Object.keys(constants.signals)
61
+ .sort()
62
+ .map(signalName => `'${signalName}'`)
63
+ .join(', ');
64
+
65
+ const getAvailableSignalIntegers = () => [...new Set(Object.values(constants.signals)
66
+ .sort((signalInteger, signalIntegerTwo) => signalInteger - signalIntegerTwo))]
67
+ .join(', ');
68
+
69
+ // Human-friendly description of a signal
70
+ export const getSignalDescription = signal => signalsByName[signal].description;
@@ -0,0 +1,21 @@
1
+ import {setTimeout} from 'node:timers/promises';
2
+ import {DiscardedError} from '../return/final-error.js';
3
+
4
+ // Validate `timeout` option
5
+ export const validateTimeout = ({timeout}) => {
6
+ if (timeout !== undefined && (!Number.isFinite(timeout) || timeout < 0)) {
7
+ throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${timeout}\` (${typeof timeout})`);
8
+ }
9
+ };
10
+
11
+ // Fails when the `timeout` option is exceeded
12
+ export const throwOnTimeout = (subprocess, timeout, context, controller) => timeout === 0 || timeout === undefined
13
+ ? []
14
+ : [killAfterTimeout(subprocess, timeout, context, controller)];
15
+
16
+ const killAfterTimeout = async (subprocess, timeout, context, {signal}) => {
17
+ await setTimeout(timeout, undefined, {signal});
18
+ context.terminationReason ??= 'timeout';
19
+ subprocess.kill();
20
+ throw new DiscardedError();
21
+ };
@@ -0,0 +1,51 @@
1
+ import {Buffer} from 'node:buffer';
2
+ import {StringDecoder} from 'node:string_decoder';
3
+ import {isUint8Array, bufferToUint8Array} from '../utils/uint-array.js';
4
+
5
+ /*
6
+ When using binary encodings, add an internal generator that converts chunks from `Buffer` to `string` or `Uint8Array`.
7
+ Chunks might be Buffer, Uint8Array or strings since:
8
+ - `subprocess.stdout|stderr` emits Buffers
9
+ - `subprocess.stdin.write()` accepts Buffer, Uint8Array or string
10
+ - Previous generators might return Uint8Array or string
11
+
12
+ However, those are converted to Buffer:
13
+ - on writes: `Duplex.writable` `decodeStrings: true` default option
14
+ - on reads: `Duplex.readable` `readableEncoding: null` default option
15
+ */
16
+ export const getEncodingTransformGenerator = (binary, encoding, skipped) => {
17
+ if (skipped) {
18
+ return;
19
+ }
20
+
21
+ if (binary) {
22
+ return {transform: encodingUint8ArrayGenerator.bind(undefined, new TextEncoder())};
23
+ }
24
+
25
+ const stringDecoder = new StringDecoder(encoding);
26
+ return {
27
+ transform: encodingStringGenerator.bind(undefined, stringDecoder),
28
+ final: encodingStringFinal.bind(undefined, stringDecoder),
29
+ };
30
+ };
31
+
32
+ const encodingUint8ArrayGenerator = function * (textEncoder, chunk) {
33
+ if (Buffer.isBuffer(chunk)) {
34
+ yield bufferToUint8Array(chunk);
35
+ } else if (typeof chunk === 'string') {
36
+ yield textEncoder.encode(chunk);
37
+ } else {
38
+ yield chunk;
39
+ }
40
+ };
41
+
42
+ const encodingStringGenerator = function * (stringDecoder, chunk) {
43
+ yield isUint8Array(chunk) ? stringDecoder.write(chunk) : chunk;
44
+ };
45
+
46
+ const encodingStringFinal = function * (stringDecoder) {
47
+ const lastChunk = stringDecoder.end();
48
+ if (lastChunk !== '') {
49
+ yield lastChunk;
50
+ }
51
+ };
@@ -0,0 +1,107 @@
1
+ import {Transform, getDefaultHighWaterMark} from 'node:stream';
2
+ import {isAsyncGenerator} from '../stdio/type.js';
3
+ import {getSplitLinesGenerator, getAppendNewlineGenerator} from './split.js';
4
+ import {getValidateTransformInput, getValidateTransformReturn} from './validate.js';
5
+ import {getEncodingTransformGenerator} from './encoding-transform.js';
6
+ import {
7
+ pushChunks,
8
+ transformChunk,
9
+ finalChunks,
10
+ destroyTransform,
11
+ } from './run-async.js';
12
+ import {
13
+ pushChunksSync,
14
+ transformChunkSync,
15
+ finalChunksSync,
16
+ runTransformSync,
17
+ } from './run-sync.js';
18
+
19
+ /*
20
+ Generators can be used to transform/filter standard streams.
21
+
22
+ Generators have a simple syntax, yet allows all of the following:
23
+ - Sharing `state` between chunks
24
+ - Flushing logic, by using a `final` function
25
+ - Asynchronous logic
26
+ - Emitting multiple chunks from a single source chunk, even if spaced in time, by using multiple `yield`
27
+ - Filtering, by using no `yield`
28
+
29
+ Therefore, there is no need to allow Node.js or web transform streams.
30
+
31
+ The `highWaterMark` is kept as the default value, since this is what `subprocess.std*` uses.
32
+
33
+ Chunks are currently processed serially. We could add a `concurrency` option to parallelize in the future.
34
+
35
+ Transform an array of generator functions into a `Transform` stream.
36
+ `Duplex.from(generator)` cannot be used because it does not allow setting the `objectMode` and `highWaterMark`.
37
+ */
38
+ export const generatorToStream = ({
39
+ value,
40
+ value: {transform, final, writableObjectMode, readableObjectMode},
41
+ optionName,
42
+ }, {encoding}) => {
43
+ const state = {};
44
+ const generators = addInternalGenerators(value, encoding, optionName);
45
+
46
+ const transformAsync = isAsyncGenerator(transform);
47
+ const finalAsync = isAsyncGenerator(final);
48
+ const transformMethod = transformAsync
49
+ ? pushChunks.bind(undefined, transformChunk, state)
50
+ : pushChunksSync.bind(undefined, transformChunkSync);
51
+ const finalMethod = transformAsync || finalAsync
52
+ ? pushChunks.bind(undefined, finalChunks, state)
53
+ : pushChunksSync.bind(undefined, finalChunksSync);
54
+ const destroyMethod = transformAsync || finalAsync
55
+ ? destroyTransform.bind(undefined, state)
56
+ : undefined;
57
+
58
+ const stream = new Transform({
59
+ writableObjectMode,
60
+ writableHighWaterMark: getDefaultHighWaterMark(writableObjectMode),
61
+ readableObjectMode,
62
+ readableHighWaterMark: getDefaultHighWaterMark(readableObjectMode),
63
+ transform(chunk, encoding, done) {
64
+ transformMethod([chunk, generators, 0], this, done);
65
+ },
66
+ flush(done) {
67
+ finalMethod([generators], this, done);
68
+ },
69
+ destroy: destroyMethod,
70
+ });
71
+ return {stream};
72
+ };
73
+
74
+ // Applies transform generators in sync mode
75
+ export const runGeneratorsSync = (chunks, stdioItems, encoding, isInput) => {
76
+ const generators = stdioItems.filter(({type}) => type === 'generator');
77
+ const reversedGenerators = isInput ? generators.reverse() : generators;
78
+
79
+ for (const {value, optionName} of reversedGenerators) {
80
+ const generators = addInternalGenerators(value, encoding, optionName);
81
+ chunks = runTransformSync(generators, chunks);
82
+ }
83
+
84
+ return chunks;
85
+ };
86
+
87
+ // Generators used internally to convert the chunk type, validate it, and split into lines
88
+ const addInternalGenerators = (
89
+ {transform, final, binary, writableObjectMode, readableObjectMode, preserveNewlines},
90
+ encoding,
91
+ optionName,
92
+ ) => {
93
+ const state = {};
94
+ return [
95
+ {transform: getValidateTransformInput(writableObjectMode, optionName)},
96
+ getEncodingTransformGenerator(binary, encoding, writableObjectMode),
97
+ getSplitLinesGenerator(binary, preserveNewlines, writableObjectMode, state),
98
+ {transform, final},
99
+ {transform: getValidateTransformReturn(readableObjectMode, optionName)},
100
+ getAppendNewlineGenerator({
101
+ binary,
102
+ preserveNewlines,
103
+ readableObjectMode,
104
+ state,
105
+ }),
106
+ ].filter(Boolean);
107
+ };
@@ -0,0 +1,111 @@
1
+ import isPlainObj from 'is-plain-obj';
2
+ import {BINARY_ENCODINGS} from '../arguments/encoding-option.js';
3
+ import {TRANSFORM_TYPES} from '../stdio/type.js';
4
+ import {getTransformObjectModes} from './object-mode.js';
5
+
6
+ // Transforms generators/duplex/TransformStream can have multiple shapes.
7
+ // This normalizes it and applies default values.
8
+ export const normalizeTransforms = (stdioItems, optionName, direction, options) => [
9
+ ...stdioItems.filter(({type}) => !TRANSFORM_TYPES.has(type)),
10
+ ...getTransforms(stdioItems, optionName, direction, options),
11
+ ];
12
+
13
+ const getTransforms = (stdioItems, optionName, direction, {encoding}) => {
14
+ const transforms = stdioItems.filter(({type}) => TRANSFORM_TYPES.has(type));
15
+ const newTransforms = Array.from({length: transforms.length});
16
+
17
+ for (const [index, stdioItem] of Object.entries(transforms)) {
18
+ newTransforms[index] = normalizeTransform({
19
+ stdioItem,
20
+ index: Number(index),
21
+ newTransforms,
22
+ optionName,
23
+ direction,
24
+ encoding,
25
+ });
26
+ }
27
+
28
+ return sortTransforms(newTransforms, direction);
29
+ };
30
+
31
+ const normalizeTransform = ({stdioItem, stdioItem: {type}, index, newTransforms, optionName, direction, encoding}) => {
32
+ if (type === 'duplex') {
33
+ return normalizeDuplex({stdioItem, optionName});
34
+ }
35
+
36
+ if (type === 'webTransform') {
37
+ return normalizeTransformStream({
38
+ stdioItem,
39
+ index,
40
+ newTransforms,
41
+ direction,
42
+ });
43
+ }
44
+
45
+ return normalizeGenerator({
46
+ stdioItem,
47
+ index,
48
+ newTransforms,
49
+ direction,
50
+ encoding,
51
+ });
52
+ };
53
+
54
+ const normalizeDuplex = ({
55
+ stdioItem,
56
+ stdioItem: {
57
+ value: {
58
+ transform,
59
+ transform: {writableObjectMode, readableObjectMode},
60
+ objectMode = readableObjectMode,
61
+ },
62
+ },
63
+ optionName,
64
+ }) => {
65
+ if (objectMode && !readableObjectMode) {
66
+ throw new TypeError(`The \`${optionName}.objectMode\` option can only be \`true\` if \`new Duplex({objectMode: true})\` is used.`);
67
+ }
68
+
69
+ if (!objectMode && readableObjectMode) {
70
+ throw new TypeError(`The \`${optionName}.objectMode\` option cannot be \`false\` if \`new Duplex({objectMode: true})\` is used.`);
71
+ }
72
+
73
+ return {
74
+ ...stdioItem,
75
+ value: {transform, writableObjectMode, readableObjectMode},
76
+ };
77
+ };
78
+
79
+ const normalizeTransformStream = ({stdioItem, stdioItem: {value}, index, newTransforms, direction}) => {
80
+ const {transform, objectMode} = isPlainObj(value) ? value : {transform: value};
81
+ const {writableObjectMode, readableObjectMode} = getTransformObjectModes(objectMode, index, newTransforms, direction);
82
+ return ({
83
+ ...stdioItem,
84
+ value: {transform, writableObjectMode, readableObjectMode},
85
+ });
86
+ };
87
+
88
+ const normalizeGenerator = ({stdioItem, stdioItem: {value}, index, newTransforms, direction, encoding}) => {
89
+ const {
90
+ transform,
91
+ final,
92
+ binary: binaryOption = false,
93
+ preserveNewlines = false,
94
+ objectMode,
95
+ } = isPlainObj(value) ? value : {transform: value};
96
+ const binary = binaryOption || BINARY_ENCODINGS.has(encoding);
97
+ const {writableObjectMode, readableObjectMode} = getTransformObjectModes(objectMode, index, newTransforms, direction);
98
+ return {
99
+ ...stdioItem,
100
+ value: {
101
+ transform,
102
+ final,
103
+ binary,
104
+ preserveNewlines,
105
+ writableObjectMode,
106
+ readableObjectMode,
107
+ },
108
+ };
109
+ };
110
+
111
+ const sortTransforms = (newTransforms, direction) => direction === 'input' ? newTransforms.reverse() : newTransforms;
@@ -0,0 +1,41 @@
1
+ import {TRANSFORM_TYPES} from '../stdio/type.js';
2
+
3
+ /*
4
+ Retrieve the `objectMode`s of a single transform.
5
+ `objectMode` determines the return value's type, i.e. the `readableObjectMode`.
6
+ The chunk argument's type is based on the previous generator's return value, i.e. the `writableObjectMode` is based on the previous `readableObjectMode`.
7
+ The last input's generator is read by `subprocess.stdin` which:
8
+ - should not be in `objectMode` for performance reasons.
9
+ - can only be strings, Buffers and Uint8Arrays.
10
+ Therefore its `readableObjectMode` must be `false`.
11
+ The same applies to the first output's generator's `writableObjectMode`.
12
+ */
13
+ export const getTransformObjectModes = (objectMode, index, newTransforms, direction) => direction === 'output'
14
+ ? getOutputObjectModes(objectMode, index, newTransforms)
15
+ : getInputObjectModes(objectMode, index, newTransforms);
16
+
17
+ const getOutputObjectModes = (objectMode, index, newTransforms) => {
18
+ const writableObjectMode = index !== 0 && newTransforms[index - 1].value.readableObjectMode;
19
+ const readableObjectMode = objectMode ?? writableObjectMode;
20
+ return {writableObjectMode, readableObjectMode};
21
+ };
22
+
23
+ const getInputObjectModes = (objectMode, index, newTransforms) => {
24
+ const writableObjectMode = index === 0
25
+ ? objectMode === true
26
+ : newTransforms[index - 1].value.readableObjectMode;
27
+ const readableObjectMode = index !== newTransforms.length - 1 && (objectMode ?? writableObjectMode);
28
+ return {writableObjectMode, readableObjectMode};
29
+ };
30
+
31
+ // Retrieve the `objectMode` of a file descriptor, e.g. `stdout` or `stderr`
32
+ export const getFdObjectMode = (stdioItems, direction) => {
33
+ const lastTransform = stdioItems.findLast(({type}) => TRANSFORM_TYPES.has(type));
34
+ if (lastTransform === undefined) {
35
+ return false;
36
+ }
37
+
38
+ return direction === 'input'
39
+ ? lastTransform.value.writableObjectMode
40
+ : lastTransform.value.readableObjectMode;
41
+ };
@@ -0,0 +1,60 @@
1
+ import {callbackify} from 'node:util';
2
+
3
+ // Applies a series of generator functions asynchronously
4
+ export const pushChunks = callbackify(async (getChunks, state, getChunksArguments, transformStream) => {
5
+ state.currentIterable = getChunks(...getChunksArguments);
6
+
7
+ try {
8
+ for await (const chunk of state.currentIterable) {
9
+ transformStream.push(chunk);
10
+ }
11
+ } finally {
12
+ delete state.currentIterable;
13
+ }
14
+ });
15
+
16
+ // For each new chunk, apply each `transform()` method
17
+ export const transformChunk = async function * (chunk, generators, index) {
18
+ if (index === generators.length) {
19
+ yield chunk;
20
+ return;
21
+ }
22
+
23
+ const {transform = identityGenerator} = generators[index];
24
+ for await (const transformedChunk of transform(chunk)) {
25
+ yield * transformChunk(transformedChunk, generators, index + 1);
26
+ }
27
+ };
28
+
29
+ // At the end, apply each `final()` method, followed by the `transform()` method of the next transforms
30
+ export const finalChunks = async function * (generators) {
31
+ for (const [index, {final}] of Object.entries(generators)) {
32
+ yield * generatorFinalChunks(final, Number(index), generators);
33
+ }
34
+ };
35
+
36
+ const generatorFinalChunks = async function * (final, index, generators) {
37
+ if (final === undefined) {
38
+ return;
39
+ }
40
+
41
+ for await (const finalChunk of final()) {
42
+ yield * transformChunk(finalChunk, generators, index + 1);
43
+ }
44
+ };
45
+
46
+ // Cancel any ongoing async generator when the Transform is destroyed, e.g. when the subprocess errors
47
+ export const destroyTransform = callbackify(async ({currentIterable}, error) => {
48
+ if (currentIterable !== undefined) {
49
+ await (error ? currentIterable.throw(error) : currentIterable.return());
50
+ return;
51
+ }
52
+
53
+ if (error) {
54
+ throw error;
55
+ }
56
+ });
57
+
58
+ const identityGenerator = function * (chunk) {
59
+ yield chunk;
60
+ };
@@ -0,0 +1,50 @@
1
+ // Duplicate the code from `run-async.js` but as synchronous functions
2
+ export const pushChunksSync = (getChunksSync, getChunksArguments, transformStream, done) => {
3
+ try {
4
+ for (const chunk of getChunksSync(...getChunksArguments)) {
5
+ transformStream.push(chunk);
6
+ }
7
+
8
+ done();
9
+ } catch (error) {
10
+ done(error);
11
+ }
12
+ };
13
+
14
+ // Run synchronous generators with `execaSync()`
15
+ export const runTransformSync = (generators, chunks) => [
16
+ ...chunks.flatMap(chunk => [...transformChunkSync(chunk, generators, 0)]),
17
+ ...finalChunksSync(generators),
18
+ ];
19
+
20
+ export const transformChunkSync = function * (chunk, generators, index) {
21
+ if (index === generators.length) {
22
+ yield chunk;
23
+ return;
24
+ }
25
+
26
+ const {transform = identityGenerator} = generators[index];
27
+ for (const transformedChunk of transform(chunk)) {
28
+ yield * transformChunkSync(transformedChunk, generators, index + 1);
29
+ }
30
+ };
31
+
32
+ export const finalChunksSync = function * (generators) {
33
+ for (const [index, {final}] of Object.entries(generators)) {
34
+ yield * generatorFinalChunksSync(final, Number(index), generators);
35
+ }
36
+ };
37
+
38
+ const generatorFinalChunksSync = function * (final, index, generators) {
39
+ if (final === undefined) {
40
+ return;
41
+ }
42
+
43
+ for (const finalChunk of final()) {
44
+ yield * transformChunkSync(finalChunk, generators, index + 1);
45
+ }
46
+ };
47
+
48
+ const identityGenerator = function * (chunk) {
49
+ yield chunk;
50
+ };