@poe-platform/safe-bash 0.1.800 → 0.1.801
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/README.md +16 -5
- package/dist/image-ast/index.browser.js +119 -75
- package/dist/image-ast/index.js +119 -75
- package/dist/pdf-ast/index.js +4 -3
- package/dist/safe-bash/chunks/{chunk-LUOFIVNI.js → chunk-3NDIFSNM.js} +3 -3
- package/dist/safe-bash/chunks/{chunk-4SEW2Q6H.js → chunk-3R3AANOR.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-HHW7MGS2.js → chunk-45PK3NWI.js} +4 -4
- package/dist/safe-bash/chunks/{chunk-KHMGTPD6.js → chunk-46Z5E5EV.js} +2 -2
- package/dist/safe-bash/chunks/{chunk-XB3B7KMM.js → chunk-6O77NL2S.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-T3JTVIEP.js → chunk-6PAVEFT3.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-PYVEAFJM.js → chunk-74GHTNJA.js} +3 -2
- package/dist/safe-bash/chunks/{chunk-LQHGH25W.js → chunk-7R5BDCG7.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-RMWLWH7Q.js → chunk-7VNF5BFF.js} +300 -737
- package/dist/safe-bash/chunks/{chunk-QVSRRNZT.js → chunk-A7XEHALN.js} +4 -4
- package/dist/safe-bash/chunks/{chunk-MHZ24KEI.js → chunk-AM5ESLPH.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-3L3T6LYV.js → chunk-AUSNDQTJ.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-YG5WAHK7.js → chunk-B7TAL7S5.js} +1 -3
- package/dist/safe-bash/chunks/{chunk-K7IQZE7D.js → chunk-C5OWC2TL.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-F3RV2F72.js → chunk-CHYGPFVM.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-M4CFCXHN.js → chunk-CS4MNM6I.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-H6JW3E4F.js → chunk-CTVWDACF.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-BHJE5LPZ.js → chunk-D3ANYGMC.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-NLAW7KDI.js → chunk-E7OYNDGL.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-SOZK5JVX.js → chunk-FBUCWVTE.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-RKKRJ54E.js → chunk-FNDNHAGE.js} +30 -23
- package/dist/safe-bash/chunks/{chunk-KCVSVD65.js → chunk-I5HZ4FGE.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-JJSTTIEZ.js → chunk-ICFDYV64.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-TYD7EVUJ.js → chunk-IVRQ4BXL.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-KV7PKOHV.js → chunk-IWDICZVK.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-I4OAEOP6.js → chunk-J42RIHHJ.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-K2VCOJ2B.js → chunk-K6VCD7IY.js} +7 -12
- package/dist/safe-bash/chunks/{chunk-63FXVDGF.js → chunk-LVOBFF4D.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-U5NUZPCC.js → chunk-MHMMRCYC.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-6HZYFL3H.js → chunk-NR3EM4LS.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-VYZTG3GV.js → chunk-NZQXYWA3.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-TFGRKY43.js → chunk-OQRVVGR6.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-PPYM75Z3.js → chunk-OV6IHKO6.js} +2 -2
- package/dist/safe-bash/chunks/{chunk-KW24TAIU.js → chunk-PQRAK7HU.js} +920 -432
- package/dist/safe-bash/chunks/{chunk-K4YMYFRJ.js → chunk-SZH7EJLD.js} +116 -697
- package/dist/safe-bash/chunks/{chunk-7YSRXFEG.js → chunk-TFIBK2GI.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-I7L3G3NX.js → chunk-UE5KZDEK.js} +2 -2
- package/dist/safe-bash/chunks/{chunk-QU3BVQ53.js → chunk-UTBUUFDM.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-JTLSUJ7V.js → chunk-VQDD3G76.js} +42 -25
- package/dist/safe-bash/chunks/{chunk-46UISJCK.js → chunk-VTH3MLDU.js} +1 -1
- package/dist/safe-bash/chunks/{chunk-LLZCZ24K.js → chunk-XVOSKJE2.js} +1 -1
- package/dist/safe-bash/chunks/{csvkit-QGP3GAOB.js → csvkit-TACDU7FC.js} +3 -3
- package/dist/safe-bash/chunks/{ffmpeg-JTVH26MK.js → ffmpeg-WTC3TEFI.js} +2 -2
- package/dist/safe-bash/chunks/{gh-I7QX7N5C.js → gh-6WU6PXL4.js} +2 -2
- package/dist/safe-bash/chunks/{git-MA7NKYVP.js → git-EFZIGJW4.js} +2 -2
- package/dist/safe-bash/chunks/{imagemagick-Y4NPWX2Q.js → imagemagick-EIEYGWPF.js} +2 -2
- package/dist/safe-bash/chunks/{implementation-BWDKOVQJ.js → implementation-MLFHUQ5M.js} +2 -2
- package/dist/safe-bash/chunks/{mmdc-44PELHDG.js → mmdc-ROQJT5HQ.js} +2 -2
- package/dist/safe-bash/chunks/{pdfimages-635TRW4Q.js → pdfimages-DW7LWXFI.js} +2 -2
- package/dist/safe-bash/chunks/{pdfinfo-FSDAA2KY.js → pdfinfo-TIP6XLUQ.js} +2 -2
- package/dist/safe-bash/chunks/{pdftk-GQ5UH3VG.js → pdftk-DMG22ITZ.js} +2 -2
- package/dist/safe-bash/chunks/{pdftoppm-YTXQCAYT.js → pdftoppm-WNDYR72T.js} +2 -2
- package/dist/safe-bash/chunks/{pdftotext-CVA2G7FY.js → pdftotext-5IPZ4NI7.js} +2 -2
- package/dist/safe-bash/chunks/{qpdf-HZMIFG4A.js → qpdf-TTX2DIUA.js} +2 -2
- package/dist/safe-bash/chunks/{sips-E7UBDP33.js → sips-XYS46JPJ.js} +2 -2
- package/dist/safe-bash/chunks/{soffice-ELASUWUK.js → soffice-TU73E5KL.js} +2 -2
- package/dist/safe-bash/chunks/{wkhtmltopdf-EPO6YCMG.js → wkhtmltopdf-FSZ2CHGE.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-QBGA56UH.js → chunk-2ELYGJDD.js} +7 -7
- package/dist/safe-bash/command-chunks/{chunk-52PCQXD2.js → chunk-2NHI5F5S.js} +2 -1
- package/dist/safe-bash/command-chunks/{chunk-HDKVO47G.js → chunk-2SQEIUGJ.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-5LSGEIZY.js → chunk-3HHCU5YU.js} +4 -3
- package/dist/safe-bash/command-chunks/{chunk-TF6OA2GK.js → chunk-3NV3HYT2.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-2QHG43WJ.js → chunk-4BB2SWJ5.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-IEXHHNOF.js → chunk-4J5CZ2DP.js} +2 -7
- package/dist/safe-bash/command-chunks/{chunk-WDHI3S6Y.js → chunk-4OOUQTQO.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-YMONDXET.js → chunk-4ZQWGOZB.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-L6DVEBW3.js → chunk-5BSTFCXG.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-Q3DII3Q7.js → chunk-5PWJG2UK.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-JMPP4TCW.js → chunk-5UBXNSFZ.js} +3 -2
- package/dist/safe-bash/command-chunks/{chunk-3NG75MOB.js → chunk-67GQA75T.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-L6SU4S26.js → chunk-6B7WQIKB.js} +0 -7
- package/dist/safe-bash/command-chunks/{chunk-V6MSPQLA.js → chunk-6BNTBWIK.js} +4 -39
- package/dist/safe-bash/command-chunks/{chunk-JN7WIP6S.js → chunk-6KJ3LPI2.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-HLDTOR7M.js → chunk-6ZVI7LUY.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-X6NJC3IC.js → chunk-75OFBY5R.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-MRW5HD2D.js → chunk-7O3E4LPT.js} +4 -22
- package/dist/safe-bash/command-chunks/{chunk-TEVJJPTC.js → chunk-7U7EXOXX.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-6CYTRQ24.js → chunk-7VTKQUA5.js} +20 -17
- package/dist/safe-bash/command-chunks/{chunk-BZPAWTUL.js → chunk-AEF5BA3D.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-63R3FEZJ.js → chunk-AIV5BF5W.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-AYUTO323.js → chunk-AKJG2XD3.js} +2 -18
- package/dist/safe-bash/command-chunks/{chunk-J34TZVMW.js → chunk-ALDC4XP4.js} +0 -5
- package/dist/safe-bash/command-chunks/{chunk-CKXV2CLD.js → chunk-ARBYOQUZ.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-44AHAB5O.js → chunk-BDSMROQZ.js} +1 -4
- package/dist/safe-bash/command-chunks/{chunk-53P53XFM.js → chunk-BPE5INLI.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-OT4LZMLB.js → chunk-BR73BIOW.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-WB5SVIG7.js → chunk-C5YYCQHW.js} +498 -88
- package/dist/safe-bash/command-chunks/{chunk-EUSPTFAX.js → chunk-CAP7ZJSY.js} +7 -7
- package/dist/safe-bash/command-chunks/{chunk-DWFLVJC6.js → chunk-CCRHMAU5.js} +2 -1
- package/dist/safe-bash/command-chunks/{chunk-GI4CJED2.js → chunk-CQTRW45K.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-N2F74VRO.js → chunk-CZ7EN3JG.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-KKG4BAFZ.js → chunk-DIEPXUM4.js} +6 -0
- package/dist/safe-bash/command-chunks/{chunk-QJAFJP2G.js → chunk-DZCY63VJ.js} +12 -10
- package/dist/safe-bash/command-chunks/{chunk-QUENU6GM.js → chunk-E55UKBIE.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-HLGKIZ25.js → chunk-F6OYH562.js} +2 -0
- package/dist/safe-bash/command-chunks/{chunk-MC3VWLIZ.js → chunk-FDBUV4HJ.js} +28 -19
- package/dist/safe-bash/command-chunks/{chunk-7FKUC34S.js → chunk-FPVUD6TH.js} +6 -3
- package/dist/safe-bash/command-chunks/{chunk-E2LB7FRT.js → chunk-FXOA7RBK.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-QWIDNAAK.js → chunk-FZTK4MFI.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-K543PB3I.js → chunk-G66QUHIZ.js} +6 -35
- package/dist/safe-bash/command-chunks/{chunk-YJDV76GL.js → chunk-GFQZCKO6.js} +29 -19
- package/dist/safe-bash/command-chunks/{chunk-FKKB5X5V.js → chunk-GOB777HR.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-IYPAQ7PH.js → chunk-GRBWW4SG.js} +6 -0
- package/dist/safe-bash/command-chunks/{chunk-PPNBNFAU.js → chunk-GYQ2HAKQ.js} +8 -8
- package/dist/safe-bash/command-chunks/{chunk-PJJUYO3R.js → chunk-II77KPZN.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-VL67NWNS.js → chunk-JDYXY44P.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-4QJOYXVB.js → chunk-JV7LBUTP.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-IKS2YXZQ.js → chunk-K67MWWWH.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-BKCNF5U3.js → chunk-KQLD3AED.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-UMDIOL3O.js → chunk-KXU3IRUO.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-QZF3SINC.js → chunk-LAOM65EE.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-HFII3QYO.js → chunk-LWS62ISU.js} +46 -32
- package/dist/safe-bash/command-chunks/{chunk-BZDDAPSV.js → chunk-LWSBAWLT.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-U6G67N23.js → chunk-MIXBO6U7.js} +18 -5
- package/dist/safe-bash/command-chunks/{chunk-JQ74HC37.js → chunk-MQFIPHIQ.js} +23 -50
- package/dist/safe-bash/command-chunks/{chunk-ZJBR5Q5I.js → chunk-MSFXC3OC.js} +4 -4
- package/dist/safe-bash/command-chunks/{chunk-NI7MKJPN.js → chunk-MTQH74CF.js} +3 -55
- package/dist/safe-bash/command-chunks/chunk-MWUZZWXK.js +354 -0
- package/dist/safe-bash/command-chunks/{chunk-RVLO4DYT.js → chunk-N4PFUSRM.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-D4OP2BR3.js → chunk-NKFYQSES.js} +1 -2
- package/dist/safe-bash/command-chunks/{chunk-NGWB2YBL.js → chunk-O4JQSB7O.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-7L24L4UO.js → chunk-OQU6UT6X.js} +2 -20
- package/dist/safe-bash/command-chunks/{chunk-TYCGMRLM.js → chunk-OYYV7ZAF.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-SVULUDOP.js → chunk-P2N33UMN.js} +20 -81
- package/dist/safe-bash/command-chunks/{chunk-Q7Q5GM5S.js → chunk-P5APDEFB.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-SAMH7SQE.js → chunk-PCEFOYA3.js} +237 -145
- package/dist/safe-bash/command-chunks/{chunk-3HXDA5PT.js → chunk-PMBFZXTK.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-4Y3WVMK4.js → chunk-PV66YWHB.js} +1 -0
- package/dist/safe-bash/command-chunks/{chunk-AXK3H4PX.js → chunk-QJ33BHI4.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-3LSOYLNV.js → chunk-QKFSRZGQ.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-JZSNU2MY.js → chunk-QKJLP53H.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-LC2MFKT4.js → chunk-RMWQAAO5.js} +24 -25
- package/dist/safe-bash/command-chunks/{chunk-QDTBMSBE.js → chunk-RO62EWX6.js} +2 -2
- package/dist/safe-bash/command-chunks/{chunk-4C6QI5BQ.js → chunk-RZZI24ZE.js} +4 -4
- package/dist/safe-bash/command-chunks/{chunk-PFAADCB5.js → chunk-SDNBCQ3X.js} +10 -24
- package/dist/safe-bash/command-chunks/{chunk-36O5OT7E.js → chunk-T35Y7YQD.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-6HMX4CQS.js → chunk-TGSNCQSR.js} +44 -16
- package/dist/safe-bash/command-chunks/{chunk-5T7CRJHW.js → chunk-TIOCQVUQ.js} +4 -7
- package/dist/safe-bash/command-chunks/{chunk-T5H5UJQ3.js → chunk-TNOA7FCQ.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-GN2TKLE7.js → chunk-TS65BJHG.js} +5 -5
- package/dist/safe-bash/command-chunks/{chunk-7RGB363W.js → chunk-TSCGT46G.js} +3 -2
- package/dist/safe-bash/command-chunks/{chunk-KBEURXFF.js → chunk-UN6WS55J.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-SX2X3IH4.js → chunk-V2V5OCL3.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-ERYJLO6G.js → chunk-V7A7DRTU.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-5SHGJ7NO.js → chunk-VA5ZHYYA.js} +73 -33
- package/dist/safe-bash/command-chunks/{chunk-XETLEHZP.js → chunk-VPR5LQYX.js} +3 -2
- package/dist/safe-bash/command-chunks/{chunk-3DT2YOGW.js → chunk-VSRGNQCP.js} +3 -3
- package/dist/safe-bash/command-chunks/{chunk-J5SN3PZ3.js → chunk-VXSLJH7G.js} +53 -3
- package/dist/safe-bash/command-chunks/{chunk-PXYOWWMV.js → chunk-W7RAD4EW.js} +4 -3
- package/dist/safe-bash/command-chunks/{chunk-YGC6OS5O.js → chunk-WECIOOQB.js} +5 -8
- package/dist/safe-bash/command-chunks/{chunk-HHP343KT.js → chunk-WTECBRU4.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-AO6Z5EQ7.js → chunk-WVE64WM2.js} +6 -5
- package/dist/safe-bash/command-chunks/{chunk-Z7RVSD5K.js → chunk-WVHONVZ4.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-QNIMV57G.js → chunk-XNLFHHOC.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-XAFSZDY2.js → chunk-XS72HTMA.js} +11 -0
- package/dist/safe-bash/command-chunks/{chunk-KYSPGS33.js → chunk-YIQACGEW.js} +2 -0
- package/dist/safe-bash/command-chunks/{chunk-NAY27PXB.js → chunk-YOFC45RK.js} +1 -1
- package/dist/safe-bash/command-chunks/{chunk-QI7LGHJJ.js → chunk-Z45N42QC.js} +21 -6
- package/dist/safe-bash/command-chunks/{chunk-67IQF5GC.js → chunk-ZYHTWNAE.js} +23 -9
- package/dist/safe-bash/command-chunks/{chunk-STC3LEWJ.js → chunk-ZYXH3B66.js} +5 -3
- package/dist/safe-bash/commands/bytes/compression/index.js +3 -2
- package/dist/safe-bash/commands/copy-preserve.d.ts +1 -0
- package/dist/safe-bash/commands/csplit/index.browser.js +2 -2
- package/dist/safe-bash/commands/docx/index.browser.js +1 -1
- package/dist/safe-bash/commands/execution.js +19 -13
- package/dist/safe-bash/commands/factor/index.browser.js +2 -2
- package/dist/safe-bash/commands/filesystem.d.ts +1 -1
- package/dist/safe-bash/commands/filesystem.js +17 -13
- package/dist/safe-bash/commands/getopt/index.browser.js +2 -2
- package/dist/safe-bash/commands/hexdump/index.browser.js +2 -2
- package/dist/safe-bash/commands/htmlq/index.d.ts +1 -1
- package/dist/safe-bash/commands/iconv/index.browser.js +2 -2
- package/dist/safe-bash/commands/line-endings/index.browser.js +2 -2
- package/dist/safe-bash/commands/llm/index.browser.js +2 -2
- package/dist/safe-bash/commands/llm/providers/index.browser.js +1 -1
- package/dist/safe-bash/commands/mdq/index.browser.js +3 -3
- package/dist/safe-bash/commands/media/index.browser.js +1 -1
- package/dist/safe-bash/commands/network/curl.d.ts +1 -1
- package/dist/safe-bash/commands/network/curl.js +1 -3
- package/dist/safe-bash/commands/network/index.browser.js +4 -4
- package/dist/safe-bash/commands/network/platform-portable.d.ts +1 -5
- package/dist/safe-bash/commands/network/platform-portable.js +1 -26
- package/dist/safe-bash/commands/network/public.d.ts +2 -2
- package/dist/safe-bash/commands/network/public.js +2 -2
- package/dist/safe-bash/commands/network/transport.js +2 -2
- package/dist/safe-bash/commands/network/wget.d.ts +1 -1
- package/dist/safe-bash/commands/network/wget.js +1 -3
- package/dist/safe-bash/commands/node/filesystem.js +3 -2
- package/dist/safe-bash/commands/node/index.browser.js +8 -8
- package/dist/safe-bash/commands/node/types.js +1 -1
- package/dist/safe-bash/commands/op/index.browser.js +3 -3
- package/dist/safe-bash/commands/pr/index.browser.js +2 -2
- package/dist/safe-bash/commands/python/host-capabilities.js +31 -14
- package/dist/safe-bash/commands/python/index.browser.js +11 -11
- package/dist/safe-bash/commands/python/manifest.d.ts +1 -0
- package/dist/safe-bash/commands/python/manifest.js +6 -3
- package/dist/safe-bash/commands/python/shell-capability.d.ts +1 -0
- package/dist/safe-bash/commands/python/shell-capability.js +3 -2
- package/dist/safe-bash/commands/python/worker.browser.js +3 -3
- package/dist/safe-bash/commands/regex-execution/public.browser.js +4 -4
- package/dist/safe-bash/commands/safejs/runtime.js +16 -7
- package/dist/safe-bash/commands/standard.d.ts +1 -0
- package/dist/safe-bash/commands/standard.js +2 -1
- package/dist/safe-bash/commands/streams.js +6 -24
- package/dist/safe-bash/commands/text.js +268 -364
- package/dist/safe-bash/commands/tsort/index.browser.js +2 -2
- package/dist/safe-bash/commands/xml/index.browser.js +2 -2
- package/dist/safe-bash/commands/yq/index.browser.js +2 -2
- package/dist/safe-bash/core.browser.js +1 -1
- package/dist/safe-bash/core.d.ts +6 -1
- package/dist/safe-bash/core.js +1 -1
- package/dist/safe-bash/full-core.browser.js +108 -104
- package/dist/safe-bash/jobs.browser.js +5 -5
- package/dist/safe-bash/opt-in/commands/dd/index.js +2 -0
- package/dist/safe-bash/opt-in/optional/commands/shuf/options.d.ts +1 -0
- package/dist/safe-bash/opt-in/optional/commands/shuf/options.js +2 -4
- package/dist/safe-bash/opt-in/optional/commands/shuf/shuf.js +2 -1
- package/dist/safe-bash/optional-host.browser.js +11 -11
- package/dist/safe-bash/plugins/composition.d.ts +1 -0
- package/dist/safe-bash/plugins/composition.js +3 -8
- package/dist/safe-bash/plugins/index.browser.js +27 -27
- package/dist/safe-bash/registry-entry.browser.js +28 -28
- package/dist/safe-bash/shell/arrays/bindings.js +1 -1
- package/dist/safe-bash/shell/arrays/state.js +4 -0
- package/dist/safe-bash/shell/brace-expansion.js +1 -1
- package/dist/safe-bash/shell/dynamic-variables.d.ts +10 -0
- package/dist/safe-bash/shell/dynamic-variables.js +25 -0
- package/dist/safe-bash/shell/parser.js +8 -1
- package/dist/safe-bash/shell/runtime.d.ts +4 -4
- package/dist/safe-bash/shell/runtime.js +291 -741
- package/dist/safe-bash/shell/shell.js +2 -31
- package/dist/safe-bash/shell-entry.browser.js +25 -25
- package/dist/safe-bash/trap.browser.js +4 -4
- package/dist/safe-bash/yq-browser/index.js +1 -1
- package/dist/safe-bash-base-encoding-engine/base.js +2 -2
- package/dist/safe-bash-base-encoding-engine/shared.js +1 -1
- package/dist/safe-bash-byte-input-engine/index.d.ts +3 -2
- package/dist/safe-bash-byte-input-engine/index.js +4 -1
- package/dist/safe-bash-checksum-engine/index.js +13 -6
- package/dist/safe-bash-command-apply-patch/apply.d.ts +1 -1
- package/dist/safe-bash-command-apply-patch/apply.js +4 -3
- package/dist/safe-bash-command-apply-patch/index.js +3 -3
- package/dist/safe-bash-command-apply-patch/matcher.js +1 -1
- package/dist/safe-bash-command-apply-patch/parser.js +1 -1
- package/dist/safe-bash-command-awk/awk-inspection.js +2 -2
- package/dist/safe-bash-command-awk/awk-runtime.js +3 -3
- package/dist/safe-bash-command-awk/awk-syntax.d.ts +1 -1
- package/dist/safe-bash-command-awk/awk-syntax.js +2 -2
- package/dist/safe-bash-command-awk/awk-values.js +1 -1
- package/dist/safe-bash-command-awk/awk.js +5 -5
- package/dist/safe-bash-command-awk/index.js +5 -5
- package/dist/safe-bash-command-bc/index.d.ts +2 -0
- package/dist/safe-bash-command-bc/index.js +123 -92
- package/dist/safe-bash-command-column/column.js +5 -5
- package/dist/safe-bash-command-column/display.d.ts +1 -1
- package/dist/safe-bash-command-column/display.js +1 -1
- package/dist/safe-bash-command-column/index.js +5 -5
- package/dist/safe-bash-command-column/internal.d.ts +0 -2
- package/dist/safe-bash-command-column/internal.js +1 -1
- package/dist/safe-bash-command-column/layout.js +4 -4
- package/dist/safe-bash-command-column/table.js +2 -2
- package/dist/safe-bash-command-comm/comm.js +1 -1
- package/dist/safe-bash-command-comm/index.js +1 -1
- package/dist/safe-bash-command-csvcut/index.d.ts +1 -0
- package/dist/safe-bash-command-csvcut/index.js +1 -0
- package/dist/safe-bash-command-csvgrep/index.d.ts +1 -0
- package/dist/safe-bash-command-csvgrep/index.js +2 -2
- package/dist/safe-bash-command-csvkit/index.js +9 -9
- package/dist/safe-bash-command-csvkit/sync-support.js +1 -1
- package/dist/safe-bash-command-curl/curl.js +1 -1
- package/dist/safe-bash-command-curl/index.js +1 -1
- package/dist/safe-bash-command-dd/index.js +2 -0
- package/dist/safe-bash-command-diff/diff.js +1 -1
- package/dist/safe-bash-command-diff/index.js +1 -1
- package/dist/safe-bash-command-exiftool/index.d.ts +1 -0
- package/dist/safe-bash-command-fd/index.js +9 -9
- package/dist/safe-bash-command-ffmpeg/index.js +31 -8
- package/dist/safe-bash-command-file/index.js +1 -1
- package/dist/safe-bash-command-file/shared.js +1 -1
- package/dist/safe-bash-command-find/find.js +1 -1
- package/dist/safe-bash-command-find/index.js +1 -1
- package/dist/safe-bash-command-gzip/index.js +3 -2
- package/dist/safe-bash-command-hexdump/command.js +4 -4
- package/dist/safe-bash-command-hexdump/custom.d.ts +24 -0
- package/dist/safe-bash-command-hexdump/index.js +4 -4
- package/dist/safe-bash-command-hexdump/internal.d.ts +2 -0
- package/dist/safe-bash-command-hexdump/internal.js +1 -1
- package/dist/safe-bash-command-hexdump/io.js +2 -2
- package/dist/safe-bash-command-hexdump/options.d.ts +3 -0
- package/dist/safe-bash-command-hexdump/options.js +2 -2
- package/dist/safe-bash-command-hostname/index.js +1 -1
- package/dist/safe-bash-command-html-to-markdown/budget.js +1 -1
- package/dist/safe-bash-command-html-to-markdown/entities.js +3 -3
- package/dist/safe-bash-command-html-to-markdown/index.js +6 -6
- package/dist/safe-bash-command-html-to-markdown/input.js +5 -5
- package/dist/safe-bash-command-html-to-markdown/parser.d.ts +1 -0
- package/dist/safe-bash-command-html-to-markdown/parser.js +4 -4
- package/dist/safe-bash-command-html-to-markdown/render.js +5 -5
- package/dist/safe-bash-command-html-to-markdown/text.js +2 -2
- package/dist/safe-bash-command-htmlq/index.d.ts +1 -0
- package/dist/safe-bash-command-htmlq/index.js +27 -9
- package/dist/safe-bash-command-iconv/codec.js +1 -1
- package/dist/safe-bash-command-iconv/command.js +2 -2
- package/dist/safe-bash-command-iconv/index.js +2 -2
- package/dist/safe-bash-command-imagemagick/index.js +24 -6
- package/dist/safe-bash-command-join/index.js +1 -1
- package/dist/safe-bash-command-join/join.js +1 -1
- package/dist/safe-bash-command-jq/index.js +1 -1
- package/dist/safe-bash-command-jq/jq.js +1 -1
- package/dist/safe-bash-command-less/index.js +43 -28
- package/dist/safe-bash-command-mmdc/index.d.ts +1 -0
- package/dist/safe-bash-command-numfmt/index.js +0 -11
- package/dist/safe-bash-command-od/index.js +101 -68
- package/dist/safe-bash-command-pandoc/command.js +1 -1
- package/dist/safe-bash-command-pandoc/index.js +1 -1
- package/dist/safe-bash-command-paste/index.js +1 -1
- package/dist/safe-bash-command-paste/paste.js +1 -1
- package/dist/safe-bash-command-pathchk/index.js +3 -13
- package/dist/safe-bash-command-pdfimages/index.js +27 -11
- package/dist/safe-bash-command-pdfinfo/index.js +19 -10
- package/dist/safe-bash-command-pdftk/index.js +3 -3
- package/dist/safe-bash-command-pdftoppm/index.js +26 -10
- package/dist/safe-bash-command-pdftotext/index.js +27 -13
- package/dist/safe-bash-command-qpdf/index.js +5 -5
- package/dist/safe-bash-command-sed/index.js +1 -1
- package/dist/safe-bash-command-sed/sed.js +1 -1
- package/dist/safe-bash-command-shuf/options.d.ts +1 -0
- package/dist/safe-bash-command-shuf/options.js +2 -4
- package/dist/safe-bash-command-shuf/shuf.js +2 -1
- package/dist/safe-bash-command-soffice/index.js +20 -16
- package/dist/safe-bash-command-split/index.js +3 -3
- package/dist/safe-bash-command-split/io.js +1 -1
- package/dist/safe-bash-command-split/outputs.js +2 -2
- package/dist/safe-bash-command-split/split.js +3 -3
- package/dist/safe-bash-command-sqlite3/btree.d.ts +1 -0
- package/dist/safe-bash-command-sqlite3/engine.d.ts +6 -0
- package/dist/safe-bash-command-sqlite3/index.js +284 -85
- package/dist/safe-bash-command-ssconvert/commands.js +9 -9
- package/dist/safe-bash-command-ssconvert/core.js +8 -8
- package/dist/safe-bash-command-ssconvert/formats/csv.js +9 -9
- package/dist/safe-bash-command-ssconvert/formats/ods.js +8 -8
- package/dist/safe-bash-command-ssconvert/formats/spreadsheetml.js +2 -2
- package/dist/safe-bash-command-ssconvert/formats/xls.js +9 -9
- package/dist/safe-bash-command-ssconvert/formats/xlsx.js +8 -8
- package/dist/safe-bash-command-ssconvert/index.js +20 -20
- package/dist/safe-bash-command-tar/extract.js +1 -1
- package/dist/safe-bash-command-tar/index.js +5 -4
- package/dist/safe-bash-command-tar/modes.js +2 -2
- package/dist/safe-bash-command-tree/arguments.js +3 -3
- package/dist/safe-bash-command-tree/charset.js +1 -1
- package/dist/safe-bash-command-tree/index.js +4 -4
- package/dist/safe-bash-command-tree/io.js +1 -1
- package/dist/safe-bash-command-tree/pattern.js +2 -2
- package/dist/safe-bash-command-tree/tree.js +4 -4
- package/dist/safe-bash-command-unrtf/index.js +14 -7
- package/dist/safe-bash-command-unzip/index.js +1 -1
- package/dist/safe-bash-command-unzip/unzip.js +1 -1
- package/dist/safe-bash-command-wget/index.js +1 -1
- package/dist/safe-bash-command-wget/wget.js +1 -1
- package/dist/safe-bash-command-xan/argv.d.ts +1 -1
- package/dist/safe-bash-command-xan/argv.js +1 -1
- package/dist/safe-bash-command-xan/commands.js +5 -3
- package/dist/safe-bash-command-xan/csv.d.ts +1 -1
- package/dist/safe-bash-command-xan/csv.js +1 -1
- package/dist/safe-bash-command-xan/index.js +7 -7
- package/dist/safe-bash-command-xan/io.js +3 -3
- package/dist/safe-bash-command-xmllint/index.js +1 -1
- package/dist/safe-bash-command-xxd/index.js +105 -91
- package/dist/safe-bash-command-xz/command.d.ts +2 -0
- package/dist/safe-bash-command-xz/index.d.ts +1 -1
- package/dist/safe-bash-command-xz/index.js +8 -0
- package/dist/safe-bash-command-yq/query.js +1 -1
- package/dist/safe-bash-command-zip/index.js +1 -1
- package/dist/safe-bash-command-zip/zip.js +1 -1
- package/dist/safe-bash-contracts/escaping.js +3 -3
- package/dist/safe-bash-contracts/filesystem-output.js +2 -2
- package/dist/safe-bash-contracts/index.d.ts +1 -0
- package/dist/safe-bash-contracts/index.js +7 -3
- package/dist/safe-bash-contracts/io.d.ts +4 -1
- package/dist/safe-bash-contracts/io.js +3 -1
- package/dist/safe-bash-contracts/managed-abort.d.ts +10 -0
- package/dist/safe-bash-contracts/output.js +2 -2
- package/dist/safe-bash-diff-engine/index.js +1 -1
- package/dist/safe-bash-diff-engine/shared.d.ts +3 -2
- package/dist/safe-bash-diff-engine/shared.js +1 -1
- package/dist/safe-bash-io-engine/commands/archive/internal.js +5 -23
- package/dist/safe-bash-io-engine/commands/search/requirements.js +2 -2
- package/dist/safe-bash-io-engine/commands/text-programs/shared.js +33 -44
- package/dist/safe-bash-io-engine/internal.js +1 -1
- package/dist/safe-bash-io-engine/shell/pattern.js +1 -1
- package/dist/safe-bash-io-engine/shell/string-operations.js +1 -1
- package/dist/safe-bash-mcp/index.browser.d.ts +155 -35
- package/dist/safe-bash-mcp/index.browser.js +416 -0
- package/dist/safe-bash-mcp/index.d.ts +54 -2
- package/dist/safe-bash-mcp/index.js +283 -89
- package/dist/safe-bash-network-engine/aggregate.js +2 -2
- package/dist/safe-bash-network-engine/args.js +4 -4
- package/dist/safe-bash-network-engine/authorizer.js +1 -1
- package/dist/safe-bash-network-engine/body.js +6 -6
- package/dist/safe-bash-network-engine/decode.d.ts +1 -1
- package/dist/safe-bash-network-engine/decode.js +3 -4
- package/dist/safe-bash-network-engine/fetch-transport.js +3 -3
- package/dist/safe-bash-network-engine/form-content-type.js +2 -2
- package/dist/safe-bash-network-engine/form-headers.js +2 -2
- package/dist/safe-bash-network-engine/glob.js +1 -1
- package/dist/safe-bash-network-engine/index.js +4 -4
- package/dist/safe-bash-network-engine/input.js +6 -6
- package/dist/safe-bash-network-engine/output.js +2 -2
- package/dist/safe-bash-network-engine/platform-portable.js +3 -3
- package/dist/safe-bash-network-engine/shared.js +2 -2
- package/dist/safe-bash-network-engine/types.d.ts +7 -2
- package/dist/safe-bash-network-engine/types.js +1 -1
- package/dist/safe-bash-network-engine/url.js +2 -2
- package/dist/safe-bash-query-engine/capture.js +3 -3
- package/dist/safe-bash-query-engine/delpaths.js +3 -3
- package/dist/safe-bash-query-engine/formats.js +2 -2
- package/dist/safe-bash-query-engine/index.js +11 -11
- package/dist/safe-bash-query-engine/indices.js +3 -3
- package/dist/safe-bash-query-engine/input.js +1 -1
- package/dist/safe-bash-query-engine/interpreter.js +9 -9
- package/dist/safe-bash-query-engine/parser.js +1 -1
- package/dist/safe-bash-query-engine/query-core.js +11 -11
- package/dist/safe-bash-query-engine/regex.js +4 -4
- package/dist/safe-bash-query-engine/splits.js +5 -5
- package/dist/safe-bash-query-engine/values.js +2 -2
- package/dist/safe-bash-regex-engine/ere/matcher.js +102 -30
- package/dist/safe-bash-regex-engine/execution/bounded-provider.js +55 -67
- package/dist/safe-bash-regex-engine/execution/portable.d.ts +0 -1
- package/dist/safe-bash-regex-engine/execution/portable.js +6 -10
- package/dist/safe-bash-regex-engine/execution/protocol.d.ts +0 -5
- package/dist/safe-bash-regex-engine/execution/protocol.js +1 -3
- package/dist/safe-bash-regex-engine/index.js +6 -4
- package/dist/safe-bash-regex-engine/text/budget.d.ts +1 -0
- package/dist/safe-bash-regex-engine/text/budget.js +1 -1
- package/dist/safe-bash-regex-engine/text/regex.d.ts +14 -0
- package/dist/safe-bash-regex-engine/text/regex.js +6 -4
- package/dist/safe-bash-regex-engine/text/replacement-buffer.js +2 -2
- package/dist/safe-bash-regex-engine/text/rust-syntax.js +2 -2
- package/dist/safe-bash-search-engine/grep.js +189 -227
- package/dist/safe-bash-table-text-engine/table-text/internal.d.ts +7 -5
- package/dist/safe-bash-table-text-engine/table-text/internal.js +39 -21
- package/dist/safe-playwright-cloudflare/browser-trace-budget.js +6 -2
- package/dist/spreadsheet-engine/codecs/odf-hyperlinks.js +8 -2
- package/dist/spreadsheet-engine/formulas/functions/captured-bessel-phase.js +2 -2
- package/dist/spreadsheet-engine/formulas/label-references.js +54 -33
- package/dist/spreadsheet-engine/formulas/parser.js +3 -1
- package/dist/spreadsheet-engine/formulas/rewriting.js +13 -3
- package/dist/spreadsheet-format-xls/biff-data-tables.js +4 -6
- package/dist/spreadsheet-format-xls/biff-formulas.js +3 -0
- package/dist/spreadsheet-format-xls/biff-label-ranges.js +9 -6
- package/dist/spreadsheet-format-xls/biff.js +1 -1
- package/dist/xlsx-ast/xlsx.js +8 -5
- package/package.json +9 -8
- package/dist/safe-bash/command-chunks/chunk-KAGBORIC.js +0 -88
- /package/dist/safe-bash/command-chunks/{chunk-BWNXWI33.js → chunk-2LMZVE3I.js} +0 -0
|
@@ -1,32 +1,32 @@
|
|
|
1
1
|
import {
|
|
2
2
|
gzip,
|
|
3
3
|
inflate
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-MHMMRCYC.js";
|
|
5
5
|
import {
|
|
6
6
|
compareCopyIdentity,
|
|
7
7
|
compareObservedEntries,
|
|
8
8
|
predicateRequirements,
|
|
9
9
|
pwdRequirements,
|
|
10
10
|
resolveInputLimit
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-XVOSKJE2.js";
|
|
12
12
|
import {
|
|
13
13
|
PublicDiagnostic,
|
|
14
14
|
escapeText,
|
|
15
15
|
quoteShellOperand,
|
|
16
16
|
writeDiagnostic
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-IVRQ4BXL.js";
|
|
18
18
|
import {
|
|
19
19
|
byteLength,
|
|
20
20
|
compareUtf8,
|
|
21
21
|
equalBytes
|
|
22
|
-
} from "./chunk-
|
|
22
|
+
} from "./chunk-D3ANYGMC.js";
|
|
23
23
|
import {
|
|
24
24
|
shellValueByteLength,
|
|
25
25
|
shellValueBytes
|
|
26
|
-
} from "./chunk-
|
|
26
|
+
} from "./chunk-J42RIHHJ.js";
|
|
27
27
|
import {
|
|
28
28
|
FsError
|
|
29
|
-
} from "./chunk-
|
|
29
|
+
} from "./chunk-VTH3MLDU.js";
|
|
30
30
|
import {
|
|
31
31
|
basename,
|
|
32
32
|
dirname,
|
|
@@ -37,15 +37,15 @@ import {
|
|
|
37
37
|
resolvePath,
|
|
38
38
|
validatePath,
|
|
39
39
|
yieldTurn
|
|
40
|
-
} from "./chunk-
|
|
40
|
+
} from "./chunk-NZQXYWA3.js";
|
|
41
41
|
import {
|
|
42
42
|
collectBytes,
|
|
43
43
|
readBytes,
|
|
44
44
|
writeBytes
|
|
45
|
-
} from "./chunk-
|
|
45
|
+
} from "./chunk-74GHTNJA.js";
|
|
46
46
|
import {
|
|
47
47
|
getCommandArguments
|
|
48
|
-
} from "./chunk-
|
|
48
|
+
} from "./chunk-7R5BDCG7.js";
|
|
49
49
|
import {
|
|
50
50
|
RESOLVED_EXIT_ZERO,
|
|
51
51
|
UsageError,
|
|
@@ -60,7 +60,6 @@ import {
|
|
|
60
60
|
escapeBytes,
|
|
61
61
|
input,
|
|
62
62
|
integer,
|
|
63
|
-
isDefaultCommandOptions,
|
|
64
63
|
lines,
|
|
65
64
|
options,
|
|
66
65
|
output,
|
|
@@ -70,39 +69,10 @@ import {
|
|
|
70
69
|
requireOperands,
|
|
71
70
|
syncCommandEvaluators,
|
|
72
71
|
value
|
|
73
|
-
} from "./chunk-
|
|
72
|
+
} from "./chunk-E7OYNDGL.js";
|
|
74
73
|
import {
|
|
75
74
|
init_platform
|
|
76
|
-
} from "./chunk-
|
|
77
|
-
|
|
78
|
-
// packages/safe-bash/src/commands/numfmt/index.ts
|
|
79
|
-
init_platform();
|
|
80
|
-
import {
|
|
81
|
-
createNumfmtCommand as createRawNumfmtCommand,
|
|
82
|
-
createNumfmtCommands as createRawNumfmtCommands
|
|
83
|
-
} from "../../safe-bash-command-numfmt/index.js";
|
|
84
|
-
import { numfmtCommand, settings } from "../../safe-bash-command-numfmt/index.js";
|
|
85
|
-
function createNumfmtCommand(options2 = {}) {
|
|
86
|
-
return registerDefaultExecutor(createRawNumfmtCommand(options2), options2);
|
|
87
|
-
}
|
|
88
|
-
function createNumfmtCommands(options2 = {}) {
|
|
89
|
-
return registerDefaultExecutors(createRawNumfmtCommands(options2), options2);
|
|
90
|
-
}
|
|
91
|
-
function numfmtCommands(options2 = {}) {
|
|
92
|
-
const commands = createNumfmtCommands(options2);
|
|
93
|
-
const replace = options2.replace ?? false;
|
|
94
|
-
return {
|
|
95
|
-
name: "numfmt-commands",
|
|
96
|
-
setup(host) {
|
|
97
|
-
if (!replace) {
|
|
98
|
-
for (const command5 of commands) {
|
|
99
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
103
|
-
}
|
|
104
|
-
};
|
|
105
|
-
}
|
|
75
|
+
} from "./chunk-B7TAL7S5.js";
|
|
106
76
|
|
|
107
77
|
// packages/safe-bash/src/commands/diff-patch/index.ts
|
|
108
78
|
init_platform();
|
|
@@ -120,10 +90,10 @@ function diffPatchCommands(options2 = {}) {
|
|
|
120
90
|
name: "diff-patch-commands",
|
|
121
91
|
setup(host) {
|
|
122
92
|
const definitions = createDiffPatchCommands(options2);
|
|
123
|
-
if (!options2.replace) for (const
|
|
124
|
-
if (host.commands.has(
|
|
93
|
+
if (!options2.replace) for (const command3 of definitions) {
|
|
94
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
125
95
|
}
|
|
126
|
-
for (const
|
|
96
|
+
for (const command3 of definitions) host.commands.register(command3, { replace: options2.replace ?? false });
|
|
127
97
|
}
|
|
128
98
|
};
|
|
129
99
|
}
|
|
@@ -143,7 +113,7 @@ init_platform();
|
|
|
143
113
|
import { gnuInformation, gnuInformationSync } from "../../safe-bash-io-engine/gnu-information.js";
|
|
144
114
|
|
|
145
115
|
// packages/safe-bash/src/commands/metadata/internal.ts
|
|
146
|
-
function
|
|
116
|
+
function settings(options2 = {}) {
|
|
147
117
|
const limits = { maxEntries: Infinity, maxDepth: Infinity, maxOutputBytes: Infinity, maxArgumentBytes: Infinity, maxAttempts: Infinity, maxArguments: Infinity, ...options2.limits };
|
|
148
118
|
for (const [key, value2] of Object.entries(limits)) {
|
|
149
119
|
if (value2 !== Infinity && (!Number.isSafeInteger(value2) || value2 < (key === "maxDepth" ? 0 : 1))) throw new RangeError(`Invalid metadata limit: ${key}`);
|
|
@@ -482,7 +452,7 @@ async function render(context, path, name, stat, format, escapes, limit, filesys
|
|
|
482
452
|
return concatBytes(chunks);
|
|
483
453
|
}
|
|
484
454
|
function createStatCommand(configuration = {}) {
|
|
485
|
-
const configured =
|
|
455
|
+
const configured = settings(configuration);
|
|
486
456
|
return metadataCommand("stat", async (context) => {
|
|
487
457
|
const budget = new MetadataBudget(context, configured.limits);
|
|
488
458
|
const parsed = parse(context.args);
|
|
@@ -783,7 +753,7 @@ function evalSyncMktemp(opArgs, env, statTypeSync, writeFileSync, mkdirSync) {
|
|
|
783
753
|
}
|
|
784
754
|
syncCommandEvaluators.evalSyncMktemp = evalSyncMktemp;
|
|
785
755
|
function createMktempCommand(configuration = {}) {
|
|
786
|
-
const configured =
|
|
756
|
+
const configured = settings(configuration);
|
|
787
757
|
const configuredUmask = configuration.umask === void 0 ? void 0 : configured.umask;
|
|
788
758
|
return metadataCommand("mktemp", async (context) => {
|
|
789
759
|
const budget = new MetadataBudget(context, configured.limits);
|
|
@@ -847,7 +817,7 @@ import { modeChange } from "../../safe-bash-io-engine/commands/mode-change.js";
|
|
|
847
817
|
import { modeChange as modeChange2 } from "../../safe-bash-io-engine/commands/mode-change.js";
|
|
848
818
|
import { bindConditionalMutation } from "@poe-platform/safe-fs/core";
|
|
849
819
|
function createChmodCommand(configuration = {}) {
|
|
850
|
-
const configured =
|
|
820
|
+
const configured = settings(configuration);
|
|
851
821
|
const configuredUmask = configuration.umask === void 0 ? void 0 : configured.umask;
|
|
852
822
|
return metadataCommand("chmod", async (context) => {
|
|
853
823
|
const budget = new MetadataBudget(context, configured.limits);
|
|
@@ -1035,16 +1005,16 @@ import { createTruncateCommand, createTruncateCommands, truncateCommand, truncat
|
|
|
1035
1005
|
// packages/safe-bash/src/commands/metadata/index.ts
|
|
1036
1006
|
import { evalSyncTruncate as evalSyncTruncate2 } from "../../safe-bash-command-truncate/index.js";
|
|
1037
1007
|
function createMetadataCommands(options2 = {}) {
|
|
1038
|
-
|
|
1008
|
+
settings(options2);
|
|
1039
1009
|
return registerDefaultExecutors([createChmodCommand(options2), createStatCommand(options2), createMktempCommand(options2), truncateCommand(options2)], options2);
|
|
1040
1010
|
}
|
|
1041
1011
|
function metadataCommands(options2 = {}) {
|
|
1042
1012
|
const commands = createMetadataCommands(options2);
|
|
1043
1013
|
return { name: "metadata-commands", setup(host) {
|
|
1044
1014
|
if (!options2.replace) {
|
|
1045
|
-
for (const
|
|
1015
|
+
for (const command3 of commands) if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1046
1016
|
}
|
|
1047
|
-
for (const
|
|
1017
|
+
for (const command3 of commands) host.commands.register(command3, { replace: options2.replace ?? false });
|
|
1048
1018
|
} };
|
|
1049
1019
|
}
|
|
1050
1020
|
|
|
@@ -1063,90 +1033,11 @@ function archiveCommands(options2 = {}) {
|
|
|
1063
1033
|
const commands = createArchiveCommands(options2);
|
|
1064
1034
|
return { name: "archive-commands", setup(host) {
|
|
1065
1035
|
if (!options2.replace) {
|
|
1066
|
-
for (const
|
|
1067
|
-
if (host.commands.has(
|
|
1036
|
+
for (const command3 of commands) {
|
|
1037
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1068
1038
|
}
|
|
1069
1039
|
}
|
|
1070
|
-
for (const
|
|
1071
|
-
} };
|
|
1072
|
-
}
|
|
1073
|
-
|
|
1074
|
-
// packages/safe-bash/src/commands/stream-inspection/index.ts
|
|
1075
|
-
init_platform();
|
|
1076
|
-
|
|
1077
|
-
// packages/safe-bash/src/commands/stream-inspection/tac.ts
|
|
1078
|
-
init_platform();
|
|
1079
|
-
import { createTacWithSettings } from "../../safe-bash-command-tac/tac.js";
|
|
1080
|
-
|
|
1081
|
-
// packages/safe-bash/src/commands/stream-inspection/expand.ts
|
|
1082
|
-
init_platform();
|
|
1083
|
-
import { createExpandWithSettings } from "../../safe-bash-command-expand/expand.js";
|
|
1084
|
-
|
|
1085
|
-
// packages/safe-bash/src/commands/stream-inspection/index.ts
|
|
1086
|
-
import { createFoldCommand } from "../../safe-bash-command-fold/family.js";
|
|
1087
|
-
|
|
1088
|
-
// packages/safe-bash/src/commands/stream-inspection/strings.ts
|
|
1089
|
-
init_platform();
|
|
1090
|
-
import { createStringsWithSettings } from "../../safe-bash-command-strings/strings.js";
|
|
1091
|
-
|
|
1092
|
-
// packages/safe-bash/src/commands/stream-inspection/shared.ts
|
|
1093
|
-
init_platform();
|
|
1094
|
-
import { ByteOutput, RecordBuffer, Session, command, settings as settings3 } from "../../safe-bash-text-stream-engine/stream-inspection/shared.js";
|
|
1095
|
-
|
|
1096
|
-
// packages/safe-bash/src/commands/stream-inspection/index.ts
|
|
1097
|
-
function createStreamInspectionCommands(options2 = {}) {
|
|
1098
|
-
const limits = settings3(options2);
|
|
1099
|
-
const defs = [createTacWithSettings(limits), createExpandWithSettings(limits), createFoldCommand(limits), createStringsWithSettings(limits)];
|
|
1100
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1101
|
-
return defs;
|
|
1102
|
-
}
|
|
1103
|
-
function streamInspectionCommands(options2 = {}) {
|
|
1104
|
-
const commands = createStreamInspectionCommands(options2);
|
|
1105
|
-
return { name: "stream-inspection-commands", setup(host) {
|
|
1106
|
-
if (!options2.replace) for (const definition of commands) {
|
|
1107
|
-
if (host.commands.has(definition.name)) throw new Error(`Command already registered: ${definition.name}`);
|
|
1108
|
-
}
|
|
1109
|
-
for (const definition of commands) host.commands.register(definition, { replace: options2.replace ?? false });
|
|
1110
|
-
} };
|
|
1111
|
-
}
|
|
1112
|
-
|
|
1113
|
-
// packages/safe-bash/src/commands/stream-format/index.ts
|
|
1114
|
-
init_platform();
|
|
1115
|
-
|
|
1116
|
-
// packages/safe-bash/src/commands/stream-format/seq.ts
|
|
1117
|
-
init_platform();
|
|
1118
|
-
import { createSeqWithSettings } from "../../safe-bash-command-seq/seq.js";
|
|
1119
|
-
|
|
1120
|
-
// packages/safe-bash/src/commands/stream-format/nl.ts
|
|
1121
|
-
init_platform();
|
|
1122
|
-
import { createNlWithSettings } from "../../safe-bash-command-nl/nl.js";
|
|
1123
|
-
|
|
1124
|
-
// packages/safe-bash/src/commands/stream-format/rev.ts
|
|
1125
|
-
init_platform();
|
|
1126
|
-
import { createRevWithSettings } from "../../safe-bash-command-rev/rev.js";
|
|
1127
|
-
|
|
1128
|
-
// packages/safe-bash/src/commands/stream-format/unexpand.ts
|
|
1129
|
-
init_platform();
|
|
1130
|
-
import { createUnexpandWithSettings } from "../../safe-bash-command-unexpand/unexpand.js";
|
|
1131
|
-
|
|
1132
|
-
// packages/safe-bash/src/commands/stream-format/shared.ts
|
|
1133
|
-
init_platform();
|
|
1134
|
-
import { ByteOutput as ByteOutput2, Session as Session2, command as command2, forEachRecord, records, settings as settings4 } from "../../safe-bash-text-stream-engine/stream-format/shared.js";
|
|
1135
|
-
|
|
1136
|
-
// packages/safe-bash/src/commands/stream-format/index.ts
|
|
1137
|
-
function createStreamFormatCommands(options2 = {}) {
|
|
1138
|
-
const limits = settings4(options2);
|
|
1139
|
-
const defs = [createSeqWithSettings(limits), createNlWithSettings(limits), createRevWithSettings(limits), createUnexpandWithSettings(limits)];
|
|
1140
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1141
|
-
return defs;
|
|
1142
|
-
}
|
|
1143
|
-
function streamFormatCommands(options2 = {}) {
|
|
1144
|
-
const commands = createStreamFormatCommands(options2);
|
|
1145
|
-
return { name: "stream-format-commands", setup(host) {
|
|
1146
|
-
if (!options2.replace) for (const definition of commands) {
|
|
1147
|
-
if (host.commands.has(definition.name)) throw new Error(`Command already registered: ${definition.name}`);
|
|
1148
|
-
}
|
|
1149
|
-
for (const definition of commands) host.commands.register(definition, { replace: options2.replace ?? false });
|
|
1040
|
+
for (const command3 of commands) host.commands.register(command3, { replace: options2.replace ?? false });
|
|
1150
1041
|
} };
|
|
1151
1042
|
}
|
|
1152
1043
|
|
|
@@ -1169,11 +1060,11 @@ import { createSleepWithSettings } from "../../safe-bash-command-sleep/sleep.js"
|
|
|
1169
1060
|
|
|
1170
1061
|
// packages/safe-bash/src/commands/time-env/shared.ts
|
|
1171
1062
|
init_platform();
|
|
1172
|
-
import { CommandFailure, checkSize, command
|
|
1063
|
+
import { CommandFailure, checkSize, command, defaultSleepScheduler, emit, ownEnvironment, settings as settings2, timeEnvExecutorSettings } from "../../safe-bash-calendar-engine/time-env/shared.js";
|
|
1173
1064
|
|
|
1174
1065
|
// packages/safe-bash/src/commands/time-env/index.ts
|
|
1175
1066
|
function createTimeEnvCommands(options2 = {}) {
|
|
1176
|
-
const configuration =
|
|
1067
|
+
const configuration = settings2(options2);
|
|
1177
1068
|
return registerDefaultExecutors([createDateWithSettings(configuration), createSleepWithSettings(configuration), createPrintenvWithSettings(configuration)], options2);
|
|
1178
1069
|
}
|
|
1179
1070
|
function timeEnvCommands(options2 = {}) {
|
|
@@ -1206,112 +1097,6 @@ import { createDuCommand, createDuCommands, duCommands, evalSyncDu } from "../..
|
|
|
1206
1097
|
init_platform();
|
|
1207
1098
|
import { createWhichCommand, createWhichCommands, evalSyncWhich, whichCommands } from "../../safe-bash-command-which/index.js";
|
|
1208
1099
|
|
|
1209
|
-
// packages/safe-bash/src/commands/bc/index.ts
|
|
1210
|
-
init_platform();
|
|
1211
|
-
import {
|
|
1212
|
-
createBcCommand as createRawBcCommand,
|
|
1213
|
-
createBcCommands as createRawBcCommands
|
|
1214
|
-
} from "../../safe-bash-command-bc/index.js";
|
|
1215
|
-
import { settings as settings6 } from "../../safe-bash-command-bc/index.js";
|
|
1216
|
-
function createBcCommand(options2 = {}) {
|
|
1217
|
-
return registerDefaultExecutor(createRawBcCommand(options2), options2);
|
|
1218
|
-
}
|
|
1219
|
-
function createBcCommands(options2 = {}) {
|
|
1220
|
-
return registerDefaultExecutors(createRawBcCommands(options2), options2);
|
|
1221
|
-
}
|
|
1222
|
-
function bcCommands(options2 = {}) {
|
|
1223
|
-
const commands = createBcCommands(options2);
|
|
1224
|
-
const replace = options2.replace ?? false;
|
|
1225
|
-
return {
|
|
1226
|
-
name: "bc-commands",
|
|
1227
|
-
setup(host) {
|
|
1228
|
-
if (!replace) {
|
|
1229
|
-
for (const command5 of commands) {
|
|
1230
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1231
|
-
}
|
|
1232
|
-
}
|
|
1233
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1234
|
-
}
|
|
1235
|
-
};
|
|
1236
|
-
}
|
|
1237
|
-
|
|
1238
|
-
// packages/safe-bash/src/commands/sponge/index.ts
|
|
1239
|
-
init_platform();
|
|
1240
|
-
import {
|
|
1241
|
-
createSpongeCommand as createRawSpongeCommand,
|
|
1242
|
-
createSpongeCommands as createRawSpongeCommands,
|
|
1243
|
-
spongeCommands as rawSpongeCommands,
|
|
1244
|
-
settings as settings7
|
|
1245
|
-
} from "../../safe-bash-command-sponge/index.js";
|
|
1246
|
-
function evalSyncSponge(inBytes, opArgs, readFileSync, writeFileSync) {
|
|
1247
|
-
let append = false;
|
|
1248
|
-
const files = [];
|
|
1249
|
-
let endOfOptions = false;
|
|
1250
|
-
for (const arg of opArgs) {
|
|
1251
|
-
if (!endOfOptions && arg === "--") {
|
|
1252
|
-
endOfOptions = true;
|
|
1253
|
-
continue;
|
|
1254
|
-
}
|
|
1255
|
-
if (!endOfOptions && arg === "--append") {
|
|
1256
|
-
append = true;
|
|
1257
|
-
continue;
|
|
1258
|
-
}
|
|
1259
|
-
if (!endOfOptions && (arg === "--help" || arg === "-h")) {
|
|
1260
|
-
return "Usage: sponge [-a] [FILE]\nSoak up standard input and write to FILE (or stdout).\n";
|
|
1261
|
-
}
|
|
1262
|
-
if (!endOfOptions && arg === "--version") {
|
|
1263
|
-
return "sponge (virtual-bash)\n";
|
|
1264
|
-
}
|
|
1265
|
-
if (!endOfOptions && arg.startsWith("-") && arg.length > 1) {
|
|
1266
|
-
for (let i = 1; i < arg.length; i++) {
|
|
1267
|
-
if (arg[i] === "a") append = true;
|
|
1268
|
-
else return void 0;
|
|
1269
|
-
}
|
|
1270
|
-
continue;
|
|
1271
|
-
}
|
|
1272
|
-
files.push(arg);
|
|
1273
|
-
}
|
|
1274
|
-
if (files.length > 1) return void 0;
|
|
1275
|
-
const payload = inBytes ?? new Uint8Array(0);
|
|
1276
|
-
if (files.length === 0 || files[0] === "-") return decoder.decode(payload);
|
|
1277
|
-
if (!writeFileSync) return void 0;
|
|
1278
|
-
const target = files[0];
|
|
1279
|
-
if (append) {
|
|
1280
|
-
const existing = readFileSync?.(target) ?? new Uint8Array(0);
|
|
1281
|
-
const combined = new Uint8Array(existing.length + payload.length);
|
|
1282
|
-
combined.set(existing, 0);
|
|
1283
|
-
combined.set(payload, existing.length);
|
|
1284
|
-
if (!writeFileSync(target, combined)) return void 0;
|
|
1285
|
-
} else {
|
|
1286
|
-
if (!writeFileSync(target, payload)) return void 0;
|
|
1287
|
-
}
|
|
1288
|
-
return "";
|
|
1289
|
-
}
|
|
1290
|
-
syncCommandEvaluators.evalSyncSponge = evalSyncSponge;
|
|
1291
|
-
function createSpongeCommand(options2 = {}) {
|
|
1292
|
-
const def = createRawSpongeCommand(options2);
|
|
1293
|
-
if (isDefaultCommandOptions(options2)) builtInDirectContextExecutors.add(def.execute);
|
|
1294
|
-
return def;
|
|
1295
|
-
}
|
|
1296
|
-
function createSpongeCommands(options2 = {}) {
|
|
1297
|
-
return createRawSpongeCommands(options2).map((def) => {
|
|
1298
|
-
if (isDefaultCommandOptions(options2)) builtInDirectContextExecutors.add(def.execute);
|
|
1299
|
-
return def;
|
|
1300
|
-
});
|
|
1301
|
-
}
|
|
1302
|
-
function spongeCommands(options2 = {}) {
|
|
1303
|
-
const plugin = rawSpongeCommands(options2);
|
|
1304
|
-
return {
|
|
1305
|
-
...plugin,
|
|
1306
|
-
setup(host) {
|
|
1307
|
-
for (const def of createSpongeCommands(options2)) {
|
|
1308
|
-
if (!options2.replace && host.commands.has(def.name)) throw new Error(`Command already registered: ${def.name}`);
|
|
1309
|
-
host.commands.register(def, { replace: options2.replace ?? false });
|
|
1310
|
-
}
|
|
1311
|
-
}
|
|
1312
|
-
};
|
|
1313
|
-
}
|
|
1314
|
-
|
|
1315
1100
|
// packages/safe-bash/src/commands/fd/index.ts
|
|
1316
1101
|
init_platform();
|
|
1317
1102
|
import {
|
|
@@ -1332,11 +1117,11 @@ function fdCommands(options2 = {}) {
|
|
|
1332
1117
|
name: "fd-commands",
|
|
1333
1118
|
setup(host) {
|
|
1334
1119
|
if (!replace) {
|
|
1335
|
-
for (const
|
|
1336
|
-
if (host.commands.has(
|
|
1120
|
+
for (const command3 of commands) {
|
|
1121
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1337
1122
|
}
|
|
1338
1123
|
}
|
|
1339
|
-
for (const
|
|
1124
|
+
for (const command3 of commands) host.commands.register(command3, { replace });
|
|
1340
1125
|
}
|
|
1341
1126
|
};
|
|
1342
1127
|
}
|
|
@@ -1349,7 +1134,7 @@ import {
|
|
|
1349
1134
|
createLessCommands as createRawLessCommands,
|
|
1350
1135
|
createPagerCommands as createRawPagerCommands
|
|
1351
1136
|
} from "../../safe-bash-command-less/index.js";
|
|
1352
|
-
import { evalSyncLess, settings as
|
|
1137
|
+
import { evalSyncLess, settings as settings3 } from "../../safe-bash-command-less/index.js";
|
|
1353
1138
|
function createLessCommand(options2 = {}) {
|
|
1354
1139
|
return registerDefaultExecutor(createRawLessCommand(options2), options2);
|
|
1355
1140
|
}
|
|
@@ -1369,11 +1154,11 @@ function lessCommands(options2 = {}) {
|
|
|
1369
1154
|
name: "less-commands",
|
|
1370
1155
|
setup(host) {
|
|
1371
1156
|
if (!replace) {
|
|
1372
|
-
for (const
|
|
1373
|
-
if (host.commands.has(
|
|
1157
|
+
for (const command3 of commands) {
|
|
1158
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1374
1159
|
}
|
|
1375
1160
|
}
|
|
1376
|
-
for (const
|
|
1161
|
+
for (const command3 of commands) host.commands.register(command3, { replace });
|
|
1377
1162
|
}
|
|
1378
1163
|
};
|
|
1379
1164
|
}
|
|
@@ -1381,207 +1166,6 @@ function pagerCommands(options2 = {}) {
|
|
|
1381
1166
|
return lessCommands(options2);
|
|
1382
1167
|
}
|
|
1383
1168
|
|
|
1384
|
-
// packages/safe-bash/src/commands/id/index.ts
|
|
1385
|
-
init_platform();
|
|
1386
|
-
import {
|
|
1387
|
-
createIdCommand as createRawIdCommand,
|
|
1388
|
-
createIdCommands as createRawIdCommands
|
|
1389
|
-
} from "../../safe-bash-command-id/index.js";
|
|
1390
|
-
import { settings as settings9 } from "../../safe-bash-command-id/index.js";
|
|
1391
|
-
function createIdCommand(options2 = {}) {
|
|
1392
|
-
return registerDefaultExecutor(createRawIdCommand(options2), options2);
|
|
1393
|
-
}
|
|
1394
|
-
function createIdCommands(options2 = {}) {
|
|
1395
|
-
return registerDefaultExecutors(createRawIdCommands(options2), options2);
|
|
1396
|
-
}
|
|
1397
|
-
function idCommands(options2 = {}) {
|
|
1398
|
-
const commands = createIdCommands(options2);
|
|
1399
|
-
const replace = options2.replace ?? false;
|
|
1400
|
-
return {
|
|
1401
|
-
name: "id-commands",
|
|
1402
|
-
setup(host) {
|
|
1403
|
-
if (!replace) {
|
|
1404
|
-
for (const command5 of commands) {
|
|
1405
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1406
|
-
}
|
|
1407
|
-
}
|
|
1408
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1409
|
-
}
|
|
1410
|
-
};
|
|
1411
|
-
}
|
|
1412
|
-
|
|
1413
|
-
// packages/safe-bash/src/commands/whoami/index.ts
|
|
1414
|
-
init_platform();
|
|
1415
|
-
import {
|
|
1416
|
-
createWhoamiCommand as createRawWhoamiCommand,
|
|
1417
|
-
createWhoamiCommands as createRawWhoamiCommands
|
|
1418
|
-
} from "../../safe-bash-command-whoami/index.js";
|
|
1419
|
-
import { settings as settings10 } from "../../safe-bash-command-whoami/index.js";
|
|
1420
|
-
function createWhoamiCommand(options2 = {}) {
|
|
1421
|
-
return registerDefaultExecutor(createRawWhoamiCommand(options2), options2);
|
|
1422
|
-
}
|
|
1423
|
-
function createWhoamiCommands(options2 = {}) {
|
|
1424
|
-
return registerDefaultExecutors(createRawWhoamiCommands(options2), options2);
|
|
1425
|
-
}
|
|
1426
|
-
function whoamiCommands(options2 = {}) {
|
|
1427
|
-
const commands = createWhoamiCommands(options2);
|
|
1428
|
-
const replace = options2.replace ?? false;
|
|
1429
|
-
return {
|
|
1430
|
-
name: "whoami-commands",
|
|
1431
|
-
setup(host) {
|
|
1432
|
-
if (!replace) {
|
|
1433
|
-
for (const command5 of commands) {
|
|
1434
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1435
|
-
}
|
|
1436
|
-
}
|
|
1437
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1438
|
-
}
|
|
1439
|
-
};
|
|
1440
|
-
}
|
|
1441
|
-
|
|
1442
|
-
// packages/safe-bash/src/commands/uname/index.ts
|
|
1443
|
-
init_platform();
|
|
1444
|
-
import {
|
|
1445
|
-
createUnameCommand as createRawUnameCommand,
|
|
1446
|
-
createUnameCommands as createRawUnameCommands
|
|
1447
|
-
} from "../../safe-bash-command-uname/index.js";
|
|
1448
|
-
import { settings as settings11 } from "../../safe-bash-command-uname/index.js";
|
|
1449
|
-
function createUnameCommand(options2 = {}) {
|
|
1450
|
-
return registerDefaultExecutor(createRawUnameCommand(options2), options2);
|
|
1451
|
-
}
|
|
1452
|
-
function createUnameCommands(options2 = {}) {
|
|
1453
|
-
return registerDefaultExecutors(createRawUnameCommands(options2), options2);
|
|
1454
|
-
}
|
|
1455
|
-
function unameCommands(options2 = {}) {
|
|
1456
|
-
const commands = createUnameCommands(options2);
|
|
1457
|
-
const replace = options2.replace ?? false;
|
|
1458
|
-
return {
|
|
1459
|
-
name: "uname-commands",
|
|
1460
|
-
setup(host) {
|
|
1461
|
-
if (!replace) {
|
|
1462
|
-
for (const command5 of commands) {
|
|
1463
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1464
|
-
}
|
|
1465
|
-
}
|
|
1466
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1467
|
-
}
|
|
1468
|
-
};
|
|
1469
|
-
}
|
|
1470
|
-
|
|
1471
|
-
// packages/safe-bash/src/commands/hostname/index.ts
|
|
1472
|
-
init_platform();
|
|
1473
|
-
import {
|
|
1474
|
-
createHostnameCommand as createRawHostnameCommand,
|
|
1475
|
-
createHostnameCommands as createRawHostnameCommands
|
|
1476
|
-
} from "../../safe-bash-command-hostname/index.js";
|
|
1477
|
-
import { settings as settings12 } from "../../safe-bash-command-hostname/index.js";
|
|
1478
|
-
function createHostnameCommand(options2 = {}) {
|
|
1479
|
-
return registerDefaultExecutor(createRawHostnameCommand(options2), options2);
|
|
1480
|
-
}
|
|
1481
|
-
function createHostnameCommands(options2 = {}) {
|
|
1482
|
-
return registerDefaultExecutors(createRawHostnameCommands(options2), options2);
|
|
1483
|
-
}
|
|
1484
|
-
function hostnameCommands(options2 = {}) {
|
|
1485
|
-
const commands = createHostnameCommands(options2);
|
|
1486
|
-
const replace = options2.replace ?? false;
|
|
1487
|
-
return {
|
|
1488
|
-
name: "hostname-commands",
|
|
1489
|
-
setup(host) {
|
|
1490
|
-
if (!replace) {
|
|
1491
|
-
for (const command5 of commands) {
|
|
1492
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1493
|
-
}
|
|
1494
|
-
}
|
|
1495
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1496
|
-
}
|
|
1497
|
-
};
|
|
1498
|
-
}
|
|
1499
|
-
|
|
1500
|
-
// packages/safe-bash/src/commands/nproc/index.ts
|
|
1501
|
-
init_platform();
|
|
1502
|
-
import {
|
|
1503
|
-
createNprocCommand as createRawNprocCommand,
|
|
1504
|
-
createNprocCommands as createRawNprocCommands
|
|
1505
|
-
} from "../../safe-bash-command-nproc/index.js";
|
|
1506
|
-
import { settings as settings13 } from "../../safe-bash-command-nproc/index.js";
|
|
1507
|
-
function createNprocCommand(options2 = {}) {
|
|
1508
|
-
return registerDefaultExecutor(createRawNprocCommand(options2), options2);
|
|
1509
|
-
}
|
|
1510
|
-
function createNprocCommands(options2 = {}) {
|
|
1511
|
-
return registerDefaultExecutors(createRawNprocCommands(options2), options2);
|
|
1512
|
-
}
|
|
1513
|
-
function nprocCommands(options2 = {}) {
|
|
1514
|
-
const commands = createNprocCommands(options2);
|
|
1515
|
-
const replace = options2.replace ?? false;
|
|
1516
|
-
return {
|
|
1517
|
-
name: "nproc-commands",
|
|
1518
|
-
setup(host) {
|
|
1519
|
-
if (!replace) {
|
|
1520
|
-
for (const command5 of commands) {
|
|
1521
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1522
|
-
}
|
|
1523
|
-
}
|
|
1524
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1525
|
-
}
|
|
1526
|
-
};
|
|
1527
|
-
}
|
|
1528
|
-
|
|
1529
|
-
// packages/safe-bash/src/shuf.ts
|
|
1530
|
-
init_platform();
|
|
1531
|
-
import { createShufCommand, createShufCommands, shufCommands } from "../../safe-bash-command-shuf/index.js";
|
|
1532
|
-
|
|
1533
|
-
// packages/safe-bash/src/dd.ts
|
|
1534
|
-
init_platform();
|
|
1535
|
-
import {
|
|
1536
|
-
createDdCommand as createRawDdCommand,
|
|
1537
|
-
createDdCommands as createRawDdCommands
|
|
1538
|
-
} from "../../safe-bash-command-dd/index.js";
|
|
1539
|
-
import { evalSyncDd, openDdFile, settings as settings14, transferReport } from "../../safe-bash-command-dd/index.js";
|
|
1540
|
-
function createDdCommand(options2 = {}) {
|
|
1541
|
-
return registerDefaultExecutor(createRawDdCommand(options2), options2);
|
|
1542
|
-
}
|
|
1543
|
-
function createDdCommands(options2 = {}) {
|
|
1544
|
-
return registerDefaultExecutors(createRawDdCommands(options2), options2);
|
|
1545
|
-
}
|
|
1546
|
-
function ddCommands(options2 = {}) {
|
|
1547
|
-
const commands = createDdCommands(options2);
|
|
1548
|
-
const replace = options2.replace ?? false;
|
|
1549
|
-
return {
|
|
1550
|
-
name: "dd-commands",
|
|
1551
|
-
setup(host) {
|
|
1552
|
-
if (!replace) {
|
|
1553
|
-
for (const command5 of commands) {
|
|
1554
|
-
if (host.commands.has(command5.name)) throw new Error(`Command already registered: ${command5.name}`);
|
|
1555
|
-
}
|
|
1556
|
-
}
|
|
1557
|
-
for (const command5 of commands) host.commands.register(command5, { replace });
|
|
1558
|
-
}
|
|
1559
|
-
};
|
|
1560
|
-
}
|
|
1561
|
-
|
|
1562
|
-
// packages/safe-bash/src/commands/envsubst/index.ts
|
|
1563
|
-
init_platform();
|
|
1564
|
-
import {
|
|
1565
|
-
createEnvsubstCommand as createRawEnvsubstCommand,
|
|
1566
|
-
createEnvsubstCommands as createRawEnvsubstCommands,
|
|
1567
|
-
envsubstCommands as rawEnvsubstCommands
|
|
1568
|
-
} from "../../safe-bash-command-envsubst/index.js";
|
|
1569
|
-
import { settings as settings16 } from "../../safe-bash-command-envsubst/index.js";
|
|
1570
|
-
function createEnvsubstCommand(options2 = {}) {
|
|
1571
|
-
const def = createRawEnvsubstCommand(options2);
|
|
1572
|
-
builtInDirectContextExecutors.add(def.execute);
|
|
1573
|
-
return def;
|
|
1574
|
-
}
|
|
1575
|
-
function createEnvsubstCommands(options2 = {}) {
|
|
1576
|
-
const defs = createRawEnvsubstCommands(options2);
|
|
1577
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1578
|
-
return defs;
|
|
1579
|
-
}
|
|
1580
|
-
function envsubstCommands(options2 = {}) {
|
|
1581
|
-
createEnvsubstCommands(options2);
|
|
1582
|
-
return rawEnvsubstCommands(options2);
|
|
1583
|
-
}
|
|
1584
|
-
|
|
1585
1169
|
// packages/safe-bash/src/commands/cal/index.ts
|
|
1586
1170
|
init_platform();
|
|
1587
1171
|
import {
|
|
@@ -1590,7 +1174,7 @@ import {
|
|
|
1590
1174
|
createCalCommands as createRawCalCommands,
|
|
1591
1175
|
evalSyncCal
|
|
1592
1176
|
} from "../../safe-bash-command-cal/index.js";
|
|
1593
|
-
import { settings as
|
|
1177
|
+
import { settings as settings4 } from "../../safe-bash-command-cal/index.js";
|
|
1594
1178
|
function isDefaultCalOptions(options2) {
|
|
1595
1179
|
return options2?.clock === void 0 && options2?.limits === void 0;
|
|
1596
1180
|
}
|
|
@@ -1617,11 +1201,11 @@ function calCommands(options2 = {}) {
|
|
|
1617
1201
|
name: "cal-commands",
|
|
1618
1202
|
setup(host) {
|
|
1619
1203
|
if (!options2.replace) {
|
|
1620
|
-
for (const
|
|
1621
|
-
if (host.commands.has(
|
|
1204
|
+
for (const command3 of commands) {
|
|
1205
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1622
1206
|
}
|
|
1623
1207
|
}
|
|
1624
|
-
for (const
|
|
1208
|
+
for (const command3 of commands) host.commands.register(command3, { replace: options2.replace ?? false });
|
|
1625
1209
|
}
|
|
1626
1210
|
};
|
|
1627
1211
|
}
|
|
@@ -1632,7 +1216,7 @@ import {
|
|
|
1632
1216
|
createPathchkCommand as createRawPathchkCommand,
|
|
1633
1217
|
createPathchkCommands as createRawPathchkCommands
|
|
1634
1218
|
} from "../../safe-bash-command-pathchk/index.js";
|
|
1635
|
-
import { settings as
|
|
1219
|
+
import { settings as settings5 } from "../../safe-bash-command-pathchk/index.js";
|
|
1636
1220
|
function createPathchkCommand(options2 = {}) {
|
|
1637
1221
|
return registerDefaultExecutor(createRawPathchkCommand(options2), options2);
|
|
1638
1222
|
}
|
|
@@ -1646,11 +1230,11 @@ function pathchkCommands(options2 = {}) {
|
|
|
1646
1230
|
name: "pathchk-commands",
|
|
1647
1231
|
setup(host) {
|
|
1648
1232
|
if (!replace) {
|
|
1649
|
-
for (const
|
|
1650
|
-
if (host.commands.has(
|
|
1233
|
+
for (const command3 of commands) {
|
|
1234
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1651
1235
|
}
|
|
1652
1236
|
}
|
|
1653
|
-
for (const
|
|
1237
|
+
for (const command3 of commands) host.commands.register(command3, { replace });
|
|
1654
1238
|
}
|
|
1655
1239
|
};
|
|
1656
1240
|
}
|
|
@@ -1731,95 +1315,13 @@ function evalSyncPathchk(opArgs, cwd = "/", statTypeSync) {
|
|
|
1731
1315
|
return "";
|
|
1732
1316
|
}
|
|
1733
1317
|
|
|
1734
|
-
// packages/safe-bash/src/commands/getconf/index.ts
|
|
1735
|
-
init_platform();
|
|
1736
|
-
import {
|
|
1737
|
-
createGetconfCommand as createRawGetconfCommand,
|
|
1738
|
-
createGetconfCommands as createRawGetconfCommands
|
|
1739
|
-
} from "../../safe-bash-command-getconf/index.js";
|
|
1740
|
-
import { settings as settings19 } from "../../safe-bash-command-getconf/index.js";
|
|
1741
|
-
function isDefaultGetconfOptions(options2) {
|
|
1742
|
-
return options2?.processors === void 0 && options2?.variables === void 0 && options2?.limits === void 0;
|
|
1743
|
-
}
|
|
1744
|
-
function createGetconfCommand(options2 = {}) {
|
|
1745
|
-
const def = createRawGetconfCommand(options2);
|
|
1746
|
-
if (isDefaultGetconfOptions(options2)) builtInDirectContextExecutors.add(def.execute);
|
|
1747
|
-
return def;
|
|
1748
|
-
}
|
|
1749
|
-
function createGetconfCommands(options2 = {}) {
|
|
1750
|
-
const defs = createRawGetconfCommands(options2);
|
|
1751
|
-
if (isDefaultGetconfOptions(options2)) {
|
|
1752
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1753
|
-
}
|
|
1754
|
-
return defs;
|
|
1755
|
-
}
|
|
1756
|
-
function getconfCommands(options2 = {}) {
|
|
1757
|
-
const commands = createGetconfCommands(options2);
|
|
1758
|
-
return {
|
|
1759
|
-
name: "getconf-commands",
|
|
1760
|
-
setup(host) {
|
|
1761
|
-
if (!options2.replace) {
|
|
1762
|
-
for (const command5 of commands) {
|
|
1763
|
-
if (host.commands.has(command5.name)) {
|
|
1764
|
-
throw new Error(`Command already registered: ${command5.name}`);
|
|
1765
|
-
}
|
|
1766
|
-
}
|
|
1767
|
-
}
|
|
1768
|
-
for (const command5 of commands) {
|
|
1769
|
-
host.commands.register(command5, { replace: options2.replace ?? false });
|
|
1770
|
-
}
|
|
1771
|
-
}
|
|
1772
|
-
};
|
|
1773
|
-
}
|
|
1774
|
-
|
|
1775
|
-
// packages/safe-bash/src/commands/locale/index.ts
|
|
1776
|
-
init_platform();
|
|
1777
|
-
import {
|
|
1778
|
-
createLocaleCommand as createRawLocaleCommand,
|
|
1779
|
-
createLocaleCommands as createRawLocaleCommands
|
|
1780
|
-
} from "../../safe-bash-command-locale/index.js";
|
|
1781
|
-
import { settings as settings20 } from "../../safe-bash-command-locale/index.js";
|
|
1782
|
-
function isDefaultLocaleOptions(options2) {
|
|
1783
|
-
return options2?.locales === void 0 && options2?.charmaps === void 0 && options2?.defaultLocale === void 0 && options2?.limits === void 0;
|
|
1784
|
-
}
|
|
1785
|
-
function createLocaleCommand(options2 = {}) {
|
|
1786
|
-
const def = createRawLocaleCommand(options2);
|
|
1787
|
-
if (isDefaultLocaleOptions(options2)) builtInDirectContextExecutors.add(def.execute);
|
|
1788
|
-
return def;
|
|
1789
|
-
}
|
|
1790
|
-
function createLocaleCommands(options2 = {}) {
|
|
1791
|
-
const defs = createRawLocaleCommands(options2);
|
|
1792
|
-
if (isDefaultLocaleOptions(options2)) {
|
|
1793
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1794
|
-
}
|
|
1795
|
-
return defs;
|
|
1796
|
-
}
|
|
1797
|
-
function localeCommands(options2 = {}) {
|
|
1798
|
-
const commands = createLocaleCommands(options2);
|
|
1799
|
-
return {
|
|
1800
|
-
name: "locale-commands",
|
|
1801
|
-
setup(host) {
|
|
1802
|
-
if (!options2.replace) {
|
|
1803
|
-
for (const command5 of commands) {
|
|
1804
|
-
if (host.commands.has(command5.name)) {
|
|
1805
|
-
throw new Error(`Command already registered: ${command5.name}`);
|
|
1806
|
-
}
|
|
1807
|
-
}
|
|
1808
|
-
}
|
|
1809
|
-
for (const command5 of commands) {
|
|
1810
|
-
host.commands.register(command5, { replace: options2.replace ?? false });
|
|
1811
|
-
}
|
|
1812
|
-
}
|
|
1813
|
-
};
|
|
1814
|
-
}
|
|
1815
|
-
|
|
1816
1318
|
// packages/safe-bash/src/commands/df/index.ts
|
|
1817
1319
|
init_platform();
|
|
1818
1320
|
import {
|
|
1819
1321
|
createDfCommand as createRawDfCommand,
|
|
1820
1322
|
createDfCommands as createRawDfCommands
|
|
1821
1323
|
} from "../../safe-bash-command-df/index.js";
|
|
1822
|
-
import { dfExecutorOptions, evalSyncDf, settings as
|
|
1324
|
+
import { dfExecutorOptions, evalSyncDf, settings as settings6 } from "../../safe-bash-command-df/index.js";
|
|
1823
1325
|
function createDfCommand(options2 = {}) {
|
|
1824
1326
|
return registerDefaultExecutor(createRawDfCommand(options2), options2);
|
|
1825
1327
|
}
|
|
@@ -1833,68 +1335,22 @@ function dfCommands(options2 = {}) {
|
|
|
1833
1335
|
name: "df-commands",
|
|
1834
1336
|
setup(host) {
|
|
1835
1337
|
if (!replace) {
|
|
1836
|
-
for (const
|
|
1837
|
-
if (host.commands.has(
|
|
1338
|
+
for (const command3 of commands) {
|
|
1339
|
+
if (host.commands.has(command3.name)) throw new Error(`Command already registered: ${command3.name}`);
|
|
1838
1340
|
}
|
|
1839
1341
|
}
|
|
1840
|
-
for (const
|
|
1342
|
+
for (const command3 of commands) host.commands.register(command3, { replace });
|
|
1841
1343
|
}
|
|
1842
1344
|
};
|
|
1843
1345
|
}
|
|
1844
1346
|
|
|
1845
|
-
// packages/safe-bash/src/commands/sqlite3/index.ts
|
|
1846
|
-
init_platform();
|
|
1847
|
-
import {
|
|
1848
|
-
createSqlite3Command as createRawSqlite3Command,
|
|
1849
|
-
createSqlite3Commands as createRawSqlite3Commands,
|
|
1850
|
-
evalSyncSqlite3
|
|
1851
|
-
} from "../../safe-bash-command-sqlite3/index.js";
|
|
1852
|
-
import { evalSyncSqlite3 as evalSyncSqlite32, settings as settings22 } from "../../safe-bash-command-sqlite3/index.js";
|
|
1853
|
-
function isDefaultSqlite3Options(options2) {
|
|
1854
|
-
if (!options2) return true;
|
|
1855
|
-
return options2.limits === void 0 && options2.engine === void 0;
|
|
1856
|
-
}
|
|
1857
|
-
function createSqlite3Command(options2 = {}) {
|
|
1858
|
-
const def = createRawSqlite3Command(options2);
|
|
1859
|
-
if (isDefaultSqlite3Options(options2)) {
|
|
1860
|
-
builtInDirectContextExecutors.add(def.execute);
|
|
1861
|
-
}
|
|
1862
|
-
return def;
|
|
1863
|
-
}
|
|
1864
|
-
function createSqlite3Commands(options2 = {}) {
|
|
1865
|
-
const defs = createRawSqlite3Commands(options2);
|
|
1866
|
-
if (isDefaultSqlite3Options(options2)) {
|
|
1867
|
-
for (let i = 0; i < defs.length; i++) builtInDirectContextExecutors.add(defs[i].execute);
|
|
1868
|
-
}
|
|
1869
|
-
return defs;
|
|
1870
|
-
}
|
|
1871
|
-
function sqlite3Commands(options2 = {}) {
|
|
1872
|
-
const commands = createSqlite3Commands(options2);
|
|
1873
|
-
return {
|
|
1874
|
-
name: "sqlite3-commands",
|
|
1875
|
-
setup(host) {
|
|
1876
|
-
if (!options2.replace) {
|
|
1877
|
-
for (const command5 of commands) {
|
|
1878
|
-
if (host.commands.has(command5.name)) {
|
|
1879
|
-
throw new Error(`Command already registered: ${command5.name}`);
|
|
1880
|
-
}
|
|
1881
|
-
}
|
|
1882
|
-
}
|
|
1883
|
-
for (const command5 of commands) {
|
|
1884
|
-
host.commands.register(command5, { replace: options2.replace ?? false });
|
|
1885
|
-
}
|
|
1886
|
-
}
|
|
1887
|
-
};
|
|
1888
|
-
}
|
|
1889
|
-
syncCommandEvaluators.evalSyncSqlite3 = evalSyncSqlite3;
|
|
1890
|
-
|
|
1891
1347
|
// packages/safe-bash/src/commands/search/rg-command.ts
|
|
1892
1348
|
init_platform();
|
|
1893
1349
|
import { clearRgFastRunnerPool, createRgCommand, preverifyMemoryRgTree } from "../../safe-bash-command-rg/rg-command.js";
|
|
1894
1350
|
|
|
1895
1351
|
// packages/safe-bash/src/commands/bytes/checksums/index.ts
|
|
1896
1352
|
init_platform();
|
|
1897
|
-
import { command as
|
|
1353
|
+
import { command as command2 } from "../../safe-bash-checksum-engine/index.js";
|
|
1898
1354
|
|
|
1899
1355
|
// packages/safe-bash/src/commands/md5sum/index.ts
|
|
1900
1356
|
init_platform();
|
|
@@ -1912,11 +1368,12 @@ import { createSha256sumCommand, createSha256sumCommands, sha256sumCommands } fr
|
|
|
1912
1368
|
import { evalSyncChecksum } from "../../safe-bash-checksum-engine/index.js";
|
|
1913
1369
|
function createChecksumCommands(options2 = {}) {
|
|
1914
1370
|
const maximum = resolveInputLimit(options2);
|
|
1915
|
-
return [
|
|
1371
|
+
return [command2("sha512sum", "sha512", maximum), command2("sha384sum", "sha384", maximum), createSha256sumCommand(options2), command2("sha224sum", "sha224", maximum), createSha1sumCommand(options2), createMd5sumCommand(options2), command2("cksum", "crc", maximum)];
|
|
1916
1372
|
}
|
|
1917
1373
|
|
|
1918
1374
|
// packages/safe-bash/src/commands/bytes/compression/index.ts
|
|
1919
1375
|
init_platform();
|
|
1376
|
+
import { withInputByteBudget } from "../../safe-bash-contracts/index.js";
|
|
1920
1377
|
import { createGzipCommands } from "../../safe-bash-command-gzip/index.js";
|
|
1921
1378
|
import bz2Factory from "../../safe-bash-compression-engine/native/bz2.js";
|
|
1922
1379
|
import xzFactory from "../../safe-bash-compression-engine/native/xz.js";
|
|
@@ -1947,7 +1404,7 @@ function createCompressionCommands(config = {}) {
|
|
|
1947
1404
|
if (maxDecodedBytes !== void 0 && maxDecodedBytes !== Infinity && (!Number.isSafeInteger(maxDecodedBytes) || maxDecodedBytes < 0)) {
|
|
1948
1405
|
throw new RangeError("maxDecodedBytes must be a nonnegative safe integer or Infinity");
|
|
1949
1406
|
}
|
|
1950
|
-
const commands = profiles.flatMap((profile) => profile.format === "gzip" ? createGzipCommands(config) : profile.format === "bzip2" ? createBzip2Commands(config) : profile.names.map((name) => define(name, async (context) => {
|
|
1407
|
+
const commands = profiles.flatMap((profile) => profile.format === "gzip" ? createGzipCommands(config) : profile.format === "bzip2" ? createBzip2Commands(config) : profile.names.map((name) => define(name, withInputByteBudget(async (context) => {
|
|
1951
1408
|
const options2 = parseOptions(name, context.args);
|
|
1952
1409
|
if (options2.help) {
|
|
1953
1410
|
await output(context, `Usage: ${name} [OPTION]... [FILE]...
|
|
@@ -2001,7 +1458,7 @@ No FILE or FILE '-' uses stdin; file output uses private VFS staging.
|
|
|
2001
1458
|
}
|
|
2002
1459
|
}
|
|
2003
1460
|
return { exitCode };
|
|
2004
|
-
})));
|
|
1461
|
+
}))));
|
|
2005
1462
|
const xzCmds = createXzCommands(config);
|
|
2006
1463
|
if (maxDecodedBytes === void 0 || maxDecodedBytes === Infinity) {
|
|
2007
1464
|
for (const c of [...commands, ...xzCmds]) builtInDirectContextExecutors.add(c.execute);
|
|
@@ -2741,9 +2198,9 @@ function basicCommands() {
|
|
|
2741
2198
|
return { exitCode: 0 };
|
|
2742
2199
|
}, 1, 1),
|
|
2743
2200
|
printfCommand
|
|
2744
|
-
].map((
|
|
2745
|
-
if (
|
|
2746
|
-
return { ...
|
|
2201
|
+
].map((command3) => {
|
|
2202
|
+
if (command3.name === "echo") defaultEchoExecutors.add(command3.execute);
|
|
2203
|
+
return { ...command3, filesystemRequirements: command3.name === "pwd" ? pwdRequirements : [] };
|
|
2747
2204
|
});
|
|
2748
2205
|
}
|
|
2749
2206
|
async function formatPrintf(context) {
|
|
@@ -4145,7 +3602,6 @@ var MKDIR_PARENTS_MODES = ["parents"];
|
|
|
4145
3602
|
var MKDIR_DIR_MODES = ["directory"];
|
|
4146
3603
|
var RM_RECURSIVE_MODES = ["recursive"];
|
|
4147
3604
|
var RM_FILE_MODES = ["file"];
|
|
4148
|
-
var MAX_RECURSIVE_DIRECTORY_DEPTH = 1024;
|
|
4149
3605
|
var MKDIR_LONG_OPTIONS = Object.freeze({ parents: "p", mode: "m", verbose: "v" });
|
|
4150
3606
|
var TOUCH_LONG_OPTIONS = Object.freeze({ "no-create": "c", "no-dereference": "h", reference: "r", date: "d", time: "time:" });
|
|
4151
3607
|
var MV_LONG_OPTIONS = Object.freeze({
|
|
@@ -4311,9 +3767,9 @@ function childOperand(operand, name) {
|
|
|
4311
3767
|
while (operand.endsWith("/")) operand = operand.slice(0, -1);
|
|
4312
3768
|
return `${operand}/${name}`;
|
|
4313
3769
|
}
|
|
4314
|
-
async function copy(context, source, target,
|
|
3770
|
+
async function copy(context, source, target, settings7, readDirectory, top = true, ancestors = /* @__PURE__ */ new Set(), preflight = false, displaySource = source, displayTarget = target, rootStat) {
|
|
4315
3771
|
context.signal.throwIfAborted();
|
|
4316
|
-
const { flags, preserve: requestedPreserve, copiedLinks, backup } =
|
|
3772
|
+
const { flags, preserve: requestedPreserve, copiedLinks, backup } = settings7;
|
|
4317
3773
|
const attributesOnly = flags.has("attributes-only");
|
|
4318
3774
|
const linkMode = flags.has("s") || flags.has("l");
|
|
4319
3775
|
const link = await context.fs.lstat(source, { signal: context.signal });
|
|
@@ -4333,11 +3789,11 @@ async function copy(context, source, target, settings23, readDirectory, top = tr
|
|
|
4333
3789
|
if (!preflight && !preserveLink && targetStat && await compareObservedEntries(context.fs, source, sourceStat, context.fs, target, targetStat, { signal: context.signal }) === "same") {
|
|
4334
3790
|
throw new FsError("EINVAL", { path: source, dest: target, message: "source and destination are the same file" });
|
|
4335
3791
|
}
|
|
4336
|
-
if (!preflight && sourceStat.type !== "directory" && targetStat && targetStat.type !== "directory" &&
|
|
4337
|
-
const metadata3 =
|
|
4338
|
-
if (preserve.has("timestamps") && !
|
|
3792
|
+
if (!preflight && sourceStat.type !== "directory" && targetStat && targetStat.type !== "directory" && settings7.confirmOverwrite && !await settings7.confirmOverwrite(displayTarget)) return;
|
|
3793
|
+
const metadata3 = settings7.sourceMetadata.get(physicalSource) ?? sourceStat;
|
|
3794
|
+
if (preserve.has("timestamps") && !settings7.sourceMetadata.has(physicalSource)) settings7.sourceMetadata.set(physicalSource, metadata3);
|
|
4339
3795
|
await admitCopyPreservation(context, preserve, sourceStat, target, targetStat);
|
|
4340
|
-
const previousSource =
|
|
3796
|
+
const previousSource = settings7.copiedTargets.get(physicalTarget);
|
|
4341
3797
|
if (previousSource && compareCopyIdentity(previousSource, sourceStat) !== "same") {
|
|
4342
3798
|
throw new PublicDiagnostic(`will not overwrite just-created '${displayTarget}' with '${displaySource}'`);
|
|
4343
3799
|
}
|
|
@@ -4379,8 +3835,8 @@ async function copy(context, source, target, settings23, readDirectory, top = tr
|
|
|
4379
3835
|
if (ancestors.has(physicalSource)) throw new FsError("ELOOP", { path: source });
|
|
4380
3836
|
if (targetStat && targetStat.type !== "directory") throw new FsError("ENOTDIR", { path: target });
|
|
4381
3837
|
context.signal.throwIfAborted();
|
|
4382
|
-
if (ancestors.size >
|
|
4383
|
-
throw new FsError("ELOOP", { path: source, message: `cp directory depth limit exceeded (${
|
|
3838
|
+
if (ancestors.size > (settings7.maxRecursiveDirectoryDepth ?? Infinity)) {
|
|
3839
|
+
throw new FsError("ELOOP", { path: source, message: `cp directory depth limit exceeded (${settings7.maxRecursiveDirectoryDepth})` });
|
|
4384
3840
|
}
|
|
4385
3841
|
await admitFilesystemModes(context, "cp", [attributesOnly ? "attributes-recursive" : "recursive"], [target]);
|
|
4386
3842
|
const capabilities = await context.fs.capabilitiesFor?.(target, { signal: context.signal }) ?? context.fs.capabilities;
|
|
@@ -4406,7 +3862,7 @@ async function copy(context, source, target, settings23, readDirectory, top = tr
|
|
|
4406
3862
|
context,
|
|
4407
3863
|
joinPath(source, entry.name),
|
|
4408
3864
|
joinPath(target, entry.name),
|
|
4409
|
-
|
|
3865
|
+
settings7,
|
|
4410
3866
|
readDirectory,
|
|
4411
3867
|
false,
|
|
4412
3868
|
ancestors,
|
|
@@ -4507,7 +3963,7 @@ async function copy(context, source, target, settings23, readDirectory, top = tr
|
|
|
4507
3963
|
if (preflight) {
|
|
4508
3964
|
if (links) {
|
|
4509
3965
|
links.set(identity, { path: target });
|
|
4510
|
-
|
|
3966
|
+
settings7.copiedTargets.set(physicalTarget, sourceStat);
|
|
4511
3967
|
}
|
|
4512
3968
|
return;
|
|
4513
3969
|
}
|
|
@@ -4533,7 +3989,7 @@ async function copy(context, source, target, settings23, readDirectory, top = tr
|
|
|
4533
3989
|
}
|
|
4534
3990
|
if (!preflight) await preserveCopyMetadata(context, preserve, metadata3, target);
|
|
4535
3991
|
context.signal.throwIfAborted();
|
|
4536
|
-
if (links)
|
|
3992
|
+
if (links) settings7.copiedTargets.set(physicalTarget, sourceStat);
|
|
4537
3993
|
if (links && !previous) links.set(identity, { path: target, ...preflight ? {} : { stat: await context.fs.lstat(target, { signal: context.signal }) } });
|
|
4538
3994
|
if (!preflight && flags.has("v")) await output(context, `'${escapeText(displaySource, "display")}' -> '${escapeText(displayTarget, "display")}'
|
|
4539
3995
|
`);
|
|
@@ -4551,7 +4007,10 @@ function modeText(stat) {
|
|
|
4551
4007
|
}
|
|
4552
4008
|
var defaultMkdirExecutors = /* @__PURE__ */ new WeakSet();
|
|
4553
4009
|
var defaultRmExecutors = /* @__PURE__ */ new WeakSet();
|
|
4554
|
-
function filesystemCommands(maxDirectoryEntries) {
|
|
4010
|
+
function filesystemCommands(maxDirectoryEntries, maxRecursiveDirectoryDepth = Infinity) {
|
|
4011
|
+
if (maxRecursiveDirectoryDepth !== Infinity && (!Number.isSafeInteger(maxRecursiveDirectoryDepth) || maxRecursiveDirectoryDepth < 0)) {
|
|
4012
|
+
throw new RangeError("maxRecursiveDirectoryDepth must be a nonnegative safe integer or Infinity");
|
|
4013
|
+
}
|
|
4555
4014
|
const readDirectory = createDirectoryReader(maxDirectoryEntries);
|
|
4556
4015
|
const commands = [
|
|
4557
4016
|
define("mkdir", (context) => {
|
|
@@ -4704,7 +4163,7 @@ function filesystemCommands(maxDirectoryEntries) {
|
|
|
4704
4163
|
}),
|
|
4705
4164
|
createTouchCommand(),
|
|
4706
4165
|
define("cp", async (context) => {
|
|
4707
|
-
const parsed = copyOptions(context);
|
|
4166
|
+
const parsed = { ...copyOptions(context), maxRecursiveDirectoryDepth };
|
|
4708
4167
|
if ((parsed.values.get("t")?.length ?? 0) > 1) throw new UsageError("multiple target directories specified");
|
|
4709
4168
|
const destination = await destinations(context, parsed.operands, value(parsed, "t"), parsed.flags.has("T"));
|
|
4710
4169
|
await preflightOperands(context, destination.sources, async (operand) => {
|
|
@@ -4725,7 +4184,7 @@ function filesystemCommands(maxDirectoryEntries) {
|
|
|
4725
4184
|
parsed.copiedTargets.clear();
|
|
4726
4185
|
const answers = lines(readBytes(context.stdin, context.signal));
|
|
4727
4186
|
let declined = false;
|
|
4728
|
-
const
|
|
4187
|
+
const settings7 = {
|
|
4729
4188
|
...parsed,
|
|
4730
4189
|
...parsed.flags.has("i") ? { confirmOverwrite: async (operand) => {
|
|
4731
4190
|
await writeBytes(context.stderr, new TextEncoder().encode(`cp: overwrite ${quoteShellOperand(operand)}? `), context.signal);
|
|
@@ -4744,7 +4203,7 @@ function filesystemCommands(maxDirectoryEntries) {
|
|
|
4744
4203
|
context,
|
|
4745
4204
|
source,
|
|
4746
4205
|
destination.directory ? joinPath(destination.target, basename(source)) : destination.target,
|
|
4747
|
-
|
|
4206
|
+
settings7,
|
|
4748
4207
|
readDirectory,
|
|
4749
4208
|
true,
|
|
4750
4209
|
/* @__PURE__ */ new Set(),
|
|
@@ -4995,9 +4454,10 @@ function filesystemCommands(maxDirectoryEntries) {
|
|
|
4995
4454
|
else parsed.flags.delete("f");
|
|
4996
4455
|
if (!parsed.flags.has("f")) requireOperands(parsed.operands);
|
|
4997
4456
|
const recursive = parsed.flags.has("r") || parsed.flags.has("R");
|
|
4457
|
+
const recursiveTraversal = recursive && (interactive === "always" || maxRecursiveDirectoryDepth !== Infinity);
|
|
4998
4458
|
const backingMem = getRuntimeBackingFileSystem(context.fs);
|
|
4999
4459
|
const caps = context.fs.capabilities;
|
|
5000
|
-
const fastStockMemory = interactive === "never" && backingMem !== void 0 && backingMem.capabilitiesFor === void 0 && backingMem.symlinkCount === 0 && caps.remove !== false && caps.recursiveRemove !== false && caps.removeDirectory !== false && !caps.readOnly && Object.getPrototypeOf(backingMem)?.constructor?.name === "MemoryFileSystem" && !Object.prototype.hasOwnProperty.call(backingMem, "lstat") && !Object.prototype.hasOwnProperty.call(backingMem, "stat") && !Object.prototype.hasOwnProperty.call(backingMem, "realpath") && !Object.prototype.hasOwnProperty.call(backingMem, "rm") && !Object.prototype.hasOwnProperty.call(backingMem, "rmdir");
|
|
4460
|
+
const fastStockMemory = interactive === "never" && !recursiveTraversal && backingMem !== void 0 && backingMem.capabilitiesFor === void 0 && backingMem.symlinkCount === 0 && caps.remove !== false && caps.recursiveRemove !== false && caps.removeDirectory !== false && !caps.readOnly && Object.getPrototypeOf(backingMem)?.constructor?.name === "MemoryFileSystem" && !Object.prototype.hasOwnProperty.call(backingMem, "lstat") && !Object.prototype.hasOwnProperty.call(backingMem, "stat") && !Object.prototype.hasOwnProperty.call(backingMem, "realpath") && !Object.prototype.hasOwnProperty.call(backingMem, "rm") && !Object.prototype.hasOwnProperty.call(backingMem, "rmdir");
|
|
5001
4461
|
if (fastStockMemory && parsed.operands.length === 1 && !parsed.flags.has("v") && (recursive || !parsed.flags.has("d"))) {
|
|
5002
4462
|
const operand = parsed.operands[0];
|
|
5003
4463
|
const path = pathOf(context, operand);
|
|
@@ -5060,22 +4520,22 @@ function filesystemCommands(maxDirectoryEntries) {
|
|
|
5060
4520
|
throw new FsError("ENOENT", { path });
|
|
5061
4521
|
}
|
|
5062
4522
|
if (stat.type === "directory" && !recursive && !parsed.flags.has("d")) throw new FsError("EISDIR", { path });
|
|
5063
|
-
if (interactive === "always") {
|
|
4523
|
+
if (interactive === "always" || recursiveTraversal) {
|
|
5064
4524
|
const display = escapeText(operand, "display");
|
|
5065
4525
|
if (stat.type === "directory" && recursive) {
|
|
5066
|
-
if (depth >
|
|
4526
|
+
if (depth > maxRecursiveDirectoryDepth) throw new FsError("ELOOP", { path });
|
|
5067
4527
|
const entries = await readDirectory(context, path, true);
|
|
5068
4528
|
if (entries.length) {
|
|
5069
|
-
if (!await confirm(`descend into directory '${display}'`)) return false;
|
|
4529
|
+
if (interactive === "always" && !await confirm(`descend into directory '${display}'`)) return false;
|
|
5070
4530
|
let removed = true;
|
|
5071
4531
|
for (const entry of entries) if (!await remove(childOperand(operand, entry.name), depth + 1)) removed = false;
|
|
5072
4532
|
if (!removed) return false;
|
|
5073
4533
|
}
|
|
5074
4534
|
}
|
|
5075
4535
|
const type = stat.type === "file" ? stat.size === 0 ? "regular empty file" : "regular file" : stat.type === "symlink" ? "symbolic link" : "directory";
|
|
5076
|
-
if (!await confirm(`remove ${type} '${display}'`)) return false;
|
|
4536
|
+
if (interactive === "always" && !await confirm(`remove ${type} '${display}'`)) return false;
|
|
5077
4537
|
}
|
|
5078
|
-
if (stat.type === "directory" && (!recursive ||
|
|
4538
|
+
if (stat.type === "directory" && (!recursive || recursiveTraversal)) {
|
|
5079
4539
|
try {
|
|
5080
4540
|
await removeEmptyDirectory(context, path, readDirectory);
|
|
5081
4541
|
} catch (error) {
|
|
@@ -5479,8 +4939,8 @@ Try 'ls --help' for more information.`);
|
|
|
5479
4939
|
const physical = await context.fs.realpath(path, { signal: context.signal });
|
|
5480
4940
|
if (ancestors.has(physical)) throw new FsError("ELOOP", { path });
|
|
5481
4941
|
context.signal.throwIfAborted();
|
|
5482
|
-
if (ancestors.size >
|
|
5483
|
-
throw new FsError("ELOOP", { path, message: `ls directory depth limit exceeded (${
|
|
4942
|
+
if (ancestors.size > maxRecursiveDirectoryDepth) {
|
|
4943
|
+
throw new FsError("ELOOP", { path, message: `ls directory depth limit exceeded (${maxRecursiveDirectoryDepth})` });
|
|
5484
4944
|
}
|
|
5485
4945
|
ancestors.add(physical);
|
|
5486
4946
|
try {
|
|
@@ -5541,13 +5001,13 @@ Try 'ls --help' for more information.`);
|
|
|
5541
5001
|
}
|
|
5542
5002
|
return result;
|
|
5543
5003
|
})
|
|
5544
|
-
].map((
|
|
5545
|
-
const requirements = filesystemCommandRequirements[
|
|
5546
|
-
return requirements ? { ...
|
|
5004
|
+
].map((command3) => {
|
|
5005
|
+
const requirements = filesystemCommandRequirements[command3.name];
|
|
5006
|
+
return requirements ? { ...command3, filesystemRequirements: requirements } : command3;
|
|
5547
5007
|
});
|
|
5548
|
-
for (const
|
|
5549
|
-
if (
|
|
5550
|
-
else if (
|
|
5008
|
+
for (const command3 of commands) {
|
|
5009
|
+
if (command3.name === "mkdir") defaultMkdirExecutors.add(command3.execute);
|
|
5010
|
+
else if (command3.name === "rm" && maxRecursiveDirectoryDepth === Infinity) defaultRmExecutors.add(command3.execute);
|
|
5551
5011
|
}
|
|
5552
5012
|
return commands;
|
|
5553
5013
|
}
|
|
@@ -8481,9 +7941,9 @@ function predicateCommands(identity = {}) {
|
|
|
8481
7941
|
}
|
|
8482
7942
|
}
|
|
8483
7943
|
return { exitCode: result !== negate ? 0 : 1 };
|
|
8484
|
-
})).map((
|
|
8485
|
-
defaultPredicateExecutors.add(
|
|
8486
|
-
return { ...
|
|
7944
|
+
})).map((command3) => {
|
|
7945
|
+
defaultPredicateExecutors.add(command3.execute);
|
|
7946
|
+
return { ...command3, filesystemRequirements: predicateRequirements };
|
|
8487
7947
|
});
|
|
8488
7948
|
}
|
|
8489
7949
|
|
|
@@ -8763,8 +8223,8 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8763
8223
|
(key, index, offset) => {
|
|
8764
8224
|
if (key === "I") replacementOrigin = { index, offset };
|
|
8765
8225
|
},
|
|
8766
|
-
(key) => {
|
|
8767
|
-
if (key === "I" || key === "L" || key === "n") batching = key;
|
|
8226
|
+
(key, optionValue) => {
|
|
8227
|
+
if (key === "I" || key === "L" || key === "n" && !(batching === "I" && integer(optionValue, 1) === 1)) batching = key;
|
|
8768
8228
|
if (key === "0" || key === "d") lastDelimMode = key;
|
|
8769
8229
|
}
|
|
8770
8230
|
);
|
|
@@ -8783,7 +8243,7 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8783
8243
|
const argumentFile = value(parsed, "a");
|
|
8784
8244
|
const childInput = argumentFile === void 0 ? emptyInput() : context.stdin;
|
|
8785
8245
|
const childInputIsDefault = argumentFile === void 0 ? true : context.stdinIsDefault;
|
|
8786
|
-
const maxArgs = replacement
|
|
8246
|
+
const maxArgs = replacement !== void 0 ? 1 : batching === "n" ? integer(value(parsed, "n"), 1) : Infinity;
|
|
8787
8247
|
const size = value(parsed, "s");
|
|
8788
8248
|
const maxBytes = size === void 0 || size === "Infinity" ? Infinity : integer(size, 1);
|
|
8789
8249
|
let delimiter = parsed.flags.has("0") ? "\0" : void 0;
|
|
@@ -8793,9 +8253,9 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8793
8253
|
if (bytes2.length !== 1 || bytes2[0] > 127) throw new UsageError("delimiter must be one ASCII byte");
|
|
8794
8254
|
if (lastDelimMode === "d") delimiter = String.fromCharCode(bytes2[0]);
|
|
8795
8255
|
}
|
|
8796
|
-
const
|
|
8256
|
+
const command3 = parsed.operands[0] ?? "echo";
|
|
8797
8257
|
const initial = argumentValues.select(operandIndices).slice(1);
|
|
8798
|
-
const baseBytes = encoder.encode(
|
|
8258
|
+
const baseBytes = encoder.encode(command3).length + 1 + initial.values.reduce((sum, argument) => sum + shellValueByteLength(argument) + 1, 0);
|
|
8799
8259
|
if (baseBytes >= maxBytes) throw new UsageError("initial arguments exceed command size limit");
|
|
8800
8260
|
let batch = [];
|
|
8801
8261
|
let bytes = baseBytes;
|
|
@@ -8878,11 +8338,11 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8878
8338
|
};
|
|
8879
8339
|
const dispatch = async () => {
|
|
8880
8340
|
if (stop) return;
|
|
8881
|
-
const childArguments = initial.withValues(replacementPattern === void 0 || parsed.operands.length === 0 ? [...initial.values, ...batch] : await replaceXargsArguments(initial.values, replacementPattern, batch[0] ?? "", maxBytes - encoder.encode(
|
|
8341
|
+
const childArguments = initial.withValues(replacementPattern === void 0 || parsed.operands.length === 0 ? [...initial.values, ...batch] : await replaceXargsArguments(initial.values, replacementPattern, batch[0] ?? "", maxBytes - encoder.encode(command3).length - 1, context.signal));
|
|
8882
8342
|
const args = childArguments.args;
|
|
8883
|
-
const size2 = encoder.encode(
|
|
8343
|
+
const size2 = encoder.encode(command3).length + 1 + childArguments.values.reduce((sum, argument) => sum + shellValueByteLength(argument) + 1, 0);
|
|
8884
8344
|
if (size2 > maxBytes) throw new UsageError("expanded arguments exceed command size limit");
|
|
8885
|
-
if (parsed.flags.has("t")) await writeDiagnostic(context.stderr, [
|
|
8345
|
+
if (parsed.flags.has("t")) await writeDiagnostic(context.stderr, [command3, ...childArguments.values].map(xargsDisplay).join(" ") + "\n", context.signal);
|
|
8886
8346
|
if (stop) return;
|
|
8887
8347
|
context.signal.throwIfAborted();
|
|
8888
8348
|
executed = true;
|
|
@@ -8895,7 +8355,7 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8895
8355
|
const pending = Promise.resolve().then(() => {
|
|
8896
8356
|
childSignal.throwIfAborted();
|
|
8897
8357
|
const env = slotVariable === void 0 ? context.env : { ...context.env, [slotVariable]: String(slot) };
|
|
8898
|
-
if (context.invoke) return context.invoke(
|
|
8358
|
+
if (context.invoke) return context.invoke(command3, args, {
|
|
8899
8359
|
argumentValues: childArguments,
|
|
8900
8360
|
externalInvocation: true,
|
|
8901
8361
|
stdin: childInput,
|
|
@@ -8906,7 +8366,7 @@ function executionCommands(execute, configuration = {}) {
|
|
|
8906
8366
|
stderr: context.stderr,
|
|
8907
8367
|
signal: childSignal
|
|
8908
8368
|
});
|
|
8909
|
-
return execute({ ...context, command:
|
|
8369
|
+
return execute({ ...context, command: command3, args, argumentValues: childArguments, stdin: childInput, ...childInputIsDefault === void 0 ? {} : { stdinIsDefault: childInputIsDefault }, env, signal: childSignal });
|
|
8910
8370
|
}).then((result) => {
|
|
8911
8371
|
const exitCode = result.exitCode;
|
|
8912
8372
|
if (!terminal && (exitCode === 255 || exitCode === 126 || exitCode === 127)) {
|
|
@@ -9247,9 +8707,11 @@ function evalSyncXargs(inBytes, opArgs, readFileSync) {
|
|
|
9247
8707
|
if (a.startsWith("--max-args=")) {
|
|
9248
8708
|
const v = a.slice(11);
|
|
9249
8709
|
if (!/^[1-9][0-9]*$/.test(v)) return void 0;
|
|
9250
|
-
|
|
9251
|
-
|
|
9252
|
-
|
|
8710
|
+
if (replaceStr === void 0 || Number(v) !== 1) {
|
|
8711
|
+
maxArgs = Number(v);
|
|
8712
|
+
replaceStr = void 0;
|
|
8713
|
+
maxLines = void 0;
|
|
8714
|
+
}
|
|
9253
8715
|
i++;
|
|
9254
8716
|
continue;
|
|
9255
8717
|
}
|
|
@@ -9274,9 +8736,11 @@ function evalSyncXargs(inBytes, opArgs, readFileSync) {
|
|
|
9274
8736
|
if (a.startsWith("-n") || a === "--max-args") {
|
|
9275
8737
|
const v = a.startsWith("-n") && a.length > 2 ? a.slice(2) : opArgs[++i];
|
|
9276
8738
|
if (!v || !/^[1-9][0-9]*$/.test(v)) return void 0;
|
|
9277
|
-
|
|
9278
|
-
|
|
9279
|
-
|
|
8739
|
+
if (replaceStr === void 0 || Number(v) !== 1) {
|
|
8740
|
+
maxArgs = Number(v);
|
|
8741
|
+
replaceStr = void 0;
|
|
8742
|
+
maxLines = void 0;
|
|
8743
|
+
}
|
|
9280
8744
|
i++;
|
|
9281
8745
|
continue;
|
|
9282
8746
|
}
|
|
@@ -9329,9 +8793,11 @@ function evalSyncXargs(inBytes, opArgs, readFileSync) {
|
|
|
9329
8793
|
ok = false;
|
|
9330
8794
|
break;
|
|
9331
8795
|
}
|
|
9332
|
-
|
|
9333
|
-
|
|
9334
|
-
|
|
8796
|
+
if (replaceStr === void 0 || Number(v) !== 1) {
|
|
8797
|
+
maxArgs = Number(v);
|
|
8798
|
+
replaceStr = void 0;
|
|
8799
|
+
maxLines = void 0;
|
|
8800
|
+
}
|
|
9335
8801
|
break;
|
|
9336
8802
|
} else if (ch === "L") {
|
|
9337
8803
|
const rest = a.slice(j + 1);
|
|
@@ -9592,7 +9058,7 @@ function evalSyncXargs(inBytes, opArgs, readFileSync) {
|
|
|
9592
9058
|
}
|
|
9593
9059
|
if (batch.length > 0) runEcho(batch);
|
|
9594
9060
|
} else {
|
|
9595
|
-
const limit = maxArgs ??
|
|
9061
|
+
const limit = maxArgs ?? Infinity;
|
|
9596
9062
|
for (let k = 0; k < tokens.length; k += limit) {
|
|
9597
9063
|
runEcho(tokens.slice(k, k + limit));
|
|
9598
9064
|
}
|
|
@@ -9664,10 +9130,6 @@ export {
|
|
|
9664
9130
|
createFmtEngine,
|
|
9665
9131
|
fmtCommand,
|
|
9666
9132
|
parseFmtArguments,
|
|
9667
|
-
createNumfmtCommand,
|
|
9668
|
-
createNumfmtCommands,
|
|
9669
|
-
numfmtCommands,
|
|
9670
|
-
numfmtCommand,
|
|
9671
9133
|
clearRgFastRunnerPool,
|
|
9672
9134
|
createRgCommand,
|
|
9673
9135
|
preverifyMemoryRgTree,
|
|
@@ -9707,10 +9169,6 @@ export {
|
|
|
9707
9169
|
createUnzipCommands,
|
|
9708
9170
|
unzipCommands,
|
|
9709
9171
|
evalSyncUnzip,
|
|
9710
|
-
createStreamInspectionCommands,
|
|
9711
|
-
streamInspectionCommands,
|
|
9712
|
-
createStreamFormatCommands,
|
|
9713
|
-
streamFormatCommands,
|
|
9714
9172
|
evalSyncPrintenv,
|
|
9715
9173
|
evalSyncDate,
|
|
9716
9174
|
createTimeEnvCommands,
|
|
@@ -9736,12 +9194,6 @@ export {
|
|
|
9736
9194
|
createWhichCommands,
|
|
9737
9195
|
evalSyncWhich,
|
|
9738
9196
|
whichCommands,
|
|
9739
|
-
createBcCommand,
|
|
9740
|
-
createBcCommands,
|
|
9741
|
-
bcCommands,
|
|
9742
|
-
createSpongeCommand,
|
|
9743
|
-
createSpongeCommands,
|
|
9744
|
-
spongeCommands,
|
|
9745
9197
|
createFdCommand,
|
|
9746
9198
|
createFdCommands,
|
|
9747
9199
|
fdCommands,
|
|
@@ -9753,30 +9205,6 @@ export {
|
|
|
9753
9205
|
lessCommands,
|
|
9754
9206
|
pagerCommands,
|
|
9755
9207
|
evalSyncLess,
|
|
9756
|
-
createIdCommand,
|
|
9757
|
-
createIdCommands,
|
|
9758
|
-
idCommands,
|
|
9759
|
-
createWhoamiCommand,
|
|
9760
|
-
createWhoamiCommands,
|
|
9761
|
-
whoamiCommands,
|
|
9762
|
-
createUnameCommand,
|
|
9763
|
-
createUnameCommands,
|
|
9764
|
-
unameCommands,
|
|
9765
|
-
createHostnameCommand,
|
|
9766
|
-
createHostnameCommands,
|
|
9767
|
-
hostnameCommands,
|
|
9768
|
-
createNprocCommand,
|
|
9769
|
-
createNprocCommands,
|
|
9770
|
-
nprocCommands,
|
|
9771
|
-
createShufCommand,
|
|
9772
|
-
createShufCommands,
|
|
9773
|
-
shufCommands,
|
|
9774
|
-
createDdCommand,
|
|
9775
|
-
createDdCommands,
|
|
9776
|
-
ddCommands,
|
|
9777
|
-
createEnvsubstCommand,
|
|
9778
|
-
createEnvsubstCommands,
|
|
9779
|
-
envsubstCommands,
|
|
9780
9208
|
evalSyncCal,
|
|
9781
9209
|
createCalCommand,
|
|
9782
9210
|
createNcalCommand,
|
|
@@ -9786,17 +9214,8 @@ export {
|
|
|
9786
9214
|
createPathchkCommands,
|
|
9787
9215
|
pathchkCommands,
|
|
9788
9216
|
evalSyncPathchk,
|
|
9789
|
-
createGetconfCommand,
|
|
9790
|
-
createGetconfCommands,
|
|
9791
|
-
getconfCommands,
|
|
9792
|
-
createLocaleCommand,
|
|
9793
|
-
createLocaleCommands,
|
|
9794
|
-
localeCommands,
|
|
9795
9217
|
createDfCommand,
|
|
9796
9218
|
createDfCommands,
|
|
9797
9219
|
dfCommands,
|
|
9798
|
-
evalSyncDf
|
|
9799
|
-
createSqlite3Command,
|
|
9800
|
-
createSqlite3Commands,
|
|
9801
|
-
sqlite3Commands
|
|
9220
|
+
evalSyncDf
|
|
9802
9221
|
};
|