@poe-platform/safe-bash 0.1.801 → 0.1.803

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 (198) hide show
  1. package/README.md +4 -2
  2. package/dist/image-ast/index.browser.js +16 -5
  3. package/dist/image-ast/index.js +16 -5
  4. package/dist/safe-bash/chunks/chunk-2LSAMQER.js +84 -0
  5. package/dist/safe-bash/chunks/chunk-3HQU4OJO.js +13 -0
  6. package/dist/safe-bash/chunks/chunk-4BSJLKNM.js +14 -0
  7. package/dist/safe-bash/chunks/chunk-4D4N7IU2.js +47 -0
  8. package/dist/safe-bash/chunks/chunk-55YJASTN.js +14 -0
  9. package/dist/safe-bash/chunks/{chunk-NZQXYWA3.js → chunk-5OHX7C2V.js} +0 -1
  10. package/dist/safe-bash/chunks/chunk-7ZBU7KYV.js +14 -0
  11. package/dist/safe-bash/chunks/{chunk-7VNF5BFF.js → chunk-B7PIL77G.js} +101 -415
  12. package/dist/safe-bash/chunks/chunk-DQP3VHSB.js +15 -0
  13. package/dist/safe-bash/chunks/{chunk-VQDD3G76.js → chunk-EEEWOYEG.js} +18 -18
  14. package/dist/safe-bash/chunks/chunk-FZE4HW6G.js +11 -0
  15. package/dist/safe-bash/chunks/{chunk-45PK3NWI.js → chunk-GDYNCWRV.js} +1 -1
  16. package/dist/safe-bash/chunks/chunk-GEG3BWGE.js +14 -0
  17. package/dist/safe-bash/chunks/chunk-HBCN24ZA.js +50 -0
  18. package/dist/safe-bash/chunks/chunk-HZ7BWKQ3.js +13 -0
  19. package/dist/safe-bash/chunks/{chunk-ICFDYV64.js → chunk-HZAMGT5I.js} +2 -2
  20. package/dist/safe-bash/chunks/{chunk-FNDNHAGE.js → chunk-JMMEIDPF.js} +2 -2
  21. package/dist/safe-bash/chunks/{chunk-IVRQ4BXL.js → chunk-PH63PLPZ.js} +7 -7
  22. package/dist/safe-bash/chunks/{chunk-SZH7EJLD.js → chunk-PNBBUWSM.js} +5529 -6547
  23. package/dist/safe-bash/chunks/chunk-QGUV42T5.js +44 -0
  24. package/dist/safe-bash/chunks/chunk-R3NAKOED.js +51 -0
  25. package/dist/safe-bash/chunks/chunk-RRR7AQ24.js +38 -0
  26. package/dist/safe-bash/chunks/{chunk-PQRAK7HU.js → chunk-RYFQ3LZG.js} +281 -476
  27. package/dist/safe-bash/chunks/chunk-VBTDHOWC.js +55 -0
  28. package/dist/safe-bash/chunks/{chunk-NR3EM4LS.js → chunk-VKNVHEX3.js} +1 -6
  29. package/dist/safe-bash/chunks/chunk-XAQMU6OY.js +14 -0
  30. package/dist/safe-bash/chunks/chunk-ZVD5IS4V.js +49 -0
  31. package/dist/safe-bash/command-chunks/{chunk-ORYGZYKW.js → chunk-4FEVBOL5.js} +1 -1
  32. package/dist/safe-bash/command-chunks/{chunk-VXSLJH7G.js → chunk-6JSIFWYT.js} +26 -6
  33. package/dist/safe-bash/command-chunks/chunk-A7MU7762.js +200 -0
  34. package/dist/safe-bash/command-chunks/{chunk-KJIMDLBB.js → chunk-BXCXRYVU.js} +1 -1
  35. package/dist/safe-bash/command-chunks/{chunk-F4TEEZTL.js → chunk-CQHP3I66.js} +1 -1
  36. package/dist/safe-bash/command-chunks/{chunk-PEF7K3UQ.js → chunk-EARHPPPJ.js} +1 -1
  37. package/dist/safe-bash/command-chunks/{chunk-QKFSRZGQ.js → chunk-GFC2NTDG.js} +2 -2
  38. package/dist/safe-bash/command-chunks/chunk-GIRNFXP3.js +466 -0
  39. package/dist/safe-bash/command-chunks/{chunk-EFANWIHL.js → chunk-GY3BWK7K.js} +1 -0
  40. package/dist/safe-bash/command-chunks/{chunk-FPVUD6TH.js → chunk-HDCNKOIX.js} +9 -7
  41. package/dist/safe-bash/command-chunks/{chunk-MQFIPHIQ.js → chunk-ILX2NOLF.js} +18 -15
  42. package/dist/safe-bash/command-chunks/{chunk-5E4WAO4O.js → chunk-JD5QNRNO.js} +3 -3
  43. package/dist/safe-bash/command-chunks/{chunk-I237SNW5.js → chunk-LFJJQQND.js} +1 -1
  44. package/dist/safe-bash/command-chunks/{chunk-W5DNF4JH.js → chunk-LOICUCHG.js} +1 -1
  45. package/dist/safe-bash/command-chunks/{chunk-7U7EXOXX.js → chunk-NASVPT6F.js} +2 -1
  46. package/dist/safe-bash/command-chunks/{chunk-WBNZ4PRE.js → chunk-NGG2XL56.js} +7 -4
  47. package/dist/safe-bash/command-chunks/{chunk-GLOZX57Y.js → chunk-NKIELG7Y.js} +45 -115
  48. package/dist/safe-bash/command-chunks/{chunk-WPYIOKE3.js → chunk-PICVQ6B5.js} +2 -2
  49. package/dist/safe-bash/command-chunks/{chunk-YOFC45RK.js → chunk-QVOS4YXL.js} +1 -1
  50. package/dist/safe-bash/command-chunks/{chunk-VGG2DL5Q.js → chunk-TRR4MYWF.js} +4 -0
  51. package/dist/safe-bash/command-chunks/{chunk-2JRBIDAD.js → chunk-V4K2JDYU.js} +2 -2
  52. package/dist/safe-bash/command-chunks/{chunk-CZ7EN3JG.js → chunk-VT6MJBEI.js} +1 -1
  53. package/dist/safe-bash/command-chunks/{chunk-PCEFOYA3.js → chunk-WWIBP2ET.js} +41 -114
  54. package/dist/safe-bash/command-chunks/{chunk-F6OYH562.js → chunk-X54L3DBL.js} +4 -9
  55. package/dist/safe-bash/command-chunks/{chunk-TNOA7FCQ.js → chunk-YVNGTIJO.js} +1 -1
  56. package/dist/safe-bash/command-chunks/chunk-ZDN7MJE6.js +168 -0
  57. package/dist/safe-bash/commands/apply-patch/index.browser.js +14 -0
  58. package/dist/safe-bash/commands/archive/index.browser.js +36 -0
  59. package/dist/safe-bash/commands/bytes/compression/index.js +54 -51
  60. package/dist/safe-bash/commands/chmod/index.browser.js +14 -0
  61. package/dist/safe-bash/commands/chmod/index.d.ts +2 -0
  62. package/dist/safe-bash/commands/chmod/index.js +2 -0
  63. package/dist/safe-bash/commands/column/index.browser.js +12 -0
  64. package/dist/safe-bash/commands/du/index.browser.js +14 -0
  65. package/dist/safe-bash/commands/expr/index.browser.js +12 -0
  66. package/dist/safe-bash/commands/file/index.browser.js +14 -0
  67. package/dist/safe-bash/commands/filesystem.js +9 -2
  68. package/dist/safe-bash/commands/grep-aliases/index.browser.js +14 -0
  69. package/dist/safe-bash/commands/html-to-markdown/index.browser.js +16 -0
  70. package/dist/safe-bash/commands/metadata/chmod.d.ts +1 -7
  71. package/dist/safe-bash/commands/metadata/chmod.js +1 -204
  72. package/dist/safe-bash/commands/metadata/index.browser.js +17 -0
  73. package/dist/safe-bash/commands/metadata/internal.d.ts +1 -30
  74. package/dist/safe-bash/commands/metadata/internal.js +1 -76
  75. package/dist/safe-bash/commands/metadata/mktemp.d.ts +1 -3
  76. package/dist/safe-bash/commands/metadata/mktemp.js +1 -202
  77. package/dist/safe-bash/commands/metadata/stat.d.ts +1 -7
  78. package/dist/safe-bash/commands/metadata/stat.js +1 -530
  79. package/dist/safe-bash/commands/mktemp/index.browser.js +13 -0
  80. package/dist/safe-bash/commands/mktemp/index.d.ts +2 -0
  81. package/dist/safe-bash/commands/mktemp/index.js +2 -0
  82. package/dist/safe-bash/commands/network/index.browser.js +1 -1
  83. package/dist/safe-bash/commands/node/index.browser.js +4 -4
  84. package/dist/safe-bash/commands/portable-random.d.ts +1 -1
  85. package/dist/safe-bash/commands/portable-random.js +1 -12
  86. package/dist/safe-bash/commands/python/index.browser.js +8 -8
  87. package/dist/safe-bash/commands/regex-execution/public.browser.js +5 -3
  88. package/dist/safe-bash/commands/split/index.browser.js +14 -0
  89. package/dist/safe-bash/commands/stat/index.browser.js +13 -0
  90. package/dist/safe-bash/commands/stat/index.d.ts +2 -0
  91. package/dist/safe-bash/commands/stat/index.js +2 -0
  92. package/dist/safe-bash/commands/stream-format/index.browser.js +11 -0
  93. package/dist/safe-bash/commands/stream-inspection/index.browser.js +11 -0
  94. package/dist/safe-bash/commands/streams.js +5 -5
  95. package/dist/safe-bash/commands/table-text/index.browser.js +11 -0
  96. package/dist/safe-bash/commands/text.js +48 -143
  97. package/dist/safe-bash/commands/time-env/index.browser.js +15 -0
  98. package/dist/safe-bash/commands/tree/index.browser.js +14 -0
  99. package/dist/safe-bash/full-core.browser.js +256 -247
  100. package/dist/safe-bash/opt-in/commands/yq/native-work.js +1 -0
  101. package/dist/safe-bash/optional-host.browser.js +12 -12
  102. package/dist/safe-bash/plugins/index.browser.js +25 -11
  103. package/dist/safe-bash/registry-entry.browser.js +28 -14
  104. package/dist/safe-bash/search.browser.js +48 -0
  105. package/dist/safe-bash/shell/runtime.d.ts +3 -9
  106. package/dist/safe-bash/shell/runtime.js +63 -311
  107. package/dist/safe-bash/shell/shell.js +0 -23
  108. package/dist/safe-bash/shell/types.d.ts +2 -0
  109. package/dist/safe-bash/shell/worker-limits.js +1 -0
  110. package/dist/safe-bash/shell-entry.browser.js +19 -10
  111. package/dist/safe-bash/worker/host.js +1 -1
  112. package/dist/safe-bash-command-bc/index.js +12 -5
  113. package/dist/safe-bash-command-bzip2/index.js +4 -3
  114. package/dist/safe-bash-command-chmod/LICENSE +21 -0
  115. package/dist/safe-bash-command-chmod/command.d.ts +7 -0
  116. package/dist/safe-bash-command-chmod/command.js +11 -0
  117. package/dist/safe-bash-command-chmod/index.d.ts +6 -0
  118. package/dist/safe-bash-command-chmod/index.js +27 -0
  119. package/dist/safe-bash-command-exiftool/index.js +5 -5
  120. package/dist/safe-bash-command-find/find.js +1 -1
  121. package/dist/safe-bash-command-find/index.js +1 -1
  122. package/dist/safe-bash-command-fmt/index.js +9 -2
  123. package/dist/safe-bash-command-gzip/index.js +45 -42
  124. package/dist/safe-bash-command-imagemagick/index.js +3 -1
  125. package/dist/safe-bash-command-jq/index.js +1 -1
  126. package/dist/safe-bash-command-jq/jq.js +1 -1
  127. package/dist/safe-bash-command-less/index.js +12 -3
  128. package/dist/safe-bash-command-mktemp/LICENSE +21 -0
  129. package/dist/safe-bash-command-mktemp/command.d.ts +3 -0
  130. package/dist/safe-bash-command-mktemp/command.js +9 -0
  131. package/dist/safe-bash-command-mktemp/index.d.ts +6 -0
  132. package/dist/safe-bash-command-mktemp/index.js +25 -0
  133. package/dist/safe-bash-command-nl/index.js +1 -1
  134. package/dist/safe-bash-command-nl/nl.js +1 -1
  135. package/dist/safe-bash-command-od/index.js +6 -2
  136. package/dist/safe-bash-command-op/index.js +25 -6
  137. package/dist/safe-bash-command-rg/index.js +1 -1
  138. package/dist/safe-bash-command-rg/rg-command.d.ts +0 -1
  139. package/dist/safe-bash-command-rg/rg-command.js +3 -5
  140. package/dist/safe-bash-command-sed/index.js +1 -1
  141. package/dist/safe-bash-command-sed/sed.js +1 -1
  142. package/dist/safe-bash-command-sips/index.js +13 -5
  143. package/dist/safe-bash-command-sponge/index.js +10 -3
  144. package/dist/safe-bash-command-stat/LICENSE +21 -0
  145. package/dist/safe-bash-command-stat/command.d.ts +7 -0
  146. package/dist/safe-bash-command-stat/command.js +9 -0
  147. package/dist/safe-bash-command-stat/index.d.ts +6 -0
  148. package/dist/safe-bash-command-stat/index.js +25 -0
  149. package/dist/safe-bash-command-unexpand/index.js +1 -1
  150. package/dist/safe-bash-command-unexpand/unexpand.js +1 -1
  151. package/dist/safe-bash-command-unrtf/index.js +11 -1
  152. package/dist/safe-bash-command-xxd/index.js +6 -2
  153. package/dist/safe-bash-command-xz/command.d.ts +1 -1
  154. package/dist/safe-bash-command-xz/index.js +3 -2
  155. package/dist/safe-bash-command-yq/index.js +1 -0
  156. package/dist/safe-bash-command-yq/native-work.js +1 -0
  157. package/dist/safe-bash-command-yq/query.js +3 -0
  158. package/dist/safe-bash-compression-engine/bounded-codec.js +3 -3
  159. package/dist/safe-bash-compression-engine/codec-loader.js +2 -2
  160. package/dist/safe-bash-compression-engine/files.js +6 -6
  161. package/dist/safe-bash-compression-engine/index.js +5 -5
  162. package/dist/safe-bash-compression-engine/operand.js +6 -6
  163. package/dist/safe-bash-compression-engine/options.js +1 -1
  164. package/dist/safe-bash-compression-engine/stream.js +5 -5
  165. package/dist/safe-bash-compression-engine/zstd-decode.js +4 -4
  166. package/dist/safe-bash-contracts/escaping.js +2 -2
  167. package/dist/safe-bash-contracts/filesystem-output.js +2 -2
  168. package/dist/safe-bash-contracts/index.js +2 -2
  169. package/dist/safe-bash-contracts/io.d.ts +2 -0
  170. package/dist/safe-bash-contracts/io.js +1 -1
  171. package/dist/safe-bash-contracts/output.js +2 -2
  172. package/dist/safe-bash-io-engine/commands/search/requirements.js +1 -1
  173. package/dist/safe-bash-io-engine/commands/text-programs/shared.js +1 -1
  174. package/dist/safe-bash-mcp/index.browser.js +11 -1
  175. package/dist/safe-bash-mcp/index.js +38 -17
  176. package/dist/safe-bash-metadata-engine/LICENSE +21 -0
  177. package/dist/safe-bash-metadata-engine/index.d.ts +30 -0
  178. package/dist/safe-bash-metadata-engine/index.js +82 -0
  179. package/dist/safe-bash-metadata-engine/random.d.ts +1 -0
  180. package/dist/safe-bash-metadata-engine/random.js +21 -0
  181. package/dist/safe-bash-regex-engine/index.js +4 -4
  182. package/dist/safe-bash-regex-engine/text/budget.d.ts +0 -1
  183. package/dist/safe-bash-regex-engine/text/budget.js +1 -1
  184. package/dist/safe-bash-regex-engine/text/regex.js +4 -4
  185. package/dist/safe-bash-regex-engine/text/replacement-buffer.js +2 -2
  186. package/dist/safe-bash-regex-engine/text/rust-syntax.js +2 -2
  187. package/dist/safe-bash-search-engine/ergonomic-regex.js +2 -2
  188. package/dist/safe-bash-search-engine/glob.js +2 -2
  189. package/dist/safe-bash-search-engine/grep.js +2 -2
  190. package/dist/safe-bash-search-engine/matcher.js +2 -2
  191. package/dist/safe-bash-search-engine/options.d.ts +2 -0
  192. package/dist/safe-bash-search-engine/options.js +1 -1
  193. package/dist/safe-bash-search-engine/output.js +1 -1
  194. package/dist/safe-bash-search-engine/shared.js +2 -2
  195. package/dist/safe-bash-search-engine/walk.js +3 -3
  196. package/dist/safe-playwright-cloudflare/browser-snapshot-json.js +2 -2
  197. package/dist/safe-playwright-cloudflare/browser-snapshot-references.js +1 -1
  198. package/package.json +91 -10
@@ -0,0 +1,44 @@
1
+ import {
2
+ init_platform
3
+ } from "./chunk-B7TAL7S5.js";
4
+
5
+ // packages/safe-bash/src/commands/archive/index.ts
6
+ init_platform();
7
+ import { createTarCommand } from "../../safe-bash-command-tar/index.js";
8
+ import { createZipCommand } from "../../safe-bash-command-zip/index.js";
9
+ import { createUnzipCommand } from "../../safe-bash-command-unzip/index.js";
10
+ import { DEFAULT_ARCHIVE_LIMITS, createTarCommand as createTarCommand2, createTarCommands, evalSyncTar, tarCommands } from "../../safe-bash-command-tar/index.js";
11
+ import { createZipCommand as createZipCommand2, createZipCommands, zipCommands, evalSyncZip } from "../../safe-bash-command-zip/index.js";
12
+ import { createUnzipCommand as createUnzipCommand2, createUnzipCommands, unzipCommands, evalSyncUnzip } from "../../safe-bash-command-unzip/index.js";
13
+ function createArchiveCommands(options = {}) {
14
+ return [createTarCommand(options), createZipCommand(options), createUnzipCommand(options)];
15
+ }
16
+ function archiveCommands(options = {}) {
17
+ const commands = createArchiveCommands(options);
18
+ return { name: "archive-commands", setup(host) {
19
+ if (!options.replace) {
20
+ for (const command of commands) {
21
+ if (host.commands.has(command.name)) throw new Error(`Command already registered: ${command.name}`);
22
+ }
23
+ }
24
+ for (const command of commands) host.commands.register(command, { replace: options.replace ?? false });
25
+ } };
26
+ }
27
+
28
+ export {
29
+ createArchiveCommands,
30
+ archiveCommands,
31
+ DEFAULT_ARCHIVE_LIMITS,
32
+ createTarCommand2 as createTarCommand,
33
+ createTarCommands,
34
+ evalSyncTar,
35
+ tarCommands,
36
+ createZipCommand2 as createZipCommand,
37
+ createZipCommands,
38
+ zipCommands,
39
+ evalSyncZip,
40
+ createUnzipCommand2 as createUnzipCommand,
41
+ createUnzipCommands,
42
+ unzipCommands,
43
+ evalSyncUnzip
44
+ };
@@ -0,0 +1,51 @@
1
+ import {
2
+ builtInDirectContextExecutors
3
+ } from "./chunk-E7OYNDGL.js";
4
+ import {
5
+ init_platform
6
+ } from "./chunk-B7TAL7S5.js";
7
+
8
+ // packages/safe-bash/src/commands/stream-format/index.ts
9
+ init_platform();
10
+
11
+ // packages/safe-bash/src/commands/stream-format/seq.ts
12
+ init_platform();
13
+ import { createSeqWithSettings } from "../../safe-bash-command-seq/seq.js";
14
+
15
+ // packages/safe-bash/src/commands/stream-format/nl.ts
16
+ init_platform();
17
+ import { createNlWithSettings } from "../../safe-bash-command-nl/nl.js";
18
+
19
+ // packages/safe-bash/src/commands/stream-format/rev.ts
20
+ init_platform();
21
+ import { createRevWithSettings } from "../../safe-bash-command-rev/rev.js";
22
+
23
+ // packages/safe-bash/src/commands/stream-format/unexpand.ts
24
+ init_platform();
25
+ import { createUnexpandWithSettings } from "../../safe-bash-command-unexpand/unexpand.js";
26
+
27
+ // packages/safe-bash/src/commands/stream-format/shared.ts
28
+ init_platform();
29
+ import { ByteOutput, Session, command, forEachRecord, records, settings } from "../../safe-bash-text-stream-engine/stream-format/shared.js";
30
+
31
+ // packages/safe-bash/src/commands/stream-format/index.ts
32
+ function createStreamFormatCommands(options = {}) {
33
+ const limits = settings(options);
34
+ const defs = [createSeqWithSettings(limits), createNlWithSettings(limits), createRevWithSettings(limits), createUnexpandWithSettings(limits)];
35
+ for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
36
+ return defs;
37
+ }
38
+ function streamFormatCommands(options = {}) {
39
+ const commands = createStreamFormatCommands(options);
40
+ return { name: "stream-format-commands", setup(host) {
41
+ if (!options.replace) for (const definition of commands) {
42
+ if (host.commands.has(definition.name)) throw new Error(`Command already registered: ${definition.name}`);
43
+ }
44
+ for (const definition of commands) host.commands.register(definition, { replace: options.replace ?? false });
45
+ } };
46
+ }
47
+
48
+ export {
49
+ createStreamFormatCommands,
50
+ streamFormatCommands
51
+ };
@@ -0,0 +1,38 @@
1
+ import {
2
+ init_platform
3
+ } from "./chunk-B7TAL7S5.js";
4
+
5
+ // packages/safe-bash/src/commands/grep-aliases/index.ts
6
+ init_platform();
7
+ import { createGrepCommands } from "../../safe-bash-command-grep/index.js";
8
+ import { createGrepAliases } from "../../safe-bash-io-engine/commands/grep-aliases/aliases.js";
9
+
10
+ // packages/safe-bash/src/commands/egrep/index.ts
11
+ init_platform();
12
+ import { createEgrepCommand, createEgrepCommands, egrepCommands } from "../../safe-bash-command-egrep/index.js";
13
+
14
+ // packages/safe-bash/src/commands/fgrep/index.ts
15
+ init_platform();
16
+ import { createFgrepCommand, createFgrepCommands, fgrepCommands } from "../../safe-bash-command-fgrep/index.js";
17
+
18
+ // packages/safe-bash/src/commands/grep-aliases/index.ts
19
+ function createGrepAliasCommands(options = {}) {
20
+ const grep = createGrepCommands({ ...options.regex, ...options.regexExecutor === void 0 ? {} : { regexExecutor: options.regexExecutor } })[0];
21
+ return createGrepAliases(grep);
22
+ }
23
+ function grepAliasCommands(options = {}) {
24
+ const commands = createGrepAliasCommands(options);
25
+ return { name: "grep-alias-commands", setup(host) {
26
+ if (!options.replace) {
27
+ for (const command of commands) if (host.commands.has(command.name)) throw new Error(`Command already registered: ${command.name}`);
28
+ }
29
+ for (const command of commands) host.commands.register(command, { replace: options.replace ?? false });
30
+ } };
31
+ }
32
+
33
+ export {
34
+ createEgrepCommand,
35
+ createFgrepCommand,
36
+ createGrepAliasCommands,
37
+ grepAliasCommands
38
+ };