@poe-platform/safe-bash 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +300 -0
- package/dist/safe-bash/browser.d.ts +13 -0
- package/dist/safe-bash/browser.d.ts.map +1 -0
- package/dist/safe-bash/browser.js +14478 -0
- package/dist/safe-bash/browser.js.map +7 -0
- package/dist/safe-bash/commands/apply-patch/apply.d.ts +6 -0
- package/dist/safe-bash/commands/apply-patch/apply.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/apply.js +273 -0
- package/dist/safe-bash/commands/apply-patch/apply.js.map +1 -0
- package/dist/safe-bash/commands/apply-patch/index.d.ts +7 -0
- package/dist/safe-bash/commands/apply-patch/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/index.js +23 -0
- package/dist/safe-bash/commands/apply-patch/index.js.map +1 -0
- package/dist/safe-bash/commands/apply-patch/matcher.d.ts +4 -0
- package/dist/safe-bash/commands/apply-patch/matcher.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/matcher.js +164 -0
- package/dist/safe-bash/commands/apply-patch/matcher.js.map +1 -0
- package/dist/safe-bash/commands/apply-patch/options.d.ts +22 -0
- package/dist/safe-bash/commands/apply-patch/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/options.js +34 -0
- package/dist/safe-bash/commands/apply-patch/options.js.map +1 -0
- package/dist/safe-bash/commands/apply-patch/parser.d.ts +22 -0
- package/dist/safe-bash/commands/apply-patch/parser.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/parser.js +164 -0
- package/dist/safe-bash/commands/apply-patch/parser.js.map +1 -0
- package/dist/safe-bash/commands/apply-patch/shared.d.ts +40 -0
- package/dist/safe-bash/commands/apply-patch/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/apply-patch/shared.js +248 -0
- package/dist/safe-bash/commands/apply-patch/shared.js.map +1 -0
- package/dist/safe-bash/commands/archive/create.d.ts +17 -0
- package/dist/safe-bash/commands/archive/create.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/create.js +168 -0
- package/dist/safe-bash/commands/archive/create.js.map +1 -0
- package/dist/safe-bash/commands/archive/extract.d.ts +5 -0
- package/dist/safe-bash/commands/archive/extract.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/extract.js +343 -0
- package/dist/safe-bash/commands/archive/extract.js.map +1 -0
- package/dist/safe-bash/commands/archive/format.d.ts +33 -0
- package/dist/safe-bash/commands/archive/format.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/format.js +225 -0
- package/dist/safe-bash/commands/archive/format.js.map +1 -0
- package/dist/safe-bash/commands/archive/index.d.ts +8 -0
- package/dist/safe-bash/commands/archive/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/index.js +70 -0
- package/dist/safe-bash/commands/archive/index.js.map +1 -0
- package/dist/safe-bash/commands/archive/internal.d.ts +48 -0
- package/dist/safe-bash/commands/archive/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/internal.js +183 -0
- package/dist/safe-bash/commands/archive/internal.js.map +1 -0
- package/dist/safe-bash/commands/archive/options.d.ts +26 -0
- package/dist/safe-bash/commands/archive/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/options.js +265 -0
- package/dist/safe-bash/commands/archive/options.js.map +1 -0
- package/dist/safe-bash/commands/archive/stream.d.ts +18 -0
- package/dist/safe-bash/commands/archive/stream.d.ts.map +1 -0
- package/dist/safe-bash/commands/archive/stream.js +108 -0
- package/dist/safe-bash/commands/archive/stream.js.map +1 -0
- package/dist/safe-bash/commands/basic.d.ts +3 -0
- package/dist/safe-bash/commands/basic.d.ts.map +1 -0
- package/dist/safe-bash/commands/basic.js +208 -0
- package/dist/safe-bash/commands/basic.js.map +1 -0
- package/dist/safe-bash/commands/bytes/checksums/index.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/checksums/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/checksums/index.js +334 -0
- package/dist/safe-bash/commands/bytes/checksums/index.js.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/files.d.ts +13 -0
- package/dist/safe-bash/commands/bytes/compression/files.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/files.js +213 -0
- package/dist/safe-bash/commands/bytes/compression/files.js.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/gunzip.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/compression/gunzip.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/gunzip.js +191 -0
- package/dist/safe-bash/commands/bytes/compression/gunzip.js.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/index.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/compression/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/index.js +46 -0
- package/dist/safe-bash/commands/bytes/compression/index.js.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/options.d.ts +12 -0
- package/dist/safe-bash/commands/bytes/compression/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/options.js +58 -0
- package/dist/safe-bash/commands/bytes/compression/options.js.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/stream.d.ts +6 -0
- package/dist/safe-bash/commands/bytes/compression/stream.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/compression/stream.js +94 -0
- package/dist/safe-bash/commands/bytes/compression/stream.js.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/base.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/encoding/base.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/base.js +120 -0
- package/dist/safe-bash/commands/bytes/encoding/base.js.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/index.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/encoding/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/index.js +7 -0
- package/dist/safe-bash/commands/bytes/encoding/index.js.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/od.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/encoding/od.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/od.js +135 -0
- package/dist/safe-bash/commands/bytes/encoding/od.js.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/shared.d.ts +10 -0
- package/dist/safe-bash/commands/bytes/encoding/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/shared.js +107 -0
- package/dist/safe-bash/commands/bytes/encoding/shared.js.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/xxd.d.ts +3 -0
- package/dist/safe-bash/commands/bytes/encoding/xxd.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/encoding/xxd.js +153 -0
- package/dist/safe-bash/commands/bytes/encoding/xxd.js.map +1 -0
- package/dist/safe-bash/commands/bytes/index.d.ts +7 -0
- package/dist/safe-bash/commands/bytes/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/bytes/index.js +22 -0
- package/dist/safe-bash/commands/bytes/index.js.map +1 -0
- package/dist/safe-bash/commands/column/column.d.ts +4 -0
- package/dist/safe-bash/commands/column/column.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/column.js +141 -0
- package/dist/safe-bash/commands/column/column.js.map +1 -0
- package/dist/safe-bash/commands/column/display.d.ts +11 -0
- package/dist/safe-bash/commands/column/display.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/display.js +74 -0
- package/dist/safe-bash/commands/column/display.js.map +1 -0
- package/dist/safe-bash/commands/column/index.d.ts +7 -0
- package/dist/safe-bash/commands/column/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/index.js +18 -0
- package/dist/safe-bash/commands/column/index.js.map +1 -0
- package/dist/safe-bash/commands/column/internal.d.ts +35 -0
- package/dist/safe-bash/commands/column/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/internal.js +193 -0
- package/dist/safe-bash/commands/column/internal.js.map +1 -0
- package/dist/safe-bash/commands/column/options.d.ts +34 -0
- package/dist/safe-bash/commands/column/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/options.js +141 -0
- package/dist/safe-bash/commands/column/options.js.map +1 -0
- package/dist/safe-bash/commands/column/table.d.ts +4 -0
- package/dist/safe-bash/commands/column/table.d.ts.map +1 -0
- package/dist/safe-bash/commands/column/table.js +87 -0
- package/dist/safe-bash/commands/column/table.js.map +1 -0
- package/dist/safe-bash/commands/copy-identity.d.ts +4 -0
- package/dist/safe-bash/commands/copy-identity.d.ts.map +1 -0
- package/dist/safe-bash/commands/copy-identity.js +46 -0
- package/dist/safe-bash/commands/copy-identity.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/diff-format.d.ts +9 -0
- package/dist/safe-bash/commands/diff-patch/diff-format.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/diff-format.js +155 -0
- package/dist/safe-bash/commands/diff-patch/diff-format.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/diff.d.ts +3 -0
- package/dist/safe-bash/commands/diff-patch/diff.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/diff.js +291 -0
- package/dist/safe-bash/commands/diff-patch/diff.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/index.d.ts +6 -0
- package/dist/safe-bash/commands/diff-patch/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/index.js +21 -0
- package/dist/safe-bash/commands/diff-patch/index.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-envelope.d.ts +3 -0
- package/dist/safe-bash/commands/diff-patch/patch-envelope.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-envelope.js +56 -0
- package/dist/safe-bash/commands/diff-patch/patch-envelope.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-formats.d.ts +8 -0
- package/dist/safe-bash/commands/diff-patch/patch-formats.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-formats.js +247 -0
- package/dist/safe-bash/commands/diff-patch/patch-formats.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-paths.d.ts +34 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-paths.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-paths.js +215 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-paths.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-reject.d.ts +4 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-reject.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-reject.js +89 -0
- package/dist/safe-bash/commands/diff-patch/patch-gnu-reject.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-path.d.ts +4 -0
- package/dist/safe-bash/commands/diff-patch/patch-path.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch-path.js +95 -0
- package/dist/safe-bash/commands/diff-patch/patch-path.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch.d.ts +3 -0
- package/dist/safe-bash/commands/diff-patch/patch.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/patch.js +389 -0
- package/dist/safe-bash/commands/diff-patch/patch.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/shared.d.ts +42 -0
- package/dist/safe-bash/commands/diff-patch/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/shared.js +177 -0
- package/dist/safe-bash/commands/diff-patch/shared.js.map +1 -0
- package/dist/safe-bash/commands/diff-patch/unified.d.ts +50 -0
- package/dist/safe-bash/commands/diff-patch/unified.d.ts.map +1 -0
- package/dist/safe-bash/commands/diff-patch/unified.js +263 -0
- package/dist/safe-bash/commands/diff-patch/unified.js.map +1 -0
- package/dist/safe-bash/commands/du/arguments.d.ts +17 -0
- package/dist/safe-bash/commands/du/arguments.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/arguments.js +164 -0
- package/dist/safe-bash/commands/du/arguments.js.map +1 -0
- package/dist/safe-bash/commands/du/budget.d.ts +37 -0
- package/dist/safe-bash/commands/du/budget.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/budget.js +127 -0
- package/dist/safe-bash/commands/du/budget.js.map +1 -0
- package/dist/safe-bash/commands/du/du.d.ts +4 -0
- package/dist/safe-bash/commands/du/du.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/du.js +205 -0
- package/dist/safe-bash/commands/du/du.js.map +1 -0
- package/dist/safe-bash/commands/du/format.d.ts +10 -0
- package/dist/safe-bash/commands/du/format.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/format.js +54 -0
- package/dist/safe-bash/commands/du/format.js.map +1 -0
- package/dist/safe-bash/commands/du/index.d.ts +7 -0
- package/dist/safe-bash/commands/du/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/index.js +19 -0
- package/dist/safe-bash/commands/du/index.js.map +1 -0
- package/dist/safe-bash/commands/du/options.d.ts +17 -0
- package/dist/safe-bash/commands/du/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/du/options.js +14 -0
- package/dist/safe-bash/commands/du/options.js.map +1 -0
- package/dist/safe-bash/commands/env-split.d.ts +8 -0
- package/dist/safe-bash/commands/env-split.d.ts.map +1 -0
- package/dist/safe-bash/commands/env-split.js +343 -0
- package/dist/safe-bash/commands/env-split.js.map +1 -0
- package/dist/safe-bash/commands/execution.d.ts +4 -0
- package/dist/safe-bash/commands/execution.d.ts.map +1 -0
- package/dist/safe-bash/commands/execution.js +230 -0
- package/dist/safe-bash/commands/execution.js.map +1 -0
- package/dist/safe-bash/commands/expr/bre-worker.d.ts +3 -0
- package/dist/safe-bash/commands/expr/bre-worker.d.ts.map +1 -0
- package/dist/safe-bash/commands/expr/bre-worker.js +445 -0
- package/dist/safe-bash/commands/expr/bre-worker.js.map +1 -0
- package/dist/safe-bash/commands/expr/evaluate.d.ts +15 -0
- package/dist/safe-bash/commands/expr/evaluate.d.ts.map +1 -0
- package/dist/safe-bash/commands/expr/evaluate.js +150 -0
- package/dist/safe-bash/commands/expr/evaluate.js.map +1 -0
- package/dist/safe-bash/commands/expr/index.d.ts +7 -0
- package/dist/safe-bash/commands/expr/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/expr/index.js +86 -0
- package/dist/safe-bash/commands/expr/index.js.map +1 -0
- package/dist/safe-bash/commands/expr/internal.d.ts +45 -0
- package/dist/safe-bash/commands/expr/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/expr/internal.js +145 -0
- package/dist/safe-bash/commands/expr/internal.js.map +1 -0
- package/dist/safe-bash/commands/expr/syntax.d.ts +4 -0
- package/dist/safe-bash/commands/expr/syntax.d.ts.map +1 -0
- package/dist/safe-bash/commands/expr/syntax.js +120 -0
- package/dist/safe-bash/commands/expr/syntax.js.map +1 -0
- package/dist/safe-bash/commands/file/classify.d.ts +8 -0
- package/dist/safe-bash/commands/file/classify.d.ts.map +1 -0
- package/dist/safe-bash/commands/file/classify.js +125 -0
- package/dist/safe-bash/commands/file/classify.js.map +1 -0
- package/dist/safe-bash/commands/file/index.d.ts +7 -0
- package/dist/safe-bash/commands/file/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/file/index.js +257 -0
- package/dist/safe-bash/commands/file/index.js.map +1 -0
- package/dist/safe-bash/commands/file/shared.d.ts +48 -0
- package/dist/safe-bash/commands/file/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/file/shared.js +166 -0
- package/dist/safe-bash/commands/file/shared.js.map +1 -0
- package/dist/safe-bash/commands/filesystem.d.ts +3 -0
- package/dist/safe-bash/commands/filesystem.d.ts.map +1 -0
- package/dist/safe-bash/commands/filesystem.js +427 -0
- package/dist/safe-bash/commands/filesystem.js.map +1 -0
- package/dist/safe-bash/commands/find.d.ts +3 -0
- package/dist/safe-bash/commands/find.d.ts.map +1 -0
- package/dist/safe-bash/commands/find.js +238 -0
- package/dist/safe-bash/commands/find.js.map +1 -0
- package/dist/safe-bash/commands/git/arguments.d.ts +17 -0
- package/dist/safe-bash/commands/git/arguments.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/arguments.js +150 -0
- package/dist/safe-bash/commands/git/arguments.js.map +1 -0
- package/dist/safe-bash/commands/git/codec.d.ts +8 -0
- package/dist/safe-bash/commands/git/codec.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/codec.js +225 -0
- package/dist/safe-bash/commands/git/codec.js.map +1 -0
- package/dist/safe-bash/commands/git/config.d.ts +8 -0
- package/dist/safe-bash/commands/git/config.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/config.js +100 -0
- package/dist/safe-bash/commands/git/config.js.map +1 -0
- package/dist/safe-bash/commands/git/crc.d.ts +3 -0
- package/dist/safe-bash/commands/git/crc.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/crc.js +14 -0
- package/dist/safe-bash/commands/git/crc.js.map +1 -0
- package/dist/safe-bash/commands/git/delta.d.ts +4 -0
- package/dist/safe-bash/commands/git/delta.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/delta.js +62 -0
- package/dist/safe-bash/commands/git/delta.js.map +1 -0
- package/dist/safe-bash/commands/git/diff.d.ts +9 -0
- package/dist/safe-bash/commands/git/diff.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/diff.js +131 -0
- package/dist/safe-bash/commands/git/diff.js.map +1 -0
- package/dist/safe-bash/commands/git/ignore.d.ts +22 -0
- package/dist/safe-bash/commands/git/ignore.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/ignore.js +153 -0
- package/dist/safe-bash/commands/git/ignore.js.map +1 -0
- package/dist/safe-bash/commands/git/index.d.ts +7 -0
- package/dist/safe-bash/commands/git/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/index.js +66 -0
- package/dist/safe-bash/commands/git/index.js.map +1 -0
- package/dist/safe-bash/commands/git/io.d.ts +46 -0
- package/dist/safe-bash/commands/git/io.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/io.js +388 -0
- package/dist/safe-bash/commands/git/io.js.map +1 -0
- package/dist/safe-bash/commands/git/limits.d.ts +39 -0
- package/dist/safe-bash/commands/git/limits.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/limits.js +43 -0
- package/dist/safe-bash/commands/git/limits.js.map +1 -0
- package/dist/safe-bash/commands/git/pack.d.ts +14 -0
- package/dist/safe-bash/commands/git/pack.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/pack.js +273 -0
- package/dist/safe-bash/commands/git/pack.js.map +1 -0
- package/dist/safe-bash/commands/git/queries.d.ts +6 -0
- package/dist/safe-bash/commands/git/queries.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/queries.js +292 -0
- package/dist/safe-bash/commands/git/queries.js.map +1 -0
- package/dist/safe-bash/commands/git/repository.d.ts +49 -0
- package/dist/safe-bash/commands/git/repository.d.ts.map +1 -0
- package/dist/safe-bash/commands/git/repository.js +473 -0
- package/dist/safe-bash/commands/git/repository.js.map +1 -0
- package/dist/safe-bash/commands/grep-aliases/index.d.ts +11 -0
- package/dist/safe-bash/commands/grep-aliases/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/grep-aliases/index.js +52 -0
- package/dist/safe-bash/commands/grep-aliases/index.js.map +1 -0
- package/dist/safe-bash/commands/grep.d.ts +4 -0
- package/dist/safe-bash/commands/grep.d.ts.map +1 -0
- package/dist/safe-bash/commands/grep.js +112 -0
- package/dist/safe-bash/commands/grep.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/budget.d.ts +34 -0
- package/dist/safe-bash/commands/html-to-markdown/budget.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/budget.js +94 -0
- package/dist/safe-bash/commands/html-to-markdown/budget.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/entities.d.ts +5 -0
- package/dist/safe-bash/commands/html-to-markdown/entities.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/entities.js +126 -0
- package/dist/safe-bash/commands/html-to-markdown/entities.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/index.d.ts +7 -0
- package/dist/safe-bash/commands/html-to-markdown/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/index.js +91 -0
- package/dist/safe-bash/commands/html-to-markdown/index.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/input.d.ts +18 -0
- package/dist/safe-bash/commands/html-to-markdown/input.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/input.js +118 -0
- package/dist/safe-bash/commands/html-to-markdown/input.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/options.d.ts +28 -0
- package/dist/safe-bash/commands/html-to-markdown/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/options.js +56 -0
- package/dist/safe-bash/commands/html-to-markdown/options.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/parser.d.ts +31 -0
- package/dist/safe-bash/commands/html-to-markdown/parser.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/parser.js +293 -0
- package/dist/safe-bash/commands/html-to-markdown/parser.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/render.d.ts +25 -0
- package/dist/safe-bash/commands/html-to-markdown/render.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/render.js +445 -0
- package/dist/safe-bash/commands/html-to-markdown/render.js.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/text.d.ts +5 -0
- package/dist/safe-bash/commands/html-to-markdown/text.d.ts.map +1 -0
- package/dist/safe-bash/commands/html-to-markdown/text.js +51 -0
- package/dist/safe-bash/commands/html-to-markdown/text.js.map +1 -0
- package/dist/safe-bash/commands/index.d.ts +10 -0
- package/dist/safe-bash/commands/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/index.js +45 -0
- package/dist/safe-bash/commands/index.js.map +1 -0
- package/dist/safe-bash/commands/internal.d.ts +38 -0
- package/dist/safe-bash/commands/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/internal.js +328 -0
- package/dist/safe-bash/commands/internal.js.map +1 -0
- package/dist/safe-bash/commands/metadata/chmod.d.ts +3 -0
- package/dist/safe-bash/commands/metadata/chmod.d.ts.map +1 -0
- package/dist/safe-bash/commands/metadata/chmod.js +144 -0
- package/dist/safe-bash/commands/metadata/chmod.js.map +1 -0
- package/dist/safe-bash/commands/metadata/index.d.ts +6 -0
- package/dist/safe-bash/commands/metadata/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/metadata/index.js +20 -0
- package/dist/safe-bash/commands/metadata/index.js.map +1 -0
- package/dist/safe-bash/commands/metadata/internal.d.ts +29 -0
- package/dist/safe-bash/commands/metadata/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/metadata/internal.js +67 -0
- package/dist/safe-bash/commands/metadata/internal.js.map +1 -0
- package/dist/safe-bash/commands/metadata/mktemp.d.ts +3 -0
- package/dist/safe-bash/commands/metadata/mktemp.d.ts.map +1 -0
- package/dist/safe-bash/commands/metadata/mktemp.js +142 -0
- package/dist/safe-bash/commands/metadata/mktemp.js.map +1 -0
- package/dist/safe-bash/commands/metadata/stat.d.ts +3 -0
- package/dist/safe-bash/commands/metadata/stat.d.ts.map +1 -0
- package/dist/safe-bash/commands/metadata/stat.js +245 -0
- package/dist/safe-bash/commands/metadata/stat.js.map +1 -0
- package/dist/safe-bash/commands/move.d.ts +10 -0
- package/dist/safe-bash/commands/move.d.ts.map +1 -0
- package/dist/safe-bash/commands/move.js +161 -0
- package/dist/safe-bash/commands/move.js.map +1 -0
- package/dist/safe-bash/commands/network/args.d.ts +37 -0
- package/dist/safe-bash/commands/network/args.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/args.js +228 -0
- package/dist/safe-bash/commands/network/args.js.map +1 -0
- package/dist/safe-bash/commands/network/body.d.ts +10 -0
- package/dist/safe-bash/commands/network/body.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/body.js +188 -0
- package/dist/safe-bash/commands/network/body.js.map +1 -0
- package/dist/safe-bash/commands/network/curl.d.ts +4 -0
- package/dist/safe-bash/commands/network/curl.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/curl.js +404 -0
- package/dist/safe-bash/commands/network/curl.js.map +1 -0
- package/dist/safe-bash/commands/network/index.d.ts +10 -0
- package/dist/safe-bash/commands/network/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/index.js +22 -0
- package/dist/safe-bash/commands/network/index.js.map +1 -0
- package/dist/safe-bash/commands/network/output.d.ts +7 -0
- package/dist/safe-bash/commands/network/output.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/output.js +93 -0
- package/dist/safe-bash/commands/network/output.js.map +1 -0
- package/dist/safe-bash/commands/network/shared.d.ts +10 -0
- package/dist/safe-bash/commands/network/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/shared.js +52 -0
- package/dist/safe-bash/commands/network/shared.js.map +1 -0
- package/dist/safe-bash/commands/network/transport.d.ts +7 -0
- package/dist/safe-bash/commands/network/transport.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/transport.js +81 -0
- package/dist/safe-bash/commands/network/transport.js.map +1 -0
- package/dist/safe-bash/commands/network/types.d.ts +49 -0
- package/dist/safe-bash/commands/network/types.d.ts.map +1 -0
- package/dist/safe-bash/commands/network/types.js +19 -0
- package/dist/safe-bash/commands/network/types.js.map +1 -0
- package/dist/safe-bash/commands/node/admission.d.ts +8 -0
- package/dist/safe-bash/commands/node/admission.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/admission.js +557 -0
- package/dist/safe-bash/commands/node/admission.js.map +1 -0
- package/dist/safe-bash/commands/node/channel.d.ts +31 -0
- package/dist/safe-bash/commands/node/channel.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/channel.js +58 -0
- package/dist/safe-bash/commands/node/channel.js.map +1 -0
- package/dist/safe-bash/commands/node/cli.d.ts +9 -0
- package/dist/safe-bash/commands/node/cli.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/cli.js +55 -0
- package/dist/safe-bash/commands/node/cli.js.map +1 -0
- package/dist/safe-bash/commands/node/diagnostics.d.ts +8 -0
- package/dist/safe-bash/commands/node/diagnostics.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/diagnostics.js +48 -0
- package/dist/safe-bash/commands/node/diagnostics.js.map +1 -0
- package/dist/safe-bash/commands/node/host.d.ts +30 -0
- package/dist/safe-bash/commands/node/host.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/host.js +411 -0
- package/dist/safe-bash/commands/node/host.js.map +1 -0
- package/dist/safe-bash/commands/node/index.d.ts +15 -0
- package/dist/safe-bash/commands/node/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/index.js +212 -0
- package/dist/safe-bash/commands/node/index.js.map +1 -0
- package/dist/safe-bash/commands/node/lifecycle.d.ts +29 -0
- package/dist/safe-bash/commands/node/lifecycle.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/lifecycle.js +205 -0
- package/dist/safe-bash/commands/node/lifecycle.js.map +1 -0
- package/dist/safe-bash/commands/node/lower.d.ts +3 -0
- package/dist/safe-bash/commands/node/lower.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/lower.js +407 -0
- package/dist/safe-bash/commands/node/lower.js.map +1 -0
- package/dist/safe-bash/commands/node/program.d.ts +3 -0
- package/dist/safe-bash/commands/node/program.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/program.js +216 -0
- package/dist/safe-bash/commands/node/program.js.map +1 -0
- package/dist/safe-bash/commands/node/rules.d.ts +2 -0
- package/dist/safe-bash/commands/node/rules.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/rules.js +134 -0
- package/dist/safe-bash/commands/node/rules.js.map +1 -0
- package/dist/safe-bash/commands/node/safejs.d.ts +4 -0
- package/dist/safe-bash/commands/node/safejs.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/safejs.js +79 -0
- package/dist/safe-bash/commands/node/safejs.js.map +1 -0
- package/dist/safe-bash/commands/node/types.d.ts +143 -0
- package/dist/safe-bash/commands/node/types.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/types.js +16 -0
- package/dist/safe-bash/commands/node/types.js.map +1 -0
- package/dist/safe-bash/commands/node/values.d.ts +13 -0
- package/dist/safe-bash/commands/node/values.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/values.js +128 -0
- package/dist/safe-bash/commands/node/values.js.map +1 -0
- package/dist/safe-bash/commands/node/worker-main.d.ts +2 -0
- package/dist/safe-bash/commands/node/worker-main.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/worker-main.js +179 -0
- package/dist/safe-bash/commands/node/worker-main.js.map +1 -0
- package/dist/safe-bash/commands/node/worker-provider.d.ts +4 -0
- package/dist/safe-bash/commands/node/worker-provider.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/worker-provider.js +355 -0
- package/dist/safe-bash/commands/node/worker-provider.js.map +1 -0
- package/dist/safe-bash/commands/node/worker-types.d.ts +30 -0
- package/dist/safe-bash/commands/node/worker-types.d.ts.map +1 -0
- package/dist/safe-bash/commands/node/worker-types.js +2 -0
- package/dist/safe-bash/commands/node/worker-types.js.map +1 -0
- package/dist/safe-bash/commands/predicates.d.ts +3 -0
- package/dist/safe-bash/commands/predicates.d.ts.map +1 -0
- package/dist/safe-bash/commands/predicates.js +151 -0
- package/dist/safe-bash/commands/predicates.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/client.d.ts +70 -0
- package/dist/safe-bash/commands/regex-execution/client.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/client.js +385 -0
- package/dist/safe-bash/commands/regex-execution/client.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/errors.d.ts +22 -0
- package/dist/safe-bash/commands/regex-execution/ere/errors.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/errors.js +37 -0
- package/dist/safe-bash/commands/regex-execution/ere/errors.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/limits.d.ts +14 -0
- package/dist/safe-bash/commands/regex-execution/ere/limits.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/limits.js +87 -0
- package/dist/safe-bash/commands/regex-execution/ere/limits.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/matcher.d.ts +4 -0
- package/dist/safe-bash/commands/regex-execution/ere/matcher.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/matcher.js +202 -0
- package/dist/safe-bash/commands/regex-execution/ere/matcher.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/syntax.d.ts +6 -0
- package/dist/safe-bash/commands/regex-execution/ere/syntax.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/syntax.js +291 -0
- package/dist/safe-bash/commands/regex-execution/ere/syntax.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/accounting.d.ts +54 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/accounting.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/accounting.js +175 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/accounting.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/owner.d.ts +15 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/owner.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/owner.js +253 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/owner.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/protocol.d.ts +68 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/protocol.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/protocol.js +35 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/protocol.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/root.d.ts +15 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/root.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/root.js +372 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/root.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/validation.d.ts +22 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/validation.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/validation.js +286 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/validation.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/wire-engine.d.ts +3 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/wire-engine.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/wire-engine.js +47 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/wire-engine.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/worker-entry.d.ts +2 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/worker-entry.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/worker-entry.js +32 -0
- package/dist/safe-bash/commands/regex-execution/ere/transport/worker-entry.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/types.d.ts +56 -0
- package/dist/safe-bash/commands/regex-execution/ere/types.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/ere/types.js +2 -0
- package/dist/safe-bash/commands/regex-execution/ere/types.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/matching.d.ts +3 -0
- package/dist/safe-bash/commands/regex-execution/matching.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/matching.js +321 -0
- package/dist/safe-bash/commands/regex-execution/matching.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/protocol.d.ts +116 -0
- package/dist/safe-bash/commands/regex-execution/protocol.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/protocol.js +159 -0
- package/dist/safe-bash/commands/regex-execution/protocol.js.map +1 -0
- package/dist/safe-bash/commands/regex-execution/worker.d.ts +2 -0
- package/dist/safe-bash/commands/regex-execution/worker.d.ts.map +1 -0
- package/dist/safe-bash/commands/regex-execution/worker.js +52 -0
- package/dist/safe-bash/commands/regex-execution/worker.js.map +1 -0
- package/dist/safe-bash/commands/safejs/index.d.ts +18 -0
- package/dist/safe-bash/commands/safejs/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/safejs/index.js +184 -0
- package/dist/safe-bash/commands/safejs/index.js.map +1 -0
- package/dist/safe-bash/commands/safejs/io.d.ts +36 -0
- package/dist/safe-bash/commands/safejs/io.d.ts.map +1 -0
- package/dist/safe-bash/commands/safejs/io.js +127 -0
- package/dist/safe-bash/commands/safejs/io.js.map +1 -0
- package/dist/safe-bash/commands/safejs/options.d.ts +12 -0
- package/dist/safe-bash/commands/safejs/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/safejs/options.js +46 -0
- package/dist/safe-bash/commands/safejs/options.js.map +1 -0
- package/dist/safe-bash/commands/safejs/render.d.ts +2 -0
- package/dist/safe-bash/commands/safejs/render.d.ts.map +1 -0
- package/dist/safe-bash/commands/safejs/render.js +100 -0
- package/dist/safe-bash/commands/safejs/render.js.map +1 -0
- package/dist/safe-bash/commands/safejs/types.d.ts +64 -0
- package/dist/safe-bash/commands/safejs/types.d.ts.map +1 -0
- package/dist/safe-bash/commands/safejs/types.js +10 -0
- package/dist/safe-bash/commands/safejs/types.js.map +1 -0
- package/dist/safe-bash/commands/search/glob.d.ts +21 -0
- package/dist/safe-bash/commands/search/glob.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/glob.js +79 -0
- package/dist/safe-bash/commands/search/glob.js.map +1 -0
- package/dist/safe-bash/commands/search/index.d.ts +6 -0
- package/dist/safe-bash/commands/search/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/index.js +20 -0
- package/dist/safe-bash/commands/search/index.js.map +1 -0
- package/dist/safe-bash/commands/search/matcher.d.ts +12 -0
- package/dist/safe-bash/commands/search/matcher.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/matcher.js +24 -0
- package/dist/safe-bash/commands/search/matcher.js.map +1 -0
- package/dist/safe-bash/commands/search/options.d.ts +56 -0
- package/dist/safe-bash/commands/search/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/options.js +307 -0
- package/dist/safe-bash/commands/search/options.js.map +1 -0
- package/dist/safe-bash/commands/search/output.d.ts +37 -0
- package/dist/safe-bash/commands/search/output.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/output.js +63 -0
- package/dist/safe-bash/commands/search/output.js.map +1 -0
- package/dist/safe-bash/commands/search/rg.d.ts +4 -0
- package/dist/safe-bash/commands/search/rg.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/rg.js +219 -0
- package/dist/safe-bash/commands/search/rg.js.map +1 -0
- package/dist/safe-bash/commands/search/shared.d.ts +37 -0
- package/dist/safe-bash/commands/search/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/shared.js +111 -0
- package/dist/safe-bash/commands/search/shared.js.map +1 -0
- package/dist/safe-bash/commands/search/walk.d.ts +28 -0
- package/dist/safe-bash/commands/search/walk.d.ts.map +1 -0
- package/dist/safe-bash/commands/search/walk.js +201 -0
- package/dist/safe-bash/commands/search/walk.js.map +1 -0
- package/dist/safe-bash/commands/split/index.d.ts +6 -0
- package/dist/safe-bash/commands/split/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/index.js +18 -0
- package/dist/safe-bash/commands/split/index.js.map +1 -0
- package/dist/safe-bash/commands/split/io.d.ts +28 -0
- package/dist/safe-bash/commands/split/io.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/io.js +101 -0
- package/dist/safe-bash/commands/split/io.js.map +1 -0
- package/dist/safe-bash/commands/split/names.d.ts +11 -0
- package/dist/safe-bash/commands/split/names.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/names.js +42 -0
- package/dist/safe-bash/commands/split/names.js.map +1 -0
- package/dist/safe-bash/commands/split/options.d.ts +28 -0
- package/dist/safe-bash/commands/split/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/options.js +130 -0
- package/dist/safe-bash/commands/split/options.js.map +1 -0
- package/dist/safe-bash/commands/split/outputs.d.ts +19 -0
- package/dist/safe-bash/commands/split/outputs.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/outputs.js +105 -0
- package/dist/safe-bash/commands/split/outputs.js.map +1 -0
- package/dist/safe-bash/commands/split/split.d.ts +4 -0
- package/dist/safe-bash/commands/split/split.d.ts.map +1 -0
- package/dist/safe-bash/commands/split/split.js +146 -0
- package/dist/safe-bash/commands/split/split.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/index.d.ts +6 -0
- package/dist/safe-bash/commands/stream-format/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/index.js +22 -0
- package/dist/safe-bash/commands/stream-format/index.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/nl.d.ts +4 -0
- package/dist/safe-bash/commands/stream-format/nl.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/nl.js +96 -0
- package/dist/safe-bash/commands/stream-format/nl.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/rev.d.ts +4 -0
- package/dist/safe-bash/commands/stream-format/rev.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/rev.js +65 -0
- package/dist/safe-bash/commands/stream-format/rev.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/seq.d.ts +4 -0
- package/dist/safe-bash/commands/stream-format/seq.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/seq.js +249 -0
- package/dist/safe-bash/commands/stream-format/seq.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/shared.d.ts +49 -0
- package/dist/safe-bash/commands/stream-format/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/shared.js +209 -0
- package/dist/safe-bash/commands/stream-format/shared.js.map +1 -0
- package/dist/safe-bash/commands/stream-format/unexpand.d.ts +4 -0
- package/dist/safe-bash/commands/stream-format/unexpand.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-format/unexpand.js +130 -0
- package/dist/safe-bash/commands/stream-format/unexpand.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/expand.d.ts +4 -0
- package/dist/safe-bash/commands/stream-inspection/expand.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/expand.js +100 -0
- package/dist/safe-bash/commands/stream-inspection/expand.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/fold.d.ts +4 -0
- package/dist/safe-bash/commands/stream-inspection/fold.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/fold.js +55 -0
- package/dist/safe-bash/commands/stream-inspection/fold.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/index.d.ts +6 -0
- package/dist/safe-bash/commands/stream-inspection/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/index.js +22 -0
- package/dist/safe-bash/commands/stream-inspection/index.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/numeric-options.d.ts +5 -0
- package/dist/safe-bash/commands/stream-inspection/numeric-options.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/numeric-options.js +53 -0
- package/dist/safe-bash/commands/stream-inspection/numeric-options.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/shared.d.ts +55 -0
- package/dist/safe-bash/commands/stream-inspection/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/shared.js +202 -0
- package/dist/safe-bash/commands/stream-inspection/shared.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/strings.d.ts +4 -0
- package/dist/safe-bash/commands/stream-inspection/strings.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/strings.js +54 -0
- package/dist/safe-bash/commands/stream-inspection/strings.js.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/tac.d.ts +4 -0
- package/dist/safe-bash/commands/stream-inspection/tac.d.ts.map +1 -0
- package/dist/safe-bash/commands/stream-inspection/tac.js +54 -0
- package/dist/safe-bash/commands/stream-inspection/tac.js.map +1 -0
- package/dist/safe-bash/commands/streams.d.ts +3 -0
- package/dist/safe-bash/commands/streams.d.ts.map +1 -0
- package/dist/safe-bash/commands/streams.js +477 -0
- package/dist/safe-bash/commands/streams.js.map +1 -0
- package/dist/safe-bash/commands/structured/index.d.ts +7 -0
- package/dist/safe-bash/commands/structured/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/index.js +21 -0
- package/dist/safe-bash/commands/structured/index.js.map +1 -0
- package/dist/safe-bash/commands/structured/input.d.ts +18 -0
- package/dist/safe-bash/commands/structured/input.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/input.js +438 -0
- package/dist/safe-bash/commands/structured/input.js.map +1 -0
- package/dist/safe-bash/commands/structured/interpreter.d.ts +21 -0
- package/dist/safe-bash/commands/structured/interpreter.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/interpreter.js +644 -0
- package/dist/safe-bash/commands/structured/interpreter.js.map +1 -0
- package/dist/safe-bash/commands/structured/jq.d.ts +4 -0
- package/dist/safe-bash/commands/structured/jq.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/jq.js +278 -0
- package/dist/safe-bash/commands/structured/jq.js.map +1 -0
- package/dist/safe-bash/commands/structured/limits.d.ts +61 -0
- package/dist/safe-bash/commands/structured/limits.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/limits.js +162 -0
- package/dist/safe-bash/commands/structured/limits.js.map +1 -0
- package/dist/safe-bash/commands/structured/numbers.d.ts +17 -0
- package/dist/safe-bash/commands/structured/numbers.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/numbers.js +143 -0
- package/dist/safe-bash/commands/structured/numbers.js.map +1 -0
- package/dist/safe-bash/commands/structured/parser.d.ts +54 -0
- package/dist/safe-bash/commands/structured/parser.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/parser.js +320 -0
- package/dist/safe-bash/commands/structured/parser.js.map +1 -0
- package/dist/safe-bash/commands/structured/split.d.ts +3 -0
- package/dist/safe-bash/commands/structured/split.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/split.js +65 -0
- package/dist/safe-bash/commands/structured/split.js.map +1 -0
- package/dist/safe-bash/commands/structured/values.d.ts +12 -0
- package/dist/safe-bash/commands/structured/values.d.ts.map +1 -0
- package/dist/safe-bash/commands/structured/values.js +213 -0
- package/dist/safe-bash/commands/structured/values.js.map +1 -0
- package/dist/safe-bash/commands/table-text/comm.d.ts +4 -0
- package/dist/safe-bash/commands/table-text/comm.d.ts.map +1 -0
- package/dist/safe-bash/commands/table-text/comm.js +101 -0
- package/dist/safe-bash/commands/table-text/comm.js.map +1 -0
- package/dist/safe-bash/commands/table-text/index.d.ts +6 -0
- package/dist/safe-bash/commands/table-text/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/table-text/index.js +21 -0
- package/dist/safe-bash/commands/table-text/index.js.map +1 -0
- package/dist/safe-bash/commands/table-text/internal.d.ts +73 -0
- package/dist/safe-bash/commands/table-text/internal.d.ts.map +1 -0
- package/dist/safe-bash/commands/table-text/internal.js +223 -0
- package/dist/safe-bash/commands/table-text/internal.js.map +1 -0
- package/dist/safe-bash/commands/table-text/join.d.ts +4 -0
- package/dist/safe-bash/commands/table-text/join.d.ts.map +1 -0
- package/dist/safe-bash/commands/table-text/join.js +252 -0
- package/dist/safe-bash/commands/table-text/join.js.map +1 -0
- package/dist/safe-bash/commands/table-text/paste.d.ts +4 -0
- package/dist/safe-bash/commands/table-text/paste.d.ts.map +1 -0
- package/dist/safe-bash/commands/table-text/paste.js +125 -0
- package/dist/safe-bash/commands/table-text/paste.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-runtime.d.ts +45 -0
- package/dist/safe-bash/commands/text-programs/awk-runtime.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-runtime.js +679 -0
- package/dist/safe-bash/commands/text-programs/awk-runtime.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-syntax.d.ts +141 -0
- package/dist/safe-bash/commands/text-programs/awk-syntax.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-syntax.js +495 -0
- package/dist/safe-bash/commands/text-programs/awk-syntax.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-values.d.ts +29 -0
- package/dist/safe-bash/commands/text-programs/awk-values.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk-values.js +155 -0
- package/dist/safe-bash/commands/text-programs/awk-values.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk.d.ts +4 -0
- package/dist/safe-bash/commands/text-programs/awk.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/awk.js +45 -0
- package/dist/safe-bash/commands/text-programs/awk.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/index.d.ts +6 -0
- package/dist/safe-bash/commands/text-programs/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/index.js +21 -0
- package/dist/safe-bash/commands/text-programs/index.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/regex.d.ts +19 -0
- package/dist/safe-bash/commands/text-programs/regex.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/regex.js +387 -0
- package/dist/safe-bash/commands/text-programs/regex.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/sed.d.ts +4 -0
- package/dist/safe-bash/commands/text-programs/sed.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/sed.js +602 -0
- package/dist/safe-bash/commands/text-programs/sed.js.map +1 -0
- package/dist/safe-bash/commands/text-programs/shared.d.ts +33 -0
- package/dist/safe-bash/commands/text-programs/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/text-programs/shared.js +102 -0
- package/dist/safe-bash/commands/text-programs/shared.js.map +1 -0
- package/dist/safe-bash/commands/text.d.ts +3 -0
- package/dist/safe-bash/commands/text.d.ts.map +1 -0
- package/dist/safe-bash/commands/text.js +428 -0
- package/dist/safe-bash/commands/text.js.map +1 -0
- package/dist/safe-bash/commands/time-env/calendar.d.ts +30 -0
- package/dist/safe-bash/commands/time-env/calendar.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/calendar.js +184 -0
- package/dist/safe-bash/commands/time-env/calendar.js.map +1 -0
- package/dist/safe-bash/commands/time-env/date.d.ts +3 -0
- package/dist/safe-bash/commands/time-env/date.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/date.js +149 -0
- package/dist/safe-bash/commands/time-env/date.js.map +1 -0
- package/dist/safe-bash/commands/time-env/format.d.ts +4 -0
- package/dist/safe-bash/commands/time-env/format.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/format.js +247 -0
- package/dist/safe-bash/commands/time-env/format.js.map +1 -0
- package/dist/safe-bash/commands/time-env/index.d.ts +6 -0
- package/dist/safe-bash/commands/time-env/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/index.js +21 -0
- package/dist/safe-bash/commands/time-env/index.js.map +1 -0
- package/dist/safe-bash/commands/time-env/printenv.d.ts +3 -0
- package/dist/safe-bash/commands/time-env/printenv.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/printenv.js +59 -0
- package/dist/safe-bash/commands/time-env/printenv.js.map +1 -0
- package/dist/safe-bash/commands/time-env/shared.d.ts +38 -0
- package/dist/safe-bash/commands/time-env/shared.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/shared.js +68 -0
- package/dist/safe-bash/commands/time-env/shared.js.map +1 -0
- package/dist/safe-bash/commands/time-env/sleep.d.ts +3 -0
- package/dist/safe-bash/commands/time-env/sleep.d.ts.map +1 -0
- package/dist/safe-bash/commands/time-env/sleep.js +150 -0
- package/dist/safe-bash/commands/time-env/sleep.js.map +1 -0
- package/dist/safe-bash/commands/timeout/duration.d.ts +10 -0
- package/dist/safe-bash/commands/timeout/duration.d.ts.map +1 -0
- package/dist/safe-bash/commands/timeout/duration.js +82 -0
- package/dist/safe-bash/commands/timeout/duration.js.map +1 -0
- package/dist/safe-bash/commands/timeout/index.d.ts +18 -0
- package/dist/safe-bash/commands/timeout/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/timeout/index.js +218 -0
- package/dist/safe-bash/commands/timeout/index.js.map +1 -0
- package/dist/safe-bash/commands/timeout/scheduler.d.ts +17 -0
- package/dist/safe-bash/commands/timeout/scheduler.d.ts.map +1 -0
- package/dist/safe-bash/commands/timeout/scheduler.js +110 -0
- package/dist/safe-bash/commands/timeout/scheduler.js.map +1 -0
- package/dist/safe-bash/commands/tree/arguments.d.ts +24 -0
- package/dist/safe-bash/commands/tree/arguments.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/arguments.js +125 -0
- package/dist/safe-bash/commands/tree/arguments.js.map +1 -0
- package/dist/safe-bash/commands/tree/charset.d.ts +5 -0
- package/dist/safe-bash/commands/tree/charset.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/charset.js +36 -0
- package/dist/safe-bash/commands/tree/charset.js.map +1 -0
- package/dist/safe-bash/commands/tree/index.d.ts +7 -0
- package/dist/safe-bash/commands/tree/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/index.js +19 -0
- package/dist/safe-bash/commands/tree/index.js.map +1 -0
- package/dist/safe-bash/commands/tree/io.d.ts +28 -0
- package/dist/safe-bash/commands/tree/io.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/io.js +95 -0
- package/dist/safe-bash/commands/tree/io.js.map +1 -0
- package/dist/safe-bash/commands/tree/options.d.ts +17 -0
- package/dist/safe-bash/commands/tree/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/options.js +14 -0
- package/dist/safe-bash/commands/tree/options.js.map +1 -0
- package/dist/safe-bash/commands/tree/pattern.d.ts +10 -0
- package/dist/safe-bash/commands/tree/pattern.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/pattern.js +90 -0
- package/dist/safe-bash/commands/tree/pattern.js.map +1 -0
- package/dist/safe-bash/commands/tree/tree.d.ts +4 -0
- package/dist/safe-bash/commands/tree/tree.d.ts.map +1 -0
- package/dist/safe-bash/commands/tree/tree.js +242 -0
- package/dist/safe-bash/commands/tree/tree.js.map +1 -0
- package/dist/safe-bash/commands/which/index.d.ts +7 -0
- package/dist/safe-bash/commands/which/index.d.ts.map +1 -0
- package/dist/safe-bash/commands/which/index.js +22 -0
- package/dist/safe-bash/commands/which/index.js.map +1 -0
- package/dist/safe-bash/commands/which/options.d.ts +15 -0
- package/dist/safe-bash/commands/which/options.d.ts.map +1 -0
- package/dist/safe-bash/commands/which/options.js +24 -0
- package/dist/safe-bash/commands/which/options.js.map +1 -0
- package/dist/safe-bash/commands/which/which.d.ts +4 -0
- package/dist/safe-bash/commands/which/which.d.ts.map +1 -0
- package/dist/safe-bash/commands/which/which.js +284 -0
- package/dist/safe-bash/commands/which/which.js.map +1 -0
- package/dist/safe-bash/contracts/command.d.ts +67 -0
- package/dist/safe-bash/contracts/command.d.ts.map +1 -0
- package/dist/safe-bash/contracts/command.js +209 -0
- package/dist/safe-bash/contracts/command.js.map +1 -0
- package/dist/safe-bash/contracts/errors.d.ts +3 -0
- package/dist/safe-bash/contracts/errors.d.ts.map +1 -0
- package/dist/safe-bash/contracts/errors.js +2 -0
- package/dist/safe-bash/contracts/errors.js.map +1 -0
- package/dist/safe-bash/contracts/filesystem.d.ts +3 -0
- package/dist/safe-bash/contracts/filesystem.d.ts.map +1 -0
- package/dist/safe-bash/contracts/filesystem.js +2 -0
- package/dist/safe-bash/contracts/filesystem.js.map +1 -0
- package/dist/safe-bash/contracts/index.d.ts +8 -0
- package/dist/safe-bash/contracts/index.d.ts.map +1 -0
- package/dist/safe-bash/contracts/index.js +8 -0
- package/dist/safe-bash/contracts/index.js.map +1 -0
- package/dist/safe-bash/contracts/io.d.ts +26 -0
- package/dist/safe-bash/contracts/io.d.ts.map +1 -0
- package/dist/safe-bash/contracts/io.js +154 -0
- package/dist/safe-bash/contracts/io.js.map +1 -0
- package/dist/safe-bash/contracts/output.d.ts +12 -0
- package/dist/safe-bash/contracts/output.d.ts.map +1 -0
- package/dist/safe-bash/contracts/output.js +126 -0
- package/dist/safe-bash/contracts/output.js.map +1 -0
- package/dist/safe-bash/contracts/path.d.ts +2 -0
- package/dist/safe-bash/contracts/path.d.ts.map +1 -0
- package/dist/safe-bash/contracts/path.js +2 -0
- package/dist/safe-bash/contracts/path.js.map +1 -0
- package/dist/safe-bash/contracts/plugin.d.ts +16 -0
- package/dist/safe-bash/contracts/plugin.d.ts.map +1 -0
- package/dist/safe-bash/contracts/plugin.js +47 -0
- package/dist/safe-bash/contracts/plugin.js.map +1 -0
- package/dist/safe-bash/contracts/value.d.ts +21 -0
- package/dist/safe-bash/contracts/value.d.ts.map +1 -0
- package/dist/safe-bash/contracts/value.js +203 -0
- package/dist/safe-bash/contracts/value.js.map +1 -0
- package/dist/safe-bash/fs/memory/index.d.ts +2 -0
- package/dist/safe-bash/fs/memory/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/memory/index.js +2 -0
- package/dist/safe-bash/fs/memory/index.js.map +1 -0
- package/dist/safe-bash/fs/mount/index.d.ts +3 -0
- package/dist/safe-bash/fs/mount/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/mount/index.js +2 -0
- package/dist/safe-bash/fs/mount/index.js.map +1 -0
- package/dist/safe-bash/fs/overlay/index.d.ts +3 -0
- package/dist/safe-bash/fs/overlay/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/overlay/index.js +2 -0
- package/dist/safe-bash/fs/overlay/index.js.map +1 -0
- package/dist/safe-bash/fs/readonly/index.d.ts +2 -0
- package/dist/safe-bash/fs/readonly/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/readonly/index.js +2 -0
- package/dist/safe-bash/fs/readonly/index.js.map +1 -0
- package/dist/safe-bash/fs/real/index.d.ts +3 -0
- package/dist/safe-bash/fs/real/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/real/index.js +2 -0
- package/dist/safe-bash/fs/real/index.js.map +1 -0
- package/dist/safe-bash/fs/s3/http/index.d.ts +3 -0
- package/dist/safe-bash/fs/s3/http/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/s3/http/index.js +2 -0
- package/dist/safe-bash/fs/s3/http/index.js.map +1 -0
- package/dist/safe-bash/fs/s3/index.d.ts +3 -0
- package/dist/safe-bash/fs/s3/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/s3/index.js +2 -0
- package/dist/safe-bash/fs/s3/index.js.map +1 -0
- package/dist/safe-bash/fs/webdav/index.d.ts +3 -0
- package/dist/safe-bash/fs/webdav/index.d.ts.map +1 -0
- package/dist/safe-bash/fs/webdav/index.js +2 -0
- package/dist/safe-bash/fs/webdav/index.js.map +1 -0
- package/dist/safe-bash/index.d.ts +40 -0
- package/dist/safe-bash/index.d.ts.map +1 -0
- package/dist/safe-bash/index.js +39 -0
- package/dist/safe-bash/index.js.map +1 -0
- package/dist/safe-bash/integrations/safejs/filesystem.d.ts +7 -0
- package/dist/safe-bash/integrations/safejs/filesystem.d.ts.map +1 -0
- package/dist/safe-bash/integrations/safejs/filesystem.js +5 -0
- package/dist/safe-bash/integrations/safejs/filesystem.js.map +1 -0
- package/dist/safe-bash/integrations/safejs/index.d.ts +5 -0
- package/dist/safe-bash/integrations/safejs/index.d.ts.map +1 -0
- package/dist/safe-bash/integrations/safejs/index.js +3 -0
- package/dist/safe-bash/integrations/safejs/index.js.map +1 -0
- package/dist/safe-bash/integrations/safejs/shell.d.ts +31 -0
- package/dist/safe-bash/integrations/safejs/shell.d.ts.map +1 -0
- package/dist/safe-bash/integrations/safejs/shell.js +53 -0
- package/dist/safe-bash/integrations/safejs/shell.js.map +1 -0
- package/dist/safe-bash/integrations/safejs/values.d.ts +8 -0
- package/dist/safe-bash/integrations/safejs/values.d.ts.map +1 -0
- package/dist/safe-bash/integrations/safejs/values.js +71 -0
- package/dist/safe-bash/integrations/safejs/values.js.map +1 -0
- package/dist/safe-bash/plugins/index.d.ts +50 -0
- package/dist/safe-bash/plugins/index.d.ts.map +1 -0
- package/dist/safe-bash/plugins/index.js +63 -0
- package/dist/safe-bash/plugins/index.js.map +1 -0
- package/dist/safe-bash/shell/arithmetic-parameters.d.ts +14 -0
- package/dist/safe-bash/shell/arithmetic-parameters.d.ts.map +1 -0
- package/dist/safe-bash/shell/arithmetic-parameters.js +156 -0
- package/dist/safe-bash/shell/arithmetic-parameters.js.map +1 -0
- package/dist/safe-bash/shell/arithmetic.d.ts +35 -0
- package/dist/safe-bash/shell/arithmetic.d.ts.map +1 -0
- package/dist/safe-bash/shell/arithmetic.js +265 -0
- package/dist/safe-bash/shell/arithmetic.js.map +1 -0
- package/dist/safe-bash/shell/arrays/bindings.d.ts +83 -0
- package/dist/safe-bash/shell/arrays/bindings.d.ts.map +1 -0
- package/dist/safe-bash/shell/arrays/bindings.js +284 -0
- package/dist/safe-bash/shell/arrays/bindings.js.map +1 -0
- package/dist/safe-bash/shell/arrays/ledger.d.ts +73 -0
- package/dist/safe-bash/shell/arrays/ledger.d.ts.map +1 -0
- package/dist/safe-bash/shell/arrays/ledger.js +270 -0
- package/dist/safe-bash/shell/arrays/ledger.js.map +1 -0
- package/dist/safe-bash/shell/arrays/state.d.ts +75 -0
- package/dist/safe-bash/shell/arrays/state.d.ts.map +1 -0
- package/dist/safe-bash/shell/arrays/state.js +444 -0
- package/dist/safe-bash/shell/arrays/state.js.map +1 -0
- package/dist/safe-bash/shell/arrays/syntax.d.ts +47 -0
- package/dist/safe-bash/shell/arrays/syntax.d.ts.map +1 -0
- package/dist/safe-bash/shell/arrays/syntax.js +122 -0
- package/dist/safe-bash/shell/arrays/syntax.js.map +1 -0
- package/dist/safe-bash/shell/cancellation.d.ts +129 -0
- package/dist/safe-bash/shell/cancellation.d.ts.map +1 -0
- package/dist/safe-bash/shell/cancellation.js +703 -0
- package/dist/safe-bash/shell/cancellation.js.map +1 -0
- package/dist/safe-bash/shell/cleanup.d.ts +19 -0
- package/dist/safe-bash/shell/cleanup.d.ts.map +1 -0
- package/dist/safe-bash/shell/cleanup.js +83 -0
- package/dist/safe-bash/shell/cleanup.js.map +1 -0
- package/dist/safe-bash/shell/conditional.d.ts +48 -0
- package/dist/safe-bash/shell/conditional.d.ts.map +1 -0
- package/dist/safe-bash/shell/conditional.js +218 -0
- package/dist/safe-bash/shell/conditional.js.map +1 -0
- package/dist/safe-bash/shell/display.d.ts +3 -0
- package/dist/safe-bash/shell/display.d.ts.map +1 -0
- package/dist/safe-bash/shell/display.js +57 -0
- package/dist/safe-bash/shell/display.js.map +1 -0
- package/dist/safe-bash/shell/getopts.d.ts +46 -0
- package/dist/safe-bash/shell/getopts.d.ts.map +1 -0
- package/dist/safe-bash/shell/getopts.js +215 -0
- package/dist/safe-bash/shell/getopts.js.map +1 -0
- package/dist/safe-bash/shell/index.d.ts +5 -0
- package/dist/safe-bash/shell/index.d.ts.map +1 -0
- package/dist/safe-bash/shell/index.js +4 -0
- package/dist/safe-bash/shell/index.js.map +1 -0
- package/dist/safe-bash/shell/input.d.ts +26 -0
- package/dist/safe-bash/shell/input.d.ts.map +1 -0
- package/dist/safe-bash/shell/input.js +323 -0
- package/dist/safe-bash/shell/input.js.map +1 -0
- package/dist/safe-bash/shell/locale.d.ts +2 -0
- package/dist/safe-bash/shell/locale.d.ts.map +1 -0
- package/dist/safe-bash/shell/locale.js +5 -0
- package/dist/safe-bash/shell/locale.js.map +1 -0
- package/dist/safe-bash/shell/parser.d.ts +149 -0
- package/dist/safe-bash/shell/parser.d.ts.map +1 -0
- package/dist/safe-bash/shell/parser.js +1023 -0
- package/dist/safe-bash/shell/parser.js.map +1 -0
- package/dist/safe-bash/shell/pattern.d.ts +9 -0
- package/dist/safe-bash/shell/pattern.d.ts.map +1 -0
- package/dist/safe-bash/shell/pattern.js +134 -0
- package/dist/safe-bash/shell/pattern.js.map +1 -0
- package/dist/safe-bash/shell/pipestatus.d.ts +6 -0
- package/dist/safe-bash/shell/pipestatus.d.ts.map +1 -0
- package/dist/safe-bash/shell/pipestatus.js +82 -0
- package/dist/safe-bash/shell/pipestatus.js.map +1 -0
- package/dist/safe-bash/shell/runtime.d.ts +282 -0
- package/dist/safe-bash/shell/runtime.d.ts.map +1 -0
- package/dist/safe-bash/shell/runtime.js +5400 -0
- package/dist/safe-bash/shell/runtime.js.map +1 -0
- package/dist/safe-bash/shell/shell.d.ts +15 -0
- package/dist/safe-bash/shell/shell.d.ts.map +1 -0
- package/dist/safe-bash/shell/shell.js +355 -0
- package/dist/safe-bash/shell/shell.js.map +1 -0
- package/dist/safe-bash/shell/types.d.ts +76 -0
- package/dist/safe-bash/shell/types.d.ts.map +1 -0
- package/dist/safe-bash/shell/types.js +25 -0
- package/dist/safe-bash/shell/types.js.map +1 -0
- package/dist/safe-bash/shell/value-state.d.ts +57 -0
- package/dist/safe-bash/shell/value-state.d.ts.map +1 -0
- package/dist/safe-bash/shell/value-state.js +275 -0
- package/dist/safe-bash/shell/value-state.js.map +1 -0
- package/package.json +143 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
import { nodeLimits } from "./types.js";
|
|
2
|
+
import { text } from "./values.js";
|
|
3
|
+
import { lowerNodeSource } from "./lower.js";
|
|
4
|
+
import { nodeValueRules } from "./rules.js";
|
|
5
|
+
const library = String.raw `
|
|
6
|
+
|
|
7
|
+
(function (__vnodeRaw, __vnodeContext, __vnodeGuest) {
|
|
8
|
+
const nativeJSON = JSON;
|
|
9
|
+
const nativeObject = Object;
|
|
10
|
+
const nativeArray = Array;
|
|
11
|
+
const nativePromise = Promise;
|
|
12
|
+
const nativeString = String;
|
|
13
|
+
const nativeError = Error;
|
|
14
|
+
${nodeValueRules}
|
|
15
|
+
function unsupported() { const error = new nativeError('Unsupported restricted Node operation'); error.code = 'ERR_VNODE_UNSUPPORTED'; throw error; }
|
|
16
|
+
function utf8(value, maximum) {
|
|
17
|
+
if (typeof value !== 'string' || value.length > maximum) unsupported();
|
|
18
|
+
let total = 0;
|
|
19
|
+
for (let offset = 0; offset < value.length; offset = offset + 1) {
|
|
20
|
+
const first = value.charCodeAt(offset);
|
|
21
|
+
if (first < 128) total = total + 1;
|
|
22
|
+
else if (first < 2048) total = total + 2;
|
|
23
|
+
else if (first >= 55296 && first <= 56319 && offset + 1 < value.length && value.charCodeAt(offset + 1) >= 56320 && value.charCodeAt(offset + 1) <= 57343) { total = total + 4; offset = offset + 1; }
|
|
24
|
+
else total = total + 3;
|
|
25
|
+
if (total > maximum) unsupported();
|
|
26
|
+
}
|
|
27
|
+
return total;
|
|
28
|
+
}
|
|
29
|
+
function primitive(value) {
|
|
30
|
+
if (value !== null && typeof value !== 'undefined' && typeof value !== 'string' && typeof value !== 'number' && typeof value !== 'boolean') unsupported();
|
|
31
|
+
return nativeString(value);
|
|
32
|
+
}
|
|
33
|
+
function tuple(argumentsValue, maximum) {
|
|
34
|
+
if (argumentsValue.length > maximum) unsupported();
|
|
35
|
+
const result = [];
|
|
36
|
+
for (let index = 0; index < argumentsValue.length; index = index + 1) result.push(argumentsValue[index]);
|
|
37
|
+
return result;
|
|
38
|
+
}
|
|
39
|
+
function pathValue(value) { utf8(value, 1024); if (value.indexOf('\u0000') !== -1) unsupported(); return value; }
|
|
40
|
+
function call(op, authority, path, flag, body, moduleKey) {
|
|
41
|
+
const envelope = nativeJSON.parse(__vnodeRaw(op, authority, path, flag, body, moduleKey));
|
|
42
|
+
let failure;
|
|
43
|
+
if (envelope.error !== null) {
|
|
44
|
+
failure = new nativeError(envelope.error.message);
|
|
45
|
+
failure.name = envelope.error.name;
|
|
46
|
+
failure.code = envelope.error.code;
|
|
47
|
+
if (envelope.kind === 'fsError') {
|
|
48
|
+
failure.errno = envelope.error.errno;
|
|
49
|
+
if (envelope.error.path !== null) failure.path = envelope.error.path;
|
|
50
|
+
if (envelope.error.syscall !== null) failure.syscall = envelope.error.syscall;
|
|
51
|
+
if (envelope.error.dest !== null) failure.dest = envelope.error.dest;
|
|
52
|
+
}
|
|
53
|
+
remember(failure, 'error', false);
|
|
54
|
+
}
|
|
55
|
+
__vnodeRaw('delivered', 'postcopy-v1', nativeString(envelope.sequence), envelope.kind, null, null);
|
|
56
|
+
if (failure !== undefined) throw failure;
|
|
57
|
+
return envelope;
|
|
58
|
+
}
|
|
59
|
+
function options(value, writing, fd) {
|
|
60
|
+
if (value === 'utf8') return writing ? 'w' : 'r';
|
|
61
|
+
if (value === null || typeof value !== 'object' || nativeArray.isArray(value)) unsupported();
|
|
62
|
+
const keys = nativeObject.keys(value);
|
|
63
|
+
if (keys.length > 2) unsupported();
|
|
64
|
+
for (let index = 0; index < keys.length; index = index + 1) if (keys[index] !== 'encoding' && keys[index] !== 'flag') unsupported();
|
|
65
|
+
if (nativeObject.hasOwn(value, 'encoding') ? value.encoding !== 'utf8' : !writing) unsupported();
|
|
66
|
+
if (nativeObject.hasOwn(value, 'flag') && (fd || (writing ? value.flag !== 'w' && value.flag !== 'wx' : value.flag !== 'r'))) unsupported();
|
|
67
|
+
return nativeObject.hasOwn(value, 'flag') ? value.flag : writing ? 'w' : 'r';
|
|
68
|
+
}
|
|
69
|
+
const fs = nativeObject.freeze({
|
|
70
|
+
readFileSync: function (path, encoding) {
|
|
71
|
+
if (arguments.length !== 2) unsupported();
|
|
72
|
+
options(encoding, false, path === 0);
|
|
73
|
+
if (path === 0) return call('readText', 'stdin', null, 'r', null, null).text;
|
|
74
|
+
return call('readText', 'data', pathValue(path), 'r', null, null).text;
|
|
75
|
+
},
|
|
76
|
+
writeFileSync: function (path, value, encoding) {
|
|
77
|
+
if (arguments.length !== 2 && arguments.length !== 3) unsupported();
|
|
78
|
+
const filename = pathValue(path);
|
|
79
|
+
utf8(value, 1048576);
|
|
80
|
+
const flag = arguments.length === 2 ? 'w' : options(encoding, true, false);
|
|
81
|
+
call('writeText', 'data', filename, flag, value, null);
|
|
82
|
+
return undefined;
|
|
83
|
+
}
|
|
84
|
+
});
|
|
85
|
+
function write(channel, value) { utf8(value, 1048576); call('writeOutput', channel, null, null, value, null); return true; }
|
|
86
|
+
const process = nativeObject.freeze({
|
|
87
|
+
argv: __vnodeContext.argv,
|
|
88
|
+
env: __vnodeContext.env,
|
|
89
|
+
cwd: function () { if (arguments.length !== 0) unsupported(); return __vnodeContext.cwd; },
|
|
90
|
+
execPath: '/virtual/bin/node',
|
|
91
|
+
stdin: nativeObject.freeze({fd: 0}),
|
|
92
|
+
stdout: nativeObject.freeze({fd: 1, write: function (value) { if (arguments.length !== 1) unsupported(); return write('stdout', value); }}),
|
|
93
|
+
stderr: nativeObject.freeze({fd: 2, write: function (value) { if (arguments.length !== 1) unsupported(); return write('stderr', value); }})
|
|
94
|
+
});
|
|
95
|
+
function logging(channel, values) {
|
|
96
|
+
let output = '';
|
|
97
|
+
for (let index = 0; index < values.length; index = index + 1) {
|
|
98
|
+
const current = primitive(values[index]);
|
|
99
|
+
utf8(current, 1048576);
|
|
100
|
+
if (output.length + current.length + 2 > 1048576) unsupported();
|
|
101
|
+
if (index > 0) output = output + ' ';
|
|
102
|
+
output = output + current;
|
|
103
|
+
}
|
|
104
|
+
utf8(output, 1048575);
|
|
105
|
+
write(channel, output + '\n');
|
|
106
|
+
}
|
|
107
|
+
const console = nativeObject.freeze({
|
|
108
|
+
log: function () { logging('stdout', tuple(arguments, 16)); },
|
|
109
|
+
error: function () { logging('stderr', tuple(arguments, 16)); }
|
|
110
|
+
});
|
|
111
|
+
function pathMethod(method, minimum, maximum) {
|
|
112
|
+
return function () {
|
|
113
|
+
const values = tuple(arguments, maximum);
|
|
114
|
+
if (values.length < minimum) unsupported();
|
|
115
|
+
for (let index = 0; index < values.length; index = index + 1) pathValue(values[index]);
|
|
116
|
+
const result = call('path', 'path', null, null, nativeJSON.stringify(values), method).text;
|
|
117
|
+
return method === 'isAbsolute' ? result === 'true' : result;
|
|
118
|
+
};
|
|
119
|
+
}
|
|
120
|
+
const path = {
|
|
121
|
+
join: pathMethod('join', 0, 16), resolve: pathMethod('resolve', 0, 16),
|
|
122
|
+
normalize: pathMethod('normalize', 1, 1), dirname: pathMethod('dirname', 1, 1),
|
|
123
|
+
basename: pathMethod('basename', 1, 2), extname: pathMethod('extname', 1, 1),
|
|
124
|
+
relative: pathMethod('relative', 2, 2), isAbsolute: pathMethod('isAbsolute', 1, 1),
|
|
125
|
+
sep: '/', delimiter: ':'
|
|
126
|
+
};
|
|
127
|
+
path.posix = path;
|
|
128
|
+
nativeObject.freeze(path);
|
|
129
|
+
const cache = {};
|
|
130
|
+
let roots = 0;
|
|
131
|
+
let jsonBytes = 0;
|
|
132
|
+
function require(target) {
|
|
133
|
+
if (arguments.length !== 1 || typeof target !== 'string') unsupported();
|
|
134
|
+
utf8(target, 1024);
|
|
135
|
+
const name = target.slice(0, 5) === 'node:' ? target.slice(5) : target;
|
|
136
|
+
if (name === 'fs' || name === 'path' || name === 'process') {
|
|
137
|
+
call('authorizeModule', 'module', null, null, null, name);
|
|
138
|
+
return name === 'fs' ? fs : name === 'path' ? path : process;
|
|
139
|
+
}
|
|
140
|
+
if ((target.slice(0, 2) !== './' && target.slice(0, 3) !== '../' && target.slice(0, 1) !== '/') || target.slice(-5) !== '.json') unsupported();
|
|
141
|
+
const authorized = call('authorizeJson', 'json', pathValue(target), 'r', null, null).cacheKey;
|
|
142
|
+
const key = nativeJSON.stringify([authorized.namespace, authorized.path]);
|
|
143
|
+
if (nativeObject.hasOwn(cache, key)) return cache[key];
|
|
144
|
+
if (roots >= 32) unsupported();
|
|
145
|
+
const result = call('readText', 'json', authorized.path, 'r', null, null);
|
|
146
|
+
if (result.cacheKey.namespace !== authorized.namespace || result.cacheKey.path !== authorized.path) unsupported();
|
|
147
|
+
const size = utf8(result.text, 1048576);
|
|
148
|
+
if (size > 1048576 - jsonBytes) unsupported();
|
|
149
|
+
jsonBytes = jsonBytes + size;
|
|
150
|
+
const parsed = recordTree(nativeJSON.parse(result.text), 0);
|
|
151
|
+
cache[key] = parsed;
|
|
152
|
+
roots = roots + 1;
|
|
153
|
+
return parsed;
|
|
154
|
+
}
|
|
155
|
+
function jsonValue(value, ancestors) {
|
|
156
|
+
const kind = typeof value;
|
|
157
|
+
if (value === null || kind === 'string' || kind === 'number' || kind === 'boolean' || kind === 'undefined') return;
|
|
158
|
+
if (kind !== 'object') unsupported();
|
|
159
|
+
if (category(value).kind === 'error' || category(value).kind === 'promise') unsupported();
|
|
160
|
+
if (ancestors.length >= 128) unsupported();
|
|
161
|
+
for (let index = 0; index < ancestors.length; index = index + 1) if (ancestors[index] === value) throw new TypeError('Cyclic JSON value');
|
|
162
|
+
const path = ancestors.slice(); path.push(value);
|
|
163
|
+
const keys = nativeObject.keys(value);
|
|
164
|
+
if (nativeArray.isArray(value)) {
|
|
165
|
+
if (keys.length !== value.length) unsupported();
|
|
166
|
+
for (let index = 0; index < value.length; index = index + 1) { if (!nativeObject.hasOwn(value, nativeString(index))) unsupported(); jsonValue(value[index], path); }
|
|
167
|
+
} else for (let index = 0; index < keys.length; index = index + 1) jsonValue(value[keys[index]], path);
|
|
168
|
+
}
|
|
169
|
+
const safeJSON = nativeObject.freeze({
|
|
170
|
+
parse: function (value) { if (arguments.length !== 1) unsupported(); utf8(value, 1048576); return recordTree(nativeJSON.parse(value), 0); },
|
|
171
|
+
stringify: function (value, replacer, space) {
|
|
172
|
+
if (arguments.length !== 1 && arguments.length !== 3) unsupported();
|
|
173
|
+
if (arguments.length === 3 && (replacer !== undefined || typeof space !== 'number' || space < 0 || space > 10 || space % 1 !== 0)) unsupported();
|
|
174
|
+
jsonValue(value, []);
|
|
175
|
+
const result = arguments.length === 1 ? nativeJSON.stringify(value) : nativeJSON.stringify(value, undefined, space);
|
|
176
|
+
if (result !== undefined) utf8(result, 1048576);
|
|
177
|
+
return result;
|
|
178
|
+
}
|
|
179
|
+
});
|
|
180
|
+
const safeObject = nativeObject.freeze({
|
|
181
|
+
keys: function (value) { if (arguments.length !== 1) unsupported(); return ownKeys(value); },
|
|
182
|
+
hasOwn: function (value, name) { if (arguments.length !== 2 || typeof name !== 'string') unsupported(); const keys = ownKeys(value); for (let index = 0; index < keys.length; index = index + 1) if (keys[index] === name) return true; return false; }
|
|
183
|
+
});
|
|
184
|
+
const safeArray = nativeObject.freeze({ isArray: function (value) { if (arguments.length !== 1) unsupported(); return nativeArray.isArray(value); } });
|
|
185
|
+
const safePromise = nativeObject.freeze({
|
|
186
|
+
resolve: function (value) { if (arguments.length !== 1) unsupported(); if (value !== null && typeof value === 'object' && category(value).kind !== 'promise' && typeof value.then === 'function') unsupported(); return remember(nativePromise.resolve(value), 'promise', true); },
|
|
187
|
+
reject: function (value) { if (arguments.length !== 1) unsupported(); return remember(nativePromise.reject(value), 'promise', true); },
|
|
188
|
+
race: function (value) { if (arguments.length !== 1 || !nativeArray.isArray(value) || value.length !== 0 || nativeObject.keys(value).length !== 0) unsupported(); return remember(nativePromise.race(value), 'promise', true); }
|
|
189
|
+
});
|
|
190
|
+
function errorConstructor(factory) { return function (message) { if (arguments.length > 1 || arguments.length === 1 && typeof message !== 'string') unsupported(); return remember(arguments.length === 0 ? new factory() : new factory(message), 'error', false); }; }
|
|
191
|
+
function stringConstructor(value) { if (arguments.length !== 1) unsupported(); return primitive(value); }
|
|
192
|
+
remember(process, 'facade', true); remember(process.env, 'env', false); remember(process.argv, 'array', false);
|
|
193
|
+
remember(process.stdin, 'facade', true); remember(process.stdout, 'facade', true); remember(process.stderr, 'facade', true);
|
|
194
|
+
remember(console, 'facade', true); remember(fs, 'facade', true); remember(path, 'facade', true);
|
|
195
|
+
remember(safeJSON, 'facade', true); remember(safeObject, 'facade', true); remember(safeArray, 'facade', true); remember(safePromise, 'facade', true);
|
|
196
|
+
const returned = __vnodeGuest(require, console, process, safeJSON, safeObject, safeArray, safePromise, errorConstructor(Error), errorConstructor(TypeError), errorConstructor(RangeError), errorConstructor(SyntaxError), errorConstructor(ReferenceError), stringConstructor, __vnodeContext.filename, __vnodeContext.directory, __vnodeRules);
|
|
197
|
+
if (__vnodeContext.selector === 'print') {
|
|
198
|
+
if (returned !== null && typeof returned !== 'undefined' && typeof returned !== 'string' && typeof returned !== 'number' && typeof returned !== 'boolean') {
|
|
199
|
+
__vnodeRaw('printRefusal', null, null, null, null, null);
|
|
200
|
+
unsupported();
|
|
201
|
+
}
|
|
202
|
+
logging('stdout', [returned]);
|
|
203
|
+
}
|
|
204
|
+
__vnodeRaw('cutoff', null, null, null, null, null);
|
|
205
|
+
})(__vnodeBridge, __vnodeContext, __vnodeEntry);
|
|
206
|
+
`;
|
|
207
|
+
export function buildNodeProgram(source, selector) {
|
|
208
|
+
const names = "require,console,process,JSON,Object,Array,Promise,Error,TypeError,RangeError,SyntaxError,ReferenceError,String,__vnodeFilename,__vnodeDirectory,__vnodeRules";
|
|
209
|
+
const lowered = lowerNodeSource(source, selector);
|
|
210
|
+
const body = selector === "print" ? "return (\n" + lowered + "\n);" : lowered;
|
|
211
|
+
const bindings = selector === "file" ? "const __filename = __vnodeFilename; const __dirname = __vnodeDirectory;\n" : "";
|
|
212
|
+
const marker = "__vnodeBridge('entry', null, null, null, null, null);\n";
|
|
213
|
+
const program = "const __vnodeEntry = function(" + names + ") {\n" + marker + bindings + body + "\n};\n" + library;
|
|
214
|
+
return text(program, nodeLimits.sourceBytes, "combined interpreted source");
|
|
215
|
+
}
|
|
216
|
+
//# sourceMappingURL=program.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"program.js","sourceRoot":"","sources":["../../../src/commands/node/program.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAqB,MAAM,YAAY,CAAC;AAC3D,OAAO,EAAE,IAAI,EAAE,MAAM,aAAa,CAAC;AACnC,OAAO,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC;AAC7C,OAAO,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAE5C,MAAM,OAAO,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;EASxB,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgMf,CAAC;AAEF,MAAM,UAAU,gBAAgB,CAAC,MAAc,EAAE,QAAsB;IACrE,MAAM,KAAK,GAAG,8JAA8J,CAAC;IAC7K,MAAM,OAAO,GAAG,eAAe,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;IAClD,MAAM,IAAI,GAAG,QAAQ,KAAK,OAAO,CAAC,CAAC,CAAC,YAAY,GAAG,OAAO,GAAG,MAAM,CAAC,CAAC,CAAC,OAAO,CAAC;IAC9E,MAAM,QAAQ,GAAG,QAAQ,KAAK,MAAM,CAAC,CAAC,CAAC,2EAA2E,CAAC,CAAC,CAAC,EAAE,CAAC;IACxH,MAAM,MAAM,GAAG,yDAAyD,CAAC;IACzE,MAAM,OAAO,GAAG,gCAAgC,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,GAAG,QAAQ,GAAG,IAAI,GAAG,QAAQ,GAAG,OAAO,CAAC;IACnH,OAAO,IAAI,CAAC,OAAO,EAAE,UAAU,CAAC,WAAW,EAAE,6BAA6B,CAAC,CAAC;AAC9E,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rules.d.ts","sourceRoot":"","sources":["../../../src/commands/node/rules.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,cAAc,QAoI1B,CAAC"}
|
|
@@ -0,0 +1,134 @@
|
|
|
1
|
+
export const nodeValueRules = String.raw `
|
|
2
|
+
const valueRecords = [];
|
|
3
|
+
function remember(value, kind, locked) {
|
|
4
|
+
if (value === null || typeof value !== 'object') return value;
|
|
5
|
+
for (let index = 0; index < valueRecords.length; index = index + 1) if (valueRecords[index].value === value) return value;
|
|
6
|
+
if (valueRecords.length >= 100000) unsupported();
|
|
7
|
+
valueRecords.push({value: value, kind: kind, locked: locked});
|
|
8
|
+
return value;
|
|
9
|
+
}
|
|
10
|
+
function category(value) {
|
|
11
|
+
if (typeof value !== 'object' || value === null) return {kind: typeof value, locked: true};
|
|
12
|
+
for (let index = 0; index < valueRecords.length; index = index + 1) if (valueRecords[index].value === value) return valueRecords[index];
|
|
13
|
+
if (nativeArray.isArray(value)) { remember(value, 'array', false); return category(value); }
|
|
14
|
+
if (typeof value.then === 'function') { remember(value, 'promise', true); return category(value); }
|
|
15
|
+
if (typeof value.name === 'string' && typeof value.message === 'string') { remember(value, 'error', false); return category(value); }
|
|
16
|
+
unsupported();
|
|
17
|
+
}
|
|
18
|
+
function recordTree(value, depth) {
|
|
19
|
+
if (value === null || typeof value !== 'object') return value;
|
|
20
|
+
if (depth > 128) unsupported();
|
|
21
|
+
remember(value, nativeArray.isArray(value) ? 'array' : 'record', false);
|
|
22
|
+
const keys = nativeObject.keys(value);
|
|
23
|
+
for (let index = 0; index < keys.length; index = index + 1) recordTree(value[keys[index]], depth + 1);
|
|
24
|
+
return value;
|
|
25
|
+
}
|
|
26
|
+
function propertyKey(value) { if (typeof value !== 'string' && typeof value !== 'number') unsupported(); return nativeString(value); }
|
|
27
|
+
function computedKey(value) { if (typeof value !== 'string') unsupported(); return value; }
|
|
28
|
+
function arrayIndex(key) {
|
|
29
|
+
if (key === '') return -1;
|
|
30
|
+
const index = +key;
|
|
31
|
+
if (index < 0 || index % 1 !== 0 || nativeString(index) !== key) return -1;
|
|
32
|
+
return index;
|
|
33
|
+
}
|
|
34
|
+
function primitiveValue(value) { if (value !== null && (typeof value === 'object' || typeof value === 'function')) unsupported(); return value; }
|
|
35
|
+
function detached() { unsupported(); }
|
|
36
|
+
function getValue(object, rawKey) {
|
|
37
|
+
const key = propertyKey(rawKey);
|
|
38
|
+
if (object === null || object === undefined) throw new TypeError('Cannot read a nullish value');
|
|
39
|
+
const record = category(object);
|
|
40
|
+
if (typeof object === 'string') {
|
|
41
|
+
if (key === 'length') return object.length;
|
|
42
|
+
const index = arrayIndex(key); if (index >= 0) return object[index];
|
|
43
|
+
if (key === 'slice' || key === 'trim') return detached;
|
|
44
|
+
unsupported();
|
|
45
|
+
}
|
|
46
|
+
if (typeof object === 'function') { if (key === 'name' || key === 'length') return object[key]; unsupported(); }
|
|
47
|
+
if (record.kind === 'array') {
|
|
48
|
+
if (key === 'length') return object.length;
|
|
49
|
+
const index = arrayIndex(key); if (index >= 0) return index < object.length ? object[index] : undefined;
|
|
50
|
+
if (key === 'push' || key === 'map') return detached;
|
|
51
|
+
unsupported();
|
|
52
|
+
}
|
|
53
|
+
if (record.kind === 'promise') { if (key === 'then' || key === 'catch' || key === 'finally') return detached; unsupported(); }
|
|
54
|
+
if (record.kind === 'error' && key !== 'name' && key !== 'message' && key !== 'code' && key !== 'errno' && key !== 'path' && key !== 'syscall' && key !== 'dest') unsupported();
|
|
55
|
+
if (record.kind === 'record' || record.kind === 'facade' || record.kind === 'env' || record.kind === 'error') return nativeObject.hasOwn(object, key) ? object[key] : undefined;
|
|
56
|
+
unsupported();
|
|
57
|
+
}
|
|
58
|
+
function reference(object, rawKey, read) { const key = propertyKey(rawKey); return {object: object, key: key, value: read ? getValue(object, key) : undefined}; }
|
|
59
|
+
function assign(target, value) {
|
|
60
|
+
const object = target.object; const key = target.key; const record = category(object);
|
|
61
|
+
if (record.locked || object === null || typeof object !== 'object') unsupported();
|
|
62
|
+
if (record.kind === 'array') {
|
|
63
|
+
if (key === 'length') { if (typeof value !== 'number' || value < 0 || value % 1 !== 0 || value > object.length) unsupported(); }
|
|
64
|
+
else { const index = arrayIndex(key); if (index < 0 || index > object.length || object === process.argv && typeof value !== 'string') unsupported(); }
|
|
65
|
+
} else if (record.kind === 'env') { if (typeof value !== 'string' || key.indexOf('\u0000') !== -1 || key.indexOf('=') !== -1 || value.indexOf('\u0000') !== -1) unsupported(); }
|
|
66
|
+
else if (record.kind === 'error') { if (key !== 'name' && key !== 'message' && key !== 'code' && key !== 'errno' && key !== 'path' && key !== 'syscall' && key !== 'dest') unsupported(); }
|
|
67
|
+
else if (record.kind !== 'record') unsupported();
|
|
68
|
+
object[key] = value; return value;
|
|
69
|
+
}
|
|
70
|
+
function binary(operator, left, right) {
|
|
71
|
+
if ((operator === '==' || operator === '!=') && left !== null && right !== null && (typeof left === 'object' || typeof left === 'function') && (typeof right === 'object' || typeof right === 'function')) return operator === '==' ? left === right : left !== right;
|
|
72
|
+
primitiveValue(left); primitiveValue(right);
|
|
73
|
+
if (operator === '+') return left + right;
|
|
74
|
+
if (operator === '-') return left - right;
|
|
75
|
+
if (operator === '*') return left * right;
|
|
76
|
+
if (operator === '/') return left / right;
|
|
77
|
+
if (operator === '%') return left % right;
|
|
78
|
+
if (operator === '**') return left ** right;
|
|
79
|
+
if (operator === '<') return left < right;
|
|
80
|
+
if (operator === '>') return left > right;
|
|
81
|
+
if (operator === '<=') return left <= right;
|
|
82
|
+
if (operator === '>=') return left >= right;
|
|
83
|
+
if (operator === '==') return left == right;
|
|
84
|
+
if (operator === '!=') return left != right;
|
|
85
|
+
unsupported();
|
|
86
|
+
}
|
|
87
|
+
function unary(operator, value) { primitiveValue(value); return operator === '+' ? +value : -value; }
|
|
88
|
+
function compound(target, operator, value) { return assign(target, binary(operator, target.value, value)); }
|
|
89
|
+
function update(target, delta, prefix) { const before = unary('+', target.value); const after = before + delta; assign(target, after); return prefix ? after : before; }
|
|
90
|
+
function updateVariable(getter, setter, delta, prefix) { const before = unary('+', getter()); const after = before + delta; setter(after); return prefix ? after : before; }
|
|
91
|
+
function remove(object, rawKey) { const key = propertyKey(rawKey); const record = category(object); if (record.locked || record.kind !== 'record' && record.kind !== 'env') unsupported(); return delete object[key]; }
|
|
92
|
+
function callable(value) { if (typeof value !== 'function') unsupported(); return value; }
|
|
93
|
+
function adopt(value) { if (value !== null && typeof value === 'object' && category(value).kind !== 'promise' && typeof value.then === 'function') unsupported(); return value; }
|
|
94
|
+
function reaction(callback, noArguments) { if (callback === undefined) return undefined; callable(callback); return function (value) { return adopt(noArguments ? callback() : callback(value)); }; }
|
|
95
|
+
function callValue(callback, args) { if (args.length > 16) unsupported(); return callable(callback)(...args); }
|
|
96
|
+
function method(object, rawKey, args) {
|
|
97
|
+
const key = propertyKey(rawKey); if (args.length > 16) unsupported();
|
|
98
|
+
if (object === null || object === undefined) throw new TypeError('Cannot call a nullish value');
|
|
99
|
+
const record = category(object);
|
|
100
|
+
if (typeof object === 'string') {
|
|
101
|
+
if (key === 'trim' && args.length === 0) return object.trim();
|
|
102
|
+
if (key === 'slice' && (args.length === 1 || args.length === 2)) {
|
|
103
|
+
for (let index = 0; index < args.length; index = index + 1) if (typeof args[index] !== 'number' || args[index] % 1 !== 0) unsupported();
|
|
104
|
+
return args.length === 1 ? object.slice(args[0]) : object.slice(args[0], args[1]);
|
|
105
|
+
}
|
|
106
|
+
unsupported();
|
|
107
|
+
}
|
|
108
|
+
if (record.kind === 'array') {
|
|
109
|
+
if (key === 'push') { for (let index = 0; index < args.length; index = index + 1) assign(reference(object, object.length, false), args[index]); return object.length; }
|
|
110
|
+
if (key === 'map' && args.length === 1) {
|
|
111
|
+
callable(args[0]); const length = object.length; const result = remember([], 'array', false);
|
|
112
|
+
for (let index = 0; index < length; index = index + 1) { if (!nativeObject.hasOwn(object, nativeString(index))) unsupported(); result.push(args[0](object[index], index, object)); }
|
|
113
|
+
return result;
|
|
114
|
+
}
|
|
115
|
+
unsupported();
|
|
116
|
+
}
|
|
117
|
+
if (record.kind === 'promise') {
|
|
118
|
+
if (key === 'then' && args.length <= 2) return remember(object.then(reaction(args[0], false), reaction(args[1], false)), 'promise', true);
|
|
119
|
+
if (key === 'catch' && args.length === 1) return remember(object.catch(reaction(callable(args[0]), false)), 'promise', true);
|
|
120
|
+
if (key === 'finally' && args.length === 1) return remember(object.finally(reaction(callable(args[0]), true)), 'promise', true);
|
|
121
|
+
unsupported();
|
|
122
|
+
}
|
|
123
|
+
return callValue(getValue(object, key), args);
|
|
124
|
+
}
|
|
125
|
+
function unbound(name) { throw new ReferenceError(name + ' is not defined'); }
|
|
126
|
+
function ownKeys(value) {
|
|
127
|
+
if (value === null || typeof value !== 'object') unsupported();
|
|
128
|
+
const kind = category(value).kind; if (kind !== 'array' && kind !== 'record' && kind !== 'env' && kind !== 'facade' && kind !== 'error') unsupported();
|
|
129
|
+
const keys = nativeObject.keys(value); if (kind !== 'error') return keys;
|
|
130
|
+
const result = []; for (let index = 0; index < keys.length; index = index + 1) if (keys[index] === 'name' || keys[index] === 'message' || keys[index] === 'code' || keys[index] === 'errno' || keys[index] === 'path' || keys[index] === 'syscall' || keys[index] === 'dest') result.push(keys[index]); return result;
|
|
131
|
+
}
|
|
132
|
+
const __vnodeRules = nativeObject.freeze({adopt: adopt, get: getValue, key: computedKey, reference: reference, assign: assign, binary: binary, unary: unary, compound: compound, update: update, updateVariable: updateVariable, remove: remove, call: callValue, method: method, unbound: unbound, object: function (value) { return remember(value, 'record', false); }, array: function (value) { return remember(value, 'array', false); }});
|
|
133
|
+
`;
|
|
134
|
+
//# sourceMappingURL=rules.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rules.js","sourceRoot":"","sources":["../../../src/commands/node/rules.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAoIvC,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { CommandDefinition } from "../../contracts/command.js";
|
|
2
|
+
import type { NodeSafeJsCommandOptions } from "./types.js";
|
|
3
|
+
export declare function createSafeJsNodeCommand<Budget>(options: NodeSafeJsCommandOptions<Budget>): CommandDefinition;
|
|
4
|
+
//# sourceMappingURL=safejs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"safejs.d.ts","sourceRoot":"","sources":["../../../src/commands/node/safejs.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AAIpE,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAiC3D,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,OAAO,EAAE,wBAAwB,CAAC,MAAM,CAAC,GAAG,iBAAiB,CAmC5G"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { UsageError } from "../internal.js";
|
|
2
|
+
import { createSafeJsCommands } from "../safejs/index.js";
|
|
3
|
+
function invocation(args) {
|
|
4
|
+
let source;
|
|
5
|
+
let print = false;
|
|
6
|
+
let index = 0;
|
|
7
|
+
for (; index < args.length; index++) {
|
|
8
|
+
const argument = args[index];
|
|
9
|
+
if (argument === "--") {
|
|
10
|
+
index++;
|
|
11
|
+
break;
|
|
12
|
+
}
|
|
13
|
+
if (argument === "-h" || argument === "--help")
|
|
14
|
+
return { file: "-", args: [], print: false, help: true };
|
|
15
|
+
if (argument === "--input-type" || argument.startsWith("--input-type=")) {
|
|
16
|
+
const value = argument === "--input-type" ? args[++index] : argument.slice(13);
|
|
17
|
+
if (value !== "module")
|
|
18
|
+
throw new UsageError("SafeJS node supports only --input-type=module");
|
|
19
|
+
continue;
|
|
20
|
+
}
|
|
21
|
+
const mode = argument === "--eval" || argument.startsWith("--eval=") || argument.startsWith("-e") ? "eval"
|
|
22
|
+
: argument === "--print" || argument.startsWith("--print=") || argument.startsWith("-p") ? "print" : undefined;
|
|
23
|
+
if (mode) {
|
|
24
|
+
if (source !== undefined)
|
|
25
|
+
throw new UsageError("conflicting source selectors");
|
|
26
|
+
print = mode === "print";
|
|
27
|
+
const equal = argument.indexOf("=");
|
|
28
|
+
source = argument.startsWith("--") ? equal >= 0 ? argument.slice(equal + 1) : args[++index]
|
|
29
|
+
: argument.length > 2 ? argument.slice(2) : args[++index];
|
|
30
|
+
if (source === undefined)
|
|
31
|
+
throw new UsageError(`${argument} requires JavaScript source`);
|
|
32
|
+
continue;
|
|
33
|
+
}
|
|
34
|
+
if (argument !== "-" && argument.startsWith("-"))
|
|
35
|
+
throw new UsageError(`unsupported node option '${argument}'`);
|
|
36
|
+
break;
|
|
37
|
+
}
|
|
38
|
+
if (source !== undefined)
|
|
39
|
+
return { source, file: print ? "<node -p>" : "<node -e>", args: args.slice(index), print, help: false };
|
|
40
|
+
return { file: args[index] ?? "-", args: args.slice(index + 1), print: false, help: false };
|
|
41
|
+
}
|
|
42
|
+
export function createSafeJsNodeCommand(options) {
|
|
43
|
+
const definitions = createSafeJsCommands(options, {
|
|
44
|
+
name: "node",
|
|
45
|
+
description: "Execute JavaScript with an injected SafeJS runtime and virtual I/O",
|
|
46
|
+
help: "Usage: node [-e SOURCE | -p EXPRESSION | FILE | -] [ARG...]\nExecutes with the injected SafeJS interpreter; no native Node.js process.\nSupports --eval, --print, --input-type=module and -- before operands.\nNo source operand reads stdin. Files and inline source leave stdin for guest data.\nUse async imports from fs or require(\"node:fs/promises\").\nNative modules, synchronous fs and local module loading are not supported.\n",
|
|
47
|
+
invocation,
|
|
48
|
+
prepare(source, selected, modules) {
|
|
49
|
+
const command = modules.command;
|
|
50
|
+
const stdio = modules.stdio;
|
|
51
|
+
const fs = modules.fs;
|
|
52
|
+
const processModule = {
|
|
53
|
+
argv: ["/virtual/bin/node", ...(selected.source === undefined ? [selected.file] : []), ...selected.args],
|
|
54
|
+
env: command.env,
|
|
55
|
+
cwd: options.runtime.declareHostOperation(() => command.cwd, "read-side-effect"),
|
|
56
|
+
exitCode: 0,
|
|
57
|
+
stdin: { readText: stdio.readText, readBytes: stdio.readBytes },
|
|
58
|
+
stdout: { write: stdio.write },
|
|
59
|
+
stderr: { write: stdio.error },
|
|
60
|
+
};
|
|
61
|
+
modules.fs = { ...fs, default: fs };
|
|
62
|
+
const requiredModules = new Map([["fs/promises", fs], ["node:fs/promises", fs]]);
|
|
63
|
+
return {
|
|
64
|
+
source: (selected.print ? `console.log((\n${source}\n));` : source) + "\n;__safeBashSetExitCode(process.exitCode);",
|
|
65
|
+
bindings: {
|
|
66
|
+
process: processModule, __safeBashSetExitCode: command.setExitCode,
|
|
67
|
+
require: options.runtime.declareHostOperation((name) => {
|
|
68
|
+
const module = typeof name === "string" ? requiredModules.get(name) : undefined;
|
|
69
|
+
if (!module)
|
|
70
|
+
throw new TypeError("Unsupported node module; use fs/promises or node:fs/promises");
|
|
71
|
+
return module;
|
|
72
|
+
}, "read-side-effect"),
|
|
73
|
+
},
|
|
74
|
+
};
|
|
75
|
+
},
|
|
76
|
+
});
|
|
77
|
+
return Object.freeze(definitions[0]);
|
|
78
|
+
}
|
|
79
|
+
//# sourceMappingURL=safejs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"safejs.js","sourceRoot":"","sources":["../../../src/commands/node/safejs.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,143 @@
|
|
|
1
|
+
import type { CommandDefinition } from "../../contracts/command.js";
|
|
2
|
+
import type { SafeJsCommandLimits, SafeJsRuntime } from "../safejs/types.js";
|
|
3
|
+
export declare const NODE_PROFILE: "NP1-CJS-WRQ-L-SYNC-1";
|
|
4
|
+
export declare const nodeLimits: Readonly<{
|
|
5
|
+
sourceBytes: 262144;
|
|
6
|
+
contextBytes: 65536;
|
|
7
|
+
pathBytes: 1024;
|
|
8
|
+
metadataBytes: 8192;
|
|
9
|
+
errorBytes: 1024;
|
|
10
|
+
operations: 128;
|
|
11
|
+
frames: 4096;
|
|
12
|
+
wakes: 8192;
|
|
13
|
+
operationBytes: 1048576;
|
|
14
|
+
readBytes: 4194304;
|
|
15
|
+
writeBytes: 4194304;
|
|
16
|
+
outputBytes: 1048576;
|
|
17
|
+
jsonBytes: 1048576;
|
|
18
|
+
jsonEntries: 32;
|
|
19
|
+
memoryBytes: 16777216;
|
|
20
|
+
diagnosticReserve: 1048576;
|
|
21
|
+
sabBytes: 197056;
|
|
22
|
+
admissionMs: 5000;
|
|
23
|
+
steps: 100000;
|
|
24
|
+
callDepth: 128;
|
|
25
|
+
oldGenerationMiB: 32;
|
|
26
|
+
youngGenerationMiB: 8;
|
|
27
|
+
codeMiB: 8;
|
|
28
|
+
stackMiB: 4;
|
|
29
|
+
}>;
|
|
30
|
+
export interface NodeGrants {
|
|
31
|
+
readonly sourceRead?: boolean;
|
|
32
|
+
readonly dataRead?: boolean;
|
|
33
|
+
readonly dataWrite?: boolean;
|
|
34
|
+
readonly jsonModules?: boolean;
|
|
35
|
+
readonly stdinRead?: boolean;
|
|
36
|
+
readonly stdoutWrite?: boolean;
|
|
37
|
+
readonly stderrWrite?: boolean;
|
|
38
|
+
}
|
|
39
|
+
export type NodeSelector = "eval" | "print" | "file" | "stdin";
|
|
40
|
+
export interface NodeSourceRequest {
|
|
41
|
+
readonly profile: typeof NODE_PROFILE;
|
|
42
|
+
readonly selector: NodeSelector;
|
|
43
|
+
readonly source: string;
|
|
44
|
+
readonly program: string;
|
|
45
|
+
readonly filename: string;
|
|
46
|
+
readonly cwd: string;
|
|
47
|
+
readonly argv: readonly string[];
|
|
48
|
+
readonly env: Readonly<Record<string, string>>;
|
|
49
|
+
readonly grants: Readonly<Required<NodeGrants>>;
|
|
50
|
+
readonly limits: typeof nodeLimits;
|
|
51
|
+
}
|
|
52
|
+
export type NodeOperation = "authorizeModule" | "authorizeJson" | "readText" | "writeText" | "writeOutput" | "path";
|
|
53
|
+
export interface NodeHostRequest {
|
|
54
|
+
readonly sequence: number;
|
|
55
|
+
readonly op: NodeOperation;
|
|
56
|
+
readonly authority: "module" | "json" | "data" | "stdin" | "stdout" | "stderr" | "path";
|
|
57
|
+
readonly path: string | null;
|
|
58
|
+
readonly flag: "r" | "w" | "wx" | null;
|
|
59
|
+
readonly text: string | null;
|
|
60
|
+
readonly moduleKey: string | null;
|
|
61
|
+
}
|
|
62
|
+
export interface NodeGuestError {
|
|
63
|
+
readonly name: string;
|
|
64
|
+
readonly message: string;
|
|
65
|
+
readonly code: string;
|
|
66
|
+
readonly errno: number | null;
|
|
67
|
+
readonly path: string | null;
|
|
68
|
+
readonly syscall: string | null;
|
|
69
|
+
readonly dest: string | null;
|
|
70
|
+
}
|
|
71
|
+
export interface NodeHostResponse {
|
|
72
|
+
readonly sequence: number;
|
|
73
|
+
readonly kind: "void" | "text" | "fsError" | "unsupported" | "denied";
|
|
74
|
+
readonly text: string | null;
|
|
75
|
+
readonly error: NodeGuestError | null;
|
|
76
|
+
readonly cacheKey: {
|
|
77
|
+
readonly namespace: number;
|
|
78
|
+
readonly path: string;
|
|
79
|
+
} | null;
|
|
80
|
+
}
|
|
81
|
+
export interface NodeReason {
|
|
82
|
+
readonly present: true;
|
|
83
|
+
readonly value: unknown;
|
|
84
|
+
}
|
|
85
|
+
export interface NodeObservation {
|
|
86
|
+
readonly state: "captured" | "unknown";
|
|
87
|
+
readonly fault: boolean;
|
|
88
|
+
readonly name: string | null;
|
|
89
|
+
readonly message: string | null;
|
|
90
|
+
readonly code: string | null;
|
|
91
|
+
}
|
|
92
|
+
export interface NodeCompletion {
|
|
93
|
+
readonly kind: "entryReturned" | "guestFailure" | "profileFailure";
|
|
94
|
+
readonly observation: NodeObservation;
|
|
95
|
+
}
|
|
96
|
+
export interface NodeRetirement {
|
|
97
|
+
readonly acquisition: "none" | "exited";
|
|
98
|
+
readonly exitCode: number | null;
|
|
99
|
+
}
|
|
100
|
+
export interface NodeHostServices {
|
|
101
|
+
readonly signal: AbortSignal;
|
|
102
|
+
readonly request: (request: NodeHostRequest) => Promise<NodeHostResponse>;
|
|
103
|
+
readonly delivered: (sequence: number) => void;
|
|
104
|
+
readonly reserve: (label: string, bytes: number) => () => void;
|
|
105
|
+
readonly cutoff: () => void;
|
|
106
|
+
readonly fail: (reason: NodeReason) => void;
|
|
107
|
+
readonly stopProfile: (reason: NodeReason) => void;
|
|
108
|
+
readonly job: <Value>(start: () => Value | PromiseLike<Value>) => Promise<Value>;
|
|
109
|
+
}
|
|
110
|
+
export interface NodeSession {
|
|
111
|
+
readonly start: () => Promise<NodeCompletion>;
|
|
112
|
+
readonly cancel: (reason: NodeReason) => void;
|
|
113
|
+
readonly retire: () => Promise<NodeRetirement>;
|
|
114
|
+
}
|
|
115
|
+
export interface NodeRuntimeProvider {
|
|
116
|
+
readonly profile: typeof NODE_PROFILE;
|
|
117
|
+
readonly identity: string;
|
|
118
|
+
readonly prepare: (request: NodeSourceRequest, services: NodeHostServices) => NodeSession;
|
|
119
|
+
}
|
|
120
|
+
export interface NodeProviderCommandOptions {
|
|
121
|
+
readonly provider: NodeRuntimeProvider;
|
|
122
|
+
readonly grants?: NodeGrants;
|
|
123
|
+
readonly runtime?: never;
|
|
124
|
+
readonly limits?: never;
|
|
125
|
+
}
|
|
126
|
+
export interface NodeSafeJsCommandOptions<Budget = unknown> {
|
|
127
|
+
readonly runtime: SafeJsRuntime<Budget>;
|
|
128
|
+
readonly limits?: Partial<SafeJsCommandLimits>;
|
|
129
|
+
readonly provider?: never;
|
|
130
|
+
readonly grants?: never;
|
|
131
|
+
}
|
|
132
|
+
export type NodeCommandOptions<Budget = unknown> = NodeProviderCommandOptions | NodeSafeJsCommandOptions<Budget>;
|
|
133
|
+
export type NodeCommandFactory = (options: NodeCommandOptions) => CommandDefinition;
|
|
134
|
+
export declare class NodeProfileError extends Error {
|
|
135
|
+
readonly resource: string;
|
|
136
|
+
readonly code = "ERR_VNODE_PROFILE";
|
|
137
|
+
constructor(resource: string);
|
|
138
|
+
}
|
|
139
|
+
export declare class NodeUsageError extends Error {
|
|
140
|
+
readonly code = "ERR_VNODE_UNSUPPORTED";
|
|
141
|
+
constructor(message: string);
|
|
142
|
+
}
|
|
143
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/commands/node/types.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export const NODE_PROFILE = "NP1-CJS-WRQ-L-SYNC-1";
|
|
2
|
+
export const nodeLimits = Object.freeze({ sourceBytes: 262144, contextBytes: 65536, pathBytes: 1024, metadataBytes: 8192, errorBytes: 1024, operations: 128, frames: 4096, wakes: 8192, operationBytes: 1048576, readBytes: 4194304, writeBytes: 4194304, outputBytes: 1048576, jsonBytes: 1048576, jsonEntries: 32, memoryBytes: 16777216, diagnosticReserve: 1048576, sabBytes: 197056, admissionMs: 5000, steps: 100000, callDepth: 128, oldGenerationMiB: 32, youngGenerationMiB: 8, codeMiB: 8, stackMiB: 4 });
|
|
3
|
+
export class NodeProfileError extends Error {
|
|
4
|
+
resource;
|
|
5
|
+
code = "ERR_VNODE_PROFILE";
|
|
6
|
+
constructor(resource) {
|
|
7
|
+
super("Restricted node profile: " + resource);
|
|
8
|
+
this.resource = resource;
|
|
9
|
+
this.name = "NodeProfileError";
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
export class NodeUsageError extends Error {
|
|
13
|
+
code = "ERR_VNODE_UNSUPPORTED";
|
|
14
|
+
constructor(message) { super(message); this.name = "NodeUsageError"; }
|
|
15
|
+
}
|
|
16
|
+
//# sourceMappingURL=types.js.map
|