artideck 0.0.1-alpha.0 → 1.112.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +1 -0
- package/LICENSE +4 -0
- package/README.md +203 -5
- package/bin/ryugi.cjs +9 -0
- package/dist/cli.cjs +994 -0
- package/dist/document-engine.cjs +1796 -0
- package/dist/loro_wasm_bg.wasm +0 -0
- package/dist/output-bootstrap.cjs +921 -0
- package/dist/runtime/Figtree-OFL.txt +93 -0
- package/dist/runtime/Geist-Mono-OFL.txt +92 -0
- package/dist/runtime/Goeist-OFL.txt +97 -0
- package/dist/runtime/deck/23I4SOAX-ByvRw0YV.js +263 -0
- package/dist/runtime/deck/26H2HVXD-bLsHUJg0.js +595 -0
- package/dist/runtime/deck/2IZ5MNOH-BMwid8pT.js +161 -0
- package/dist/runtime/deck/2P3CZEXH-CDGTr1B1.js +263 -0
- package/dist/runtime/deck/3E5HRNYT-DWV6YnPn.js +1328 -0
- package/dist/runtime/deck/3JIRLDUO-BxW79znC.js +489 -0
- package/dist/runtime/deck/5MJ3UKSG-CZlIMh9R.js +470 -0
- package/dist/runtime/deck/5THPTBWS-BCdZFhV1.js +32 -0
- package/dist/runtime/deck/7WLXJQOR-CjURryg_.js +22 -0
- package/dist/runtime/deck/A255FCTW-BsKVHooW.js +796 -0
- package/dist/runtime/deck/AM43MQ64-Ctg0tPg5.js +279 -0
- package/dist/runtime/deck/AOZTNTMC-BFmaehsA.js +563 -0
- package/dist/runtime/deck/AQNLM6KG-BaXA1Iyk.js +1264 -0
- package/dist/runtime/deck/BNU2RHQB-xTFbJFq5.js +181 -0
- package/dist/runtime/deck/C5HTQT3I-gSZhc4E5.js +168 -0
- package/dist/runtime/deck/CPKRWH5G-BWHn4GAl.js +1339 -0
- package/dist/runtime/deck/CUVCMPQX-CWb0Dm80.js +1235 -0
- package/dist/runtime/deck/D4V2MWCI-DU3TsZxx.js +24 -0
- package/dist/runtime/deck/DHKBVIA3-D7oUDJiJ.js +39 -0
- package/dist/runtime/deck/DKTLEL5E-CJdweuKi.js +35 -0
- package/dist/runtime/deck/DUZNPW7S-DbhjhetM.js +103 -0
- package/dist/runtime/deck/E3FWOBN4-BtJPMX8M.js +488 -0
- package/dist/runtime/deck/E65FQMJL-Dd_2fyME.js +21 -0
- package/dist/runtime/deck/FTXIJQGB-AHnjjGOa.js +226 -0
- package/dist/runtime/deck/G3MDBVQH-2qSadYZr.js +24 -0
- package/dist/runtime/deck/G3OATVW2-1h3YkBu7.js +1567 -0
- package/dist/runtime/deck/IV52FOAS-Zn4UzH4N.js +1404 -0
- package/dist/runtime/deck/JTJEEBDN-YkCHY8Zf.js +52 -0
- package/dist/runtime/deck/K7FUICZ3-CGPZ7izx.js +795 -0
- package/dist/runtime/deck/LHH2HHRB-B29BDRKn.js +356 -0
- package/dist/runtime/deck/MSPQPZZY-D8T12kEI.js +688 -0
- package/dist/runtime/deck/OB6ZFVKF-BXfQ4FMH.js +242 -0
- package/dist/runtime/deck/PLTZDMI2-Bt_th5t6.js +1 -0
- package/dist/runtime/deck/R7EPXMMD-Biy1Rh6R.js +1079 -0
- package/dist/runtime/deck/RVARI57O-DHZR7iMv.js +9 -0
- package/dist/runtime/deck/SPBWZ4VS-Ce9sEW6_.js +75 -0
- package/dist/runtime/deck/SR7OOV3Q-DnX0KpAd.js +1017 -0
- package/dist/runtime/deck/STAXBNH4-C4TCtjfh.js +22 -0
- package/dist/runtime/deck/SXFARSFO-DO8JeDyL.js +405 -0
- package/dist/runtime/deck/TC77ISAL-ByLfgcrY.js +1135 -0
- package/dist/runtime/deck/TYIQQHVC-TRfAzv7p.js +1859 -0
- package/dist/runtime/deck/TZUXETIT-B8gqbld-.js +776 -0
- package/dist/runtime/deck/U7N72BGE-BuZ4vKTn.js +519 -0
- package/dist/runtime/deck/UFPIB6EZ-4MlZnCrF.js +475 -0
- package/dist/runtime/deck/UO52YEYL-Bq22hG5W.js +146 -0
- package/dist/runtime/deck/VIK3ONSK-D_kEzfgj.js +445 -0
- package/dist/runtime/deck/VVVO4ZVP-CpABiIqr.js +166 -0
- package/dist/runtime/deck/WRGXZO53-UB13aRTu.js +947 -0
- package/dist/runtime/deck/X5SG7MGC-BfmHie-r.js +296 -0
- package/dist/runtime/deck/XLHPVVFU-B_uzIt_G.js +51 -0
- package/dist/runtime/deck/XXYPNCD5-CgyfByXb.js +183 -0
- package/dist/runtime/deck/Z6WRYFJC-Cxt5GIGU.js +416 -0
- package/dist/runtime/deck/ZI2QNEGF-zbLA5j2H.js +1414 -0
- package/dist/runtime/deck/code-Dzzx958k.js +786 -0
- package/dist/runtime/deck/diagram-D4QtUYG0.js +1095 -0
- package/dist/runtime/deck/embed-ByYr4D5y.js +94 -0
- package/dist/runtime/deck/magic-move-QHEhTESo.js +864 -0
- package/dist/runtime/deck/math-CyFe6hk1.js +21956 -0
- package/dist/runtime/deck/open-BwthTmko.js +788 -0
- package/dist/runtime/icons/a.json +1 -0
- package/dist/runtime/icons/b.json +1 -0
- package/dist/runtime/icons/c.json +1 -0
- package/dist/runtime/icons/d.json +1 -0
- package/dist/runtime/icons/e.json +1 -0
- package/dist/runtime/icons/f.json +1 -0
- package/dist/runtime/icons/g.json +1 -0
- package/dist/runtime/icons/h.json +1 -0
- package/dist/runtime/icons/i.json +1 -0
- package/dist/runtime/icons/index.json +1 -0
- package/dist/runtime/icons/j.json +1 -0
- package/dist/runtime/icons/k.json +1 -0
- package/dist/runtime/icons/l.json +1 -0
- package/dist/runtime/icons/m.json +1 -0
- package/dist/runtime/icons/n.json +1 -0
- package/dist/runtime/icons/o.json +1 -0
- package/dist/runtime/icons/p.json +1 -0
- package/dist/runtime/icons/q.json +1 -0
- package/dist/runtime/icons/r.json +1 -0
- package/dist/runtime/icons/s.json +1 -0
- package/dist/runtime/icons/t.json +1 -0
- package/dist/runtime/icons/u.json +1 -0
- package/dist/runtime/icons/v.json +1 -0
- package/dist/runtime/icons/w.json +1 -0
- package/dist/runtime/icons/x.json +1 -0
- package/dist/runtime/icons/z.json +1 -0
- package/dist/runtime/robots.txt +9 -0
- package/dist/runtime/ryugi-deck.js +4097 -0
- package/dist/runtime/ryugi-icons.js +47 -0
- package/dist/runtime/ryugi-mockup.js +558 -0
- package/dist/runtime/ryugi-preview-bridge.js +2 -0
- package/dist/runtime/ryugi-report.js +65827 -0
- package/dist/runtime/ryugi-storyboard.js +55 -0
- package/dist/runtime/ryugi-ui.js +90 -0
- package/dist/runtime/ryugi-whiteboard-embed.js +11904 -0
- package/dist/viewer/AgentDock-DO3wjCT6.js +2 -0
- package/dist/viewer/ArtboardLayout-CWx1_DVU.js +14 -0
- package/dist/viewer/ArtboardLayout-DLyi-yDq.css +1 -0
- package/dist/viewer/ArtifactList-DtgRku6l.js +2 -0
- package/dist/viewer/ArtifactModal-BU_PR8k8.css +1 -0
- package/dist/viewer/ArtifactModal-DfZqI4AY.js +1 -0
- package/dist/viewer/BottomSheet-DHasPJPu.js +1 -0
- package/dist/viewer/Canvas-C5NJh3wF.js +1 -0
- package/dist/viewer/CommentPopover-GqGMqaHP.js +1 -0
- package/dist/viewer/DocumentExportMenu-8sZID_nO.js +1 -0
- package/dist/viewer/DocumentLayout-CJ59MGXp.js +2 -0
- package/dist/viewer/DocumentPage-CcmkTxH-.js +5 -0
- package/dist/viewer/DocumentPage-DGJI3MRN.css +1 -0
- package/dist/viewer/DotGrid-DKKr_PyM.js +1 -0
- package/dist/viewer/DraggablePanel-BuFi6njZ.js +1 -0
- package/dist/viewer/DropdownMenu-CM7q1CMp.js +1 -0
- package/dist/viewer/Figtree-OFL.txt +93 -0
- package/dist/viewer/Geist-Mono-OFL.txt +92 -0
- package/dist/viewer/GeistMono-BoRIzn25.woff2 +0 -0
- package/dist/viewer/Goeist-OFL.txt +97 -0
- package/dist/viewer/GroupVerdict-DeeQUfkG.js +1 -0
- package/dist/viewer/HtmlLayout-vlPq4J9Y.js +1 -0
- package/dist/viewer/Input-CVcfIqt2.js +1 -0
- package/dist/viewer/KaTeX_AMS-Regular-BQhdFMY1.woff2 +0 -0
- package/dist/viewer/KaTeX_AMS-Regular-DMm9YOAa.woff +0 -0
- package/dist/viewer/KaTeX_AMS-Regular-DRggAlZN.ttf +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Bold-ATXxdsX0.ttf +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Bold-BEiXGLvX.woff +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Bold-Dq_IR9rO.woff2 +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Regular-CTRA-rTL.woff +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Regular-Di6jR-x-.woff2 +0 -0
- package/dist/viewer/KaTeX_Caligraphic-Regular-wX97UBjC.ttf +0 -0
- package/dist/viewer/KaTeX_Fraktur-Bold-BdnERNNW.ttf +0 -0
- package/dist/viewer/KaTeX_Fraktur-Bold-BsDP51OF.woff +0 -0
- package/dist/viewer/KaTeX_Fraktur-Bold-CL6g_b3V.woff2 +0 -0
- package/dist/viewer/KaTeX_Fraktur-Regular-CB_wures.ttf +0 -0
- package/dist/viewer/KaTeX_Fraktur-Regular-CTYiF6lA.woff2 +0 -0
- package/dist/viewer/KaTeX_Fraktur-Regular-Dxdc4cR9.woff +0 -0
- package/dist/viewer/KaTeX_Main-Bold-Cx986IdX.woff2 +0 -0
- package/dist/viewer/KaTeX_Main-Bold-Jm3AIy58.woff +0 -0
- package/dist/viewer/KaTeX_Main-Bold-waoOVXN0.ttf +0 -0
- package/dist/viewer/KaTeX_Main-BoldItalic-DxDJ3AOS.woff2 +0 -0
- package/dist/viewer/KaTeX_Main-BoldItalic-DzxPMmG6.ttf +0 -0
- package/dist/viewer/KaTeX_Main-BoldItalic-SpSLRI95.woff +0 -0
- package/dist/viewer/KaTeX_Main-Italic-3WenGoN9.ttf +0 -0
- package/dist/viewer/KaTeX_Main-Italic-BMLOBm91.woff +0 -0
- package/dist/viewer/KaTeX_Main-Italic-NWA7e6Wa.woff2 +0 -0
- package/dist/viewer/KaTeX_Main-Regular-B22Nviop.woff2 +0 -0
- package/dist/viewer/KaTeX_Main-Regular-Dr94JaBh.woff +0 -0
- package/dist/viewer/KaTeX_Main-Regular-ypZvNtVU.ttf +0 -0
- package/dist/viewer/KaTeX_Math-BoldItalic-B3XSjfu4.ttf +0 -0
- package/dist/viewer/KaTeX_Math-BoldItalic-CZnvNsCZ.woff2 +0 -0
- package/dist/viewer/KaTeX_Math-BoldItalic-iY-2wyZ7.woff +0 -0
- package/dist/viewer/KaTeX_Math-Italic-DA0__PXp.woff +0 -0
- package/dist/viewer/KaTeX_Math-Italic-flOr_0UB.ttf +0 -0
- package/dist/viewer/KaTeX_Math-Italic-t53AETM-.woff2 +0 -0
- package/dist/viewer/KaTeX_SansSerif-Bold-CFMepnvq.ttf +0 -0
- package/dist/viewer/KaTeX_SansSerif-Bold-D1sUS0GD.woff2 +0 -0
- package/dist/viewer/KaTeX_SansSerif-Bold-DbIhKOiC.woff +0 -0
- package/dist/viewer/KaTeX_SansSerif-Italic-C3H0VqGB.woff2 +0 -0
- package/dist/viewer/KaTeX_SansSerif-Italic-DN2j7dab.woff +0 -0
- package/dist/viewer/KaTeX_SansSerif-Italic-YYjJ1zSn.ttf +0 -0
- package/dist/viewer/KaTeX_SansSerif-Regular-BNo7hRIc.ttf +0 -0
- package/dist/viewer/KaTeX_SansSerif-Regular-CS6fqUqJ.woff +0 -0
- package/dist/viewer/KaTeX_SansSerif-Regular-DDBCnlJ7.woff2 +0 -0
- package/dist/viewer/KaTeX_Script-Regular-C5JkGWo-.ttf +0 -0
- package/dist/viewer/KaTeX_Script-Regular-D3wIWfF6.woff2 +0 -0
- package/dist/viewer/KaTeX_Script-Regular-D5yQViql.woff +0 -0
- package/dist/viewer/KaTeX_Size1-Regular-C195tn64.woff +0 -0
- package/dist/viewer/KaTeX_Size1-Regular-Dbsnue_I.ttf +0 -0
- package/dist/viewer/KaTeX_Size1-Regular-mCD8mA8B.woff2 +0 -0
- package/dist/viewer/KaTeX_Size2-Regular-B7gKUWhC.ttf +0 -0
- package/dist/viewer/KaTeX_Size2-Regular-Dy4dx90m.woff2 +0 -0
- package/dist/viewer/KaTeX_Size2-Regular-oD1tc_U0.woff +0 -0
- package/dist/viewer/KaTeX_Size3-Regular-CTq5MqoE.woff +0 -0
- package/dist/viewer/KaTeX_Size3-Regular-DgpXs0kz.ttf +0 -0
- package/dist/viewer/KaTeX_Size4-Regular-BF-4gkZK.woff +0 -0
- package/dist/viewer/KaTeX_Size4-Regular-DWFBv043.ttf +0 -0
- package/dist/viewer/KaTeX_Size4-Regular-Dl5lxZxV.woff2 +0 -0
- package/dist/viewer/KaTeX_Typewriter-Regular-C0xS9mPB.woff +0 -0
- package/dist/viewer/KaTeX_Typewriter-Regular-CO6r4hn1.woff2 +0 -0
- package/dist/viewer/KaTeX_Typewriter-Regular-D3Ib7_Hf.ttf +0 -0
- package/dist/viewer/MenuSubmenuTrigger-BczoxS9k.js +1 -0
- package/dist/viewer/MotionConfigContext-HC2vqcJO.js +1 -0
- package/dist/viewer/PhoneArtboardBar-BK3M_psy.js +1 -0
- package/dist/viewer/PlaybackIcon-D-vfZnSv.js +1 -0
- package/dist/viewer/Popover-O6mMCn1S.js +1 -0
- package/dist/viewer/PreviewArtifactLayout-KGeS-A9y.js +1 -0
- package/dist/viewer/PreviewLayout-C5knCbv-.js +2 -0
- package/dist/viewer/ReportLayout-BD1bNPfi.js +5 -0
- package/dist/viewer/RyugiMark-Dyu4ej9h.js +1 -0
- package/dist/viewer/Segmented-Clhtb1CD.js +1 -0
- package/dist/viewer/SelectScrollUpArrow-CTGOrluu.js +1 -0
- package/dist/viewer/SlidesLayout-8j14xYA-.js +12 -0
- package/dist/viewer/SlidesLayout-Bjds2UXz.css +1 -0
- package/dist/viewer/SnapshotDocument-CnqXgo4y.js +1 -0
- package/dist/viewer/SplitFrame-CQ3lXrch.js +1 -0
- package/dist/viewer/StoryboardLayout-ayS9S6Ff.js +1 -0
- package/dist/viewer/StoryboardRender--NOzkhyN.js +1 -0
- package/dist/viewer/ThreadView-OBDIwTkP.js +1 -0
- package/dist/viewer/Tooltip-DX1QlxEQ.js +1 -0
- package/dist/viewer/VerifyLayout-B9e4RHAZ.css +1 -0
- package/dist/viewer/VerifyLayout-Usn3NkOU.js +1 -0
- package/dist/viewer/VirtualizedEditor-uWe43zaI-C5Sahl_l.js +1 -0
- package/dist/viewer/VirtualizedRenderer-C_d95FXi-BpaHPQz0.js +1 -0
- package/dist/viewer/WarningsBadge-DGnz2zmy.js +1 -0
- package/dist/viewer/WhiteboardEditor-DrHOvXez-JWa5PVHK.js +22 -0
- package/dist/viewer/WhiteboardLayout-Dd8Uh61C.js +4 -0
- package/dist/viewer/WhiteboardLayout-SRFXrlmW.css +1 -0
- package/dist/viewer/WritingCursor-CRzyzaVO.js +1 -0
- package/dist/viewer/agentLook-CU806djA.js +1 -0
- package/dist/viewer/apl-gfMMiTNf.js +1 -0
- package/dist/viewer/app-icon-6WJOuhLx.svg +1 -0
- package/dist/viewer/app-icon-Bm9-i4yr.png +0 -0
- package/dist/viewer/arrow-up-right-0KreI6kY.js +1 -0
- package/dist/viewer/artifact-list-B9KTDzUh.js +1 -0
- package/dist/viewer/asciiarmor-C_eisQCp.js +1 -0
- package/dist/viewer/asn1-DCl_8MCW.js +1 -0
- package/dist/viewer/asterisk-BEn0Cwpx.js +1 -0
- package/dist/viewer/auto-publish-GJrN3H-Y.js +1 -0
- package/dist/viewer/backlinks-C_k8-LL2.js +1 -0
- package/dist/viewer/bem-vbke-3KC.js +1 -0
- package/dist/viewer/brainfuck-D5EjA2JK.js +1 -0
- package/dist/viewer/channel-CF9EHtSL.js +4 -0
- package/dist/viewer/chevron-left-C5itNrp5.js +1 -0
- package/dist/viewer/chevron-right-xNdXLJg6.js +1 -0
- package/dist/viewer/clapperboard-BfpJ7tpa.js +1 -0
- package/dist/viewer/clike-xvONpD0Z.js +1 -0
- package/dist/viewer/clojure-BflJGmDX.js +1 -0
- package/dist/viewer/cloud-upload-D8TpApTr.js +1 -0
- package/dist/viewer/cmake-84nbDH0I.js +1 -0
- package/dist/viewer/cobol-DHLQUbN7.js +1 -0
- package/dist/viewer/code-DnmQyGiF.js +1 -0
- package/dist/viewer/code-xml-c9QCqmhY.js +1 -0
- package/dist/viewer/coffeescript-De_zI4J0.js +1 -0
- package/dist/viewer/comments-DUAz1Q9X.js +1 -0
- package/dist/viewer/commonlisp-DgAKBe0r.js +1 -0
- package/dist/viewer/crop-encode-C1SdKlik.js +1 -0
- package/dist/viewer/crystal-Bl6YKCG_.js +1 -0
- package/dist/viewer/css-CnaYoQib.js +1 -0
- package/dist/viewer/cssVar.stylex-CGbpAC1Y.js +1 -0
- package/dist/viewer/cypher-p9eYesGn.js +1 -0
- package/dist/viewer/d-DWkQyNnU.js +1 -0
- package/dist/viewer/default-Ckb1jcnl.js +4 -0
- package/dist/viewer/diff-ChtP43wD.js +1 -0
- package/dist/viewer/dist-B0qXxOuX.js +1 -0
- package/dist/viewer/dist-B3-vnt93.js +1 -0
- package/dist/viewer/dist-BDGp5lli.js +6 -0
- package/dist/viewer/dist-BHga6o7i.js +1 -0
- package/dist/viewer/dist-BNB-dtd1.js +1 -0
- package/dist/viewer/dist-BWDri6GH.js +1 -0
- package/dist/viewer/dist-B_dCTH8c.js +9 -0
- package/dist/viewer/dist-BaGZx4vf.js +1 -0
- package/dist/viewer/dist-Bgia1wnJ.js +11 -0
- package/dist/viewer/dist-C4H1ECie.js +1 -0
- package/dist/viewer/dist-CJucIoCR.js +1 -0
- package/dist/viewer/dist-CiMWQRhQ.js +1 -0
- package/dist/viewer/dist-Cj74Rdec.js +1 -0
- package/dist/viewer/dist-CsBIrCGx.js +1 -0
- package/dist/viewer/dist-CyHqzrxc.js +1 -0
- package/dist/viewer/dist-CzD--XrY.js +1 -0
- package/dist/viewer/dist-D4as0PD-.js +1 -0
- package/dist/viewer/dist-DTD3yXBi.js +1 -0
- package/dist/viewer/dist-Dfck1z2n.js +23 -0
- package/dist/viewer/dist-Dmr_aVAS.js +1 -0
- package/dist/viewer/dist-Dn_o36dG.js +2 -0
- package/dist/viewer/dist-DxngwfWH.js +1 -0
- package/dist/viewer/dist-_D5xLBBO.js +1 -0
- package/dist/viewer/dist-vsF0cCGK.js +1 -0
- package/dist/viewer/dockerfile-DJkHQgkl.js +1 -0
- package/dist/viewer/dtd-DTF72YNO.js +1 -0
- package/dist/viewer/dylan-S7ucR4pR.js +1 -0
- package/dist/viewer/ebnf-D4c0_ac3.js +1 -0
- package/dist/viewer/ecl-BVIeWmwY.js +1 -0
- package/dist/viewer/editor-DHJQC-c0.js +397 -0
- package/dist/viewer/eiffel-BEjRio4Q.js +1 -0
- package/dist/viewer/elements-CmGVWYag.js +1 -0
- package/dist/viewer/elm-Cshzl8qu.js +1 -0
- package/dist/viewer/embed-src-CmyqZplg.js +1 -0
- package/dist/viewer/erlang-BV0c4Hdn.js +1 -0
- package/dist/viewer/external-link-D382oEvK.js +1 -0
- package/dist/viewer/factor-LKH5gN8L.js +1 -0
- package/dist/viewer/fcl-ClOhbFR7.js +1 -0
- package/dist/viewer/figtree-latin-ext-wght-normal-DCwSJGxG.woff2 +0 -0
- package/dist/viewer/figtree-latin-wght-normal-D_ZTVpCC.woff2 +0 -0
- package/dist/viewer/film-A6SU1RGC.js +1 -0
- package/dist/viewer/fit-BgVy5mbn.js +1 -0
- package/dist/viewer/folder-BViSPo7g.js +1 -0
- package/dist/viewer/forth-D6RzAl64.js +1 -0
- package/dist/viewer/fortran-Bt6PBEDR.js +1 -0
- package/dist/viewer/gas-BHEdbvp9.js +1 -0
- package/dist/viewer/gherkin-oBAE_ms0.js +1 -0
- package/dist/viewer/github-dark-C895GGrm.js +1 -0
- package/dist/viewer/github-light-B4HDwToD.js +1 -0
- package/dist/viewer/groovy-CUrWKPia.js +1 -0
- package/dist/viewer/haskell-BRsoo5mP.js +1 -0
- package/dist/viewer/haxe-DjVOVvNP.js +1 -0
- package/dist/viewer/http-CLVgA2GD.js +1 -0
- package/dist/viewer/icons-BwlHhLMH.js +1 -0
- package/dist/viewer/idl-BUZw3wgd.js +1 -0
- package/dist/viewer/imperative-D1UIq_CR.js +1 -0
- package/dist/viewer/index.css +1 -0
- package/dist/viewer/index.html +75 -0
- package/dist/viewer/index.js +2 -0
- package/dist/viewer/index2.css +1 -0
- package/dist/viewer/index3.css +1 -0
- package/dist/viewer/index4.css +1 -0
- package/dist/viewer/index5.css +6655 -0
- package/dist/viewer/is-html-element-DvgHo_1h.js +1 -0
- package/dist/viewer/javascript-lS2r2ifg.js +1 -0
- package/dist/viewer/jsx-runtime-LKYXHABd.js +1 -0
- package/dist/viewer/julia-CQfgDRfP.js +1 -0
- package/dist/viewer/katex-DuZJ-tFh.js +257 -0
- package/dist/viewer/lib-DJrc3aG3.js +3 -0
- package/dist/viewer/livescript-BXxG0Yva.js +1 -0
- package/dist/viewer/local-CvTEMav_.js +1 -0
- package/dist/viewer/local-split-host-DOfRlsgx.js +1 -0
- package/dist/viewer/lua-DPCEkfD_.js +1 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-100-DLPe7tEt.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-101-d3VsZKWT.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-102-ClzJuLq6.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-103-DuDnQ6K-.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-104-kPGW3Eem.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-105-BzD54h-0.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-106-BQ7fIzlx.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-107-D8tDfFHI.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-108-tGhkpwep.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-109-7SMVSrly.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-110-_uDKrFed.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-111-Bio825RE.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-112-D2ee0i-C.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-113-JPFVDrga.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-114-BcfxYA4w.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-115-B1HeeOsd.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-116-hY12tXpq.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-117-BvuZwmre.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-118-tzvs_H7j.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-119-J2DWuYDN.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-21-pDubCJV5.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-22-ChAPMpqp.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-23-BBx3oNpT.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-24-CYt-Oagk.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-25-Cx3j-ZUv.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-26-B9AfZ3LL.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-27-Bh2s9MNE.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-28-C02JPoKP.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-29-T_tbUGhk.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-30-DMfyNzhz.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-31-DFfdzbkg.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-32-Bs1fz2iW.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-33-cpB96OkZ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-34-BhinPYWX.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-35-D_njRQqA.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-36-DqXlLE3t.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-37-j5LbvMph.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-38-oO4jWdKm.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-39-CabsX4rw.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-4-PatS3YHh.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-40-yrLg3C3e.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-41-DBXmCQhc.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-42-Bqij_UiQ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-43-D3kp0Ntc.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-44-B_BNGvK4.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-45-CZc0cQWs.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-46-CHQX5Kd9.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-47-Ci8gLrHA.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-48-run3ugD3.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-49-DgfiUb6u.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-5-B0CtGbX_.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-50-CdCG-POr.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-51-L2okeQZ2.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-52-BZAqyGJW.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-53-B0xWqLeU.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-54-BZVQX-EA.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-55-093mkIUJ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-56-CbhWG8G-.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-57-pLQuvo6c.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-58-BHhoY50x.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-59-D1_6DuIQ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-6-BnAelmYU.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-60-HDBIuLTZ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-61-C-c13SeU.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-62-kHRVOhZ2.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-63-C0MCsvFv.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-64-DZekguCj.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-65-CtP6c3IU.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-66-DLVWoMSf.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-67-BVuOnayH.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-68-DpxQ6Mnx.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-69-qesBxLmC.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-70-BBt1xN7h.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-71-BWqZacwB.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-72-B1wP_Yst.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-73-C99T7jNZ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-74-DrUTsWBe.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-75-C4M5XXQe.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-76-Bq8spVWF.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-77-D9vNupE2.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-78-D6th7Gnu.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-79-bezM85cS.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-80-DD8pnhG2.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-81-N6jtSyBs.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-82-D6c180bZ.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-83-em17AadM.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-84-CJ8gdrMK.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-85-9PPGO1eB.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-86-CjWPf-u5.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-87-8D_X_yOC.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-88-9vtKFPBx.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-89-BhE5jAKX.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-90-D2Npfm5E.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-91-C6Ft1-Eu.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-97-CaExyQP9.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-98-CPoVbsUd.woff2 +0 -0
- package/dist/viewer/lxgwwenkaiscreen-subset-99-ZUQZGVgH.woff2 +0 -0
- package/dist/viewer/mathematica-u8YMmbU0.js +1 -0
- package/dist/viewer/maximize-2-Bc0lXBg6.js +1 -0
- package/dist/viewer/mbox-BEMVcqjs.js +1 -0
- package/dist/viewer/message-square-Yl8PoPy_.js +1 -0
- package/dist/viewer/mirc-C9zpzAZU.js +1 -0
- package/dist/viewer/mllike-B45xgp2S.js +1 -0
- package/dist/viewer/modelica-CqHI_q-D.js +1 -0
- package/dist/viewer/monitor-DRrnx_H5.js +1 -0
- package/dist/viewer/motion-Cy65kd7X.js +1 -0
- package/dist/viewer/mouse-pointer-2-B-OF_fcG.js +1 -0
- package/dist/viewer/mscgen-qgSLujhx.js +1 -0
- package/dist/viewer/mumps-BSzj6Xyz.js +1 -0
- package/dist/viewer/nginx-C-ORUuei.js +1 -0
- package/dist/viewer/nsis-viPvXFiq.js +1 -0
- package/dist/viewer/ntriples-CzMBulkp.js +1 -0
- package/dist/viewer/octave-D2Q8cUp1.js +1 -0
- package/dist/viewer/oz-BwTct_5T.js +1 -0
- package/dist/viewer/pages-DWkRbog-.js +1 -0
- package/dist/viewer/pascal-Dp_KdFgX.js +1 -0
- package/dist/viewer/pen-tool-BfwjhXQW.js +1 -0
- package/dist/viewer/perl-BkSkiI9m.js +1 -0
- package/dist/viewer/pig-AF4Hwhju.js +1 -0
- package/dist/viewer/play-6FAfeM1L.js +1 -0
- package/dist/viewer/plugin-_bGVeqI0-DZgj9wju.js +2 -0
- package/dist/viewer/plus-DZJ2BVkK.js +1 -0
- package/dist/viewer/powershell-D8WpQPaX.js +1 -0
- package/dist/viewer/preference-oNdcNeml.js +1 -0
- package/dist/viewer/presentation-DXrcAbwM.js +1 -0
- package/dist/viewer/preview.html +28 -0
- package/dist/viewer/preview.js +1 -0
- package/dist/viewer/printDocument-CUNshxwb.js +1 -0
- package/dist/viewer/properties-C357ku5U.js +1 -0
- package/dist/viewer/protobuf-D1ij_kNL.js +1 -0
- package/dist/viewer/pug-BqCHZ5xT.js +1 -0
- package/dist/viewer/puppet-BZyAS7I4.js +1 -0
- package/dist/viewer/python-B_1Jd8HM.js +1 -0
- package/dist/viewer/q-B9NhS7L_.js +1 -0
- package/dist/viewer/r-CxDmU1I4.js +1 -0
- package/dist/viewer/react-DlmbjZJV.js +1 -0
- package/dist/viewer/read-marks-CVVWpIvf.js +1 -0
- package/dist/viewer/ref-Bj5JiHki.js +1 -0
- package/dist/viewer/robots.txt +9 -0
- package/dist/viewer/rolldown-runtime-XKyaHtl9.js +1 -0
- package/dist/viewer/rounds-BLj-tfMG.js +1 -0
- package/dist/viewer/route-Csi4PU7w.js +64 -0
- package/dist/viewer/route-messages-DeWSMVNI.js +1 -0
- package/dist/viewer/rpm-gpDK5sbt.js +1 -0
- package/dist/viewer/ruby-ChfNwlCY.js +1 -0
- package/dist/viewer/ruler-CYb0HZGT.js +1 -0
- package/dist/viewer/sas-C2OyD2Y6.js +1 -0
- package/dist/viewer/scheme-D9qYN0V5.js +1 -0
- package/dist/viewer/search-DTrfkTpJ.js +1 -0
- package/dist/viewer/selection-BWCQd_Fn.js +1 -0
- package/dist/viewer/settings-Ccw15Eyz.js +1 -0
- package/dist/viewer/shell-DwuoZtxw.js +1 -0
- package/dist/viewer/shims-s-YVfIlz.js +1 -0
- package/dist/viewer/sieve-tLWDfEkZ.js +1 -0
- package/dist/viewer/simple-mode-DXiLM1-G.js +1 -0
- package/dist/viewer/sliders-horizontal-CuS3-UwA.js +1 -0
- package/dist/viewer/smalltalk-BLp5-jwC.js +1 -0
- package/dist/viewer/snap-B7T8Fi-t.js +1 -0
- package/dist/viewer/solr-B78wSQJQ.js +1 -0
- package/dist/viewer/sparql-Dz-mlCAC.js +1 -0
- package/dist/viewer/split-DYwwKqIa.js +2 -0
- package/dist/viewer/spreadsheet-CTIncYxj.js +1 -0
- package/dist/viewer/sql-DuQMFDvy.js +1 -0
- package/dist/viewer/stable-CwENW2fR.js +1 -0
- package/dist/viewer/stex-DNzd62Q_.js +1 -0
- package/dist/viewer/store-D3ROW536.js +1 -0
- package/dist/viewer/stringifyLocale-D0juOOnH.js +1 -0
- package/dist/viewer/styles-clvPUBbJ.js +1 -0
- package/dist/viewer/stylus-BOVgKnng.js +1 -0
- package/dist/viewer/swift-DKB6_1j6.js +1 -0
- package/dist/viewer/table-2-D90vZ04E.js +1 -0
- package/dist/viewer/tcl-BGfruO1u.js +1 -0
- package/dist/viewer/text-align-start-CRhecbJR.js +1 -0
- package/dist/viewer/textile-C4jVoHG1.js +1 -0
- package/dist/viewer/tiddlywiki-VlUiK86J.js +1 -0
- package/dist/viewer/tiki-CvUEFusT.js +1 -0
- package/dist/viewer/toml-BPTmHmyx.js +1 -0
- package/dist/viewer/transport-CSbo3sV6.js +1 -0
- package/dist/viewer/troff-C2dAgh7P.js +1 -0
- package/dist/viewer/ttcn-PPSTk1ow.js +1 -0
- package/dist/viewer/ttcn-cfg-2b4Gb5sE.js +1 -0
- package/dist/viewer/turtle-Cx3rYX2g.js +1 -0
- package/dist/viewer/type-icons-CxYXZlMj.js +1 -0
- package/dist/viewer/types-BCsOeYI6.js +1 -0
- package/dist/viewer/underline-CT_nGhA9.js +1 -0
- package/dist/viewer/undo-2-B-JiyKIl.js +1 -0
- package/dist/viewer/upload-DffL3XsM.js +1 -0
- package/dist/viewer/url-D8qiZRqE.js +29 -0
- package/dist/viewer/useArtifactFeed-1e4jVUAL.js +1 -0
- package/dist/viewer/useArtifactSocket-wqYKSfgz.js +1 -0
- package/dist/viewer/useAssetBase-4Ut9QhBI.js +1 -0
- package/dist/viewer/useLayerZIndex-D4jsmz12.js +1 -0
- package/dist/viewer/useMedia-CFebB4XU.js +1 -0
- package/dist/viewer/useSandboxFrame-CJmSnwgG.js +1 -0
- package/dist/viewer/useStoryboardData-aWqqHGVH.js +1 -0
- package/dist/viewer/useTypeFavicon-yXOsFZBx.js +1 -0
- package/dist/viewer/vb-BthdM_4N.js +1 -0
- package/dist/viewer/vbscript-D9f6rSsU.js +1 -0
- package/dist/viewer/velocity-CqftRsjg.js +1 -0
- package/dist/viewer/verilog-CjI9Y6RI.js +1 -0
- package/dist/viewer/vhdl-kS471soi.js +1 -0
- package/dist/viewer/video-DKoRqEZW.js +1 -0
- package/dist/viewer/view-ClWzCAjM.js +3 -0
- package/dist/viewer/viewport-CFJHn_Y6--n1vZkKz.js +1 -0
- package/dist/viewer/webidl-D5jiJvOU.js +1 -0
- package/dist/viewer/xquery-BKJx4mf9.js +1 -0
- package/dist/viewer/yacas-CXXgtw0p.js +1 -0
- package/dist/viewer/z80-Co3PbHdE.js +1 -0
- package/dist/viewer/zoom-out-DsmGFv1v.js +1 -0
- package/package.json +124 -19
|
@@ -0,0 +1,921 @@
|
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
// \0rolldown/runtime.js
|
|
3
|
+
var __create = Object.create;
|
|
4
|
+
var __defProp = Object.defineProperty;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i = 0, n = keys.length, key; i < n; i++) {
|
|
11
|
+
key = keys[i];
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
|
+
get: ((k) => from[k]).bind(null, key),
|
|
14
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", {
|
|
20
|
+
value: mod,
|
|
21
|
+
enumerable: true
|
|
22
|
+
}) : target, mod));
|
|
23
|
+
let node_fs = require("node:fs");
|
|
24
|
+
node_fs = __toESM(node_fs, 1);
|
|
25
|
+
let node_os = require("node:os");
|
|
26
|
+
node_os = __toESM(node_os, 1);
|
|
27
|
+
let node_path = require("node:path");
|
|
28
|
+
node_path = __toESM(node_path, 1);
|
|
29
|
+
// ../shared/src/types.ts
|
|
30
|
+
const ARTIFACT_TYPES = [
|
|
31
|
+
"artboard",
|
|
32
|
+
"document",
|
|
33
|
+
"html",
|
|
34
|
+
"whiteboard",
|
|
35
|
+
"verify",
|
|
36
|
+
"slides",
|
|
37
|
+
"report",
|
|
38
|
+
"storyboard"
|
|
39
|
+
];
|
|
40
|
+
// ../shared/src/validate.ts
|
|
41
|
+
const BOARD_NUMBERS = [
|
|
42
|
+
"x",
|
|
43
|
+
"y",
|
|
44
|
+
"w",
|
|
45
|
+
"h"
|
|
46
|
+
];
|
|
47
|
+
[...BOARD_NUMBERS];
|
|
48
|
+
[...BOARD_NUMBERS];
|
|
49
|
+
// src/core/server/cloud/credentials.ts
|
|
50
|
+
function credentialsFile(env, platform, home) {
|
|
51
|
+
if (platform === "win32" && env.APPDATA) return node_path.default.join(env.APPDATA, "ryugi", "credentials.json");
|
|
52
|
+
return node_path.default.join(env.XDG_CONFIG_HOME || node_path.default.join(home, ".config"), "ryugi", "credentials.json");
|
|
53
|
+
}
|
|
54
|
+
// src/core/server/cloud/settings.ts
|
|
55
|
+
const settingsFileFor = (credentialsFile) => node_path.default.join(node_path.default.dirname(credentialsFile), "config.json");
|
|
56
|
+
// src/core/cli/kit/paths.ts
|
|
57
|
+
var CliError = class extends Error {
|
|
58
|
+
fields;
|
|
59
|
+
code;
|
|
60
|
+
constructor(message, fields = {}, code = 1) {
|
|
61
|
+
super(message);
|
|
62
|
+
this.fields = fields;
|
|
63
|
+
this.code = code;
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
function projectRoot(dir) {
|
|
67
|
+
let home = "";
|
|
68
|
+
try {
|
|
69
|
+
home = node_fs.default.realpathSync(node_os.default.homedir());
|
|
70
|
+
} catch {}
|
|
71
|
+
const chain = [];
|
|
72
|
+
for (let current = dir;; current = node_path.default.dirname(current)) {
|
|
73
|
+
chain.push(current);
|
|
74
|
+
if (node_fs.default.existsSync(node_path.default.join(current, ".git")) && (current !== home || dir === home)) break;
|
|
75
|
+
if (node_path.default.dirname(current) === current) return dir;
|
|
76
|
+
}
|
|
77
|
+
return chain.find((candidate) => node_fs.default.existsSync(node_path.default.join(candidate, ".ryugi", "artifacts"))) ?? chain.at(-1);
|
|
78
|
+
}
|
|
79
|
+
function projectPaths(dir) {
|
|
80
|
+
let project;
|
|
81
|
+
try {
|
|
82
|
+
project = node_fs.default.realpathSync(node_path.default.resolve(dir));
|
|
83
|
+
if (!node_fs.default.statSync(project).isDirectory()) throw new Error("Not a directory");
|
|
84
|
+
} catch {
|
|
85
|
+
throw new CliError(`Project directory not found: ${dir}`);
|
|
86
|
+
}
|
|
87
|
+
project = projectRoot(project);
|
|
88
|
+
const root = node_path.default.join(project, ".ryugi", "artifacts");
|
|
89
|
+
const state = node_path.default.join(root, ".state");
|
|
90
|
+
return {
|
|
91
|
+
project,
|
|
92
|
+
root,
|
|
93
|
+
state,
|
|
94
|
+
pid: node_path.default.join(state, "server.pid"),
|
|
95
|
+
log: node_path.default.join(state, "server.log"),
|
|
96
|
+
serverId: node_path.default.join(state, "server-instance-id"),
|
|
97
|
+
info: node_path.default.join(state, "server-info"),
|
|
98
|
+
version: node_path.default.join(state, "server-version"),
|
|
99
|
+
owners: node_path.default.join(state, "owners"),
|
|
100
|
+
stopped: node_path.default.join(state, "server-stopped"),
|
|
101
|
+
lock: node_path.default.join(state, "start.lock")
|
|
102
|
+
};
|
|
103
|
+
}
|
|
104
|
+
new RegExp(`^(${ARTIFACT_TYPES.join("|")})/[a-z0-9][a-z0-9-]*$`);
|
|
105
|
+
`${ARTIFACT_TYPES.slice(0, -1).join(", ")}${ARTIFACT_TYPES.at(-1)}`;
|
|
106
|
+
// src/core/cli/output/normalize.ts
|
|
107
|
+
var OutputError = class extends Error {
|
|
108
|
+
error;
|
|
109
|
+
kind;
|
|
110
|
+
raw;
|
|
111
|
+
constructor(error, kind = "failed", raw) {
|
|
112
|
+
super(error.message);
|
|
113
|
+
this.error = error;
|
|
114
|
+
this.kind = kind;
|
|
115
|
+
this.raw = raw;
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
function completionState(completion, warning = false) {
|
|
119
|
+
switch (completion.kind) {
|
|
120
|
+
case "succeeded": return {
|
|
121
|
+
outcome: warning ? "attention" : "success",
|
|
122
|
+
code: 0
|
|
123
|
+
};
|
|
124
|
+
case "validation_failed": return {
|
|
125
|
+
outcome: "attention",
|
|
126
|
+
code: 3
|
|
127
|
+
};
|
|
128
|
+
case "pending": return {
|
|
129
|
+
outcome: "pending",
|
|
130
|
+
code: 4
|
|
131
|
+
};
|
|
132
|
+
case "action_required": return {
|
|
133
|
+
outcome: "attention",
|
|
134
|
+
code: 2
|
|
135
|
+
};
|
|
136
|
+
case "partial": return {
|
|
137
|
+
outcome: "partial",
|
|
138
|
+
code: 5
|
|
139
|
+
};
|
|
140
|
+
case "failed": return {
|
|
141
|
+
outcome: "error",
|
|
142
|
+
code: 1
|
|
143
|
+
};
|
|
144
|
+
case "interrupted": return {
|
|
145
|
+
outcome: "error",
|
|
146
|
+
code: completion.signal === "SIGINT" ? 130 : 143
|
|
147
|
+
};
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
function project(value, keys, path, omitted) {
|
|
151
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) return value;
|
|
152
|
+
return Object.fromEntries(Object.entries(value).filter(([key]) => {
|
|
153
|
+
if (keys.includes(key)) return true;
|
|
154
|
+
omitted.push({
|
|
155
|
+
path: `${path}.${key}`,
|
|
156
|
+
reason: "fields"
|
|
157
|
+
});
|
|
158
|
+
return false;
|
|
159
|
+
}));
|
|
160
|
+
}
|
|
161
|
+
function normalize(command, result, options, policy) {
|
|
162
|
+
const omitted = [...result.coverage.omitted ?? []];
|
|
163
|
+
let data = result.data;
|
|
164
|
+
if (options.fields) {
|
|
165
|
+
const keys = [.../* @__PURE__ */ new Set([...options.fields, ...policy.requiredFields ?? []])];
|
|
166
|
+
if (policy.collection && data && typeof data === "object") {
|
|
167
|
+
const record = data;
|
|
168
|
+
const rows = record[policy.collection];
|
|
169
|
+
data = {
|
|
170
|
+
...record,
|
|
171
|
+
[policy.collection]: Array.isArray(rows) ? rows.map((row, i) => project(row, keys, `data.${policy.collection}.${i}`, omitted)) : rows
|
|
172
|
+
};
|
|
173
|
+
} else data = project(data, keys, "data", omitted);
|
|
174
|
+
}
|
|
175
|
+
return {
|
|
176
|
+
schema: "ryugi.cli/v1",
|
|
177
|
+
command,
|
|
178
|
+
outcome: completionState(result.completion, result.warnings.length > 0).outcome,
|
|
179
|
+
data,
|
|
180
|
+
...result.coverage.page ? { page: result.coverage.page } : {},
|
|
181
|
+
...omitted.length ? { omitted } : {},
|
|
182
|
+
...result.effects.length ? { effects: result.effects } : {},
|
|
183
|
+
...result.warnings.length ? { warnings: result.warnings } : {},
|
|
184
|
+
...result.actions.length ? { next: result.actions } : {},
|
|
185
|
+
...result.completion.kind === "failed" ? { error: result.completion.error } : result.completion.kind === "interrupted" ? { error: {
|
|
186
|
+
code: "E_INTERRUPTED",
|
|
187
|
+
message: `Command interrupted by ${result.completion.signal}.`,
|
|
188
|
+
details: { signal: result.completion.signal }
|
|
189
|
+
} } : {}
|
|
190
|
+
};
|
|
191
|
+
}
|
|
192
|
+
// src/core/cli/output/planning.ts
|
|
193
|
+
function scanOptions(argv, optionSpecs) {
|
|
194
|
+
const values = {};
|
|
195
|
+
for (let i = 0; i < argv.length; i++) {
|
|
196
|
+
const token = argv[i];
|
|
197
|
+
if (token === "--") break;
|
|
198
|
+
if (!token.startsWith("--")) continue;
|
|
199
|
+
const equal = token.indexOf("=");
|
|
200
|
+
const name = token.slice(2, equal < 0 ? void 0 : equal);
|
|
201
|
+
const type = name === "source" ? "boolean" : optionSpecs[name]?.type;
|
|
202
|
+
if (type === "string") values[name] = equal < 0 ? argv[++i] ?? "" : token.slice(equal + 1);
|
|
203
|
+
else if (type === "boolean") values[name] = true;
|
|
204
|
+
}
|
|
205
|
+
return values;
|
|
206
|
+
}
|
|
207
|
+
function selectOutput(argv, optionSpecs, env = process.env) {
|
|
208
|
+
const values = scanOptions(argv, optionSpecs);
|
|
209
|
+
const explicit = [
|
|
210
|
+
"format",
|
|
211
|
+
"json",
|
|
212
|
+
"quiet",
|
|
213
|
+
"source"
|
|
214
|
+
].filter((key) => values[key] !== void 0);
|
|
215
|
+
const configured = env.RYUGI_ARTIFACTS_FORMAT ?? "brief";
|
|
216
|
+
const requested = values.format ?? (values.json ? "json" : values.quiet ? "quiet" : values.source ? "source" : configured);
|
|
217
|
+
const valid = [
|
|
218
|
+
"brief",
|
|
219
|
+
"table",
|
|
220
|
+
"json",
|
|
221
|
+
"jsonl",
|
|
222
|
+
"raw",
|
|
223
|
+
"source",
|
|
224
|
+
"quiet"
|
|
225
|
+
].includes(requested);
|
|
226
|
+
const options = {
|
|
227
|
+
format: valid ? requested : "brief",
|
|
228
|
+
detail: !!values.detail || !!values.source,
|
|
229
|
+
verbose: !!values.verbose
|
|
230
|
+
};
|
|
231
|
+
let error;
|
|
232
|
+
if (explicit.length > 1) error = new OutputError({
|
|
233
|
+
code: "E_OPTION_CONFLICT",
|
|
234
|
+
message: "Choose one of --format, --json, --quiet or --source."
|
|
235
|
+
});
|
|
236
|
+
else if (!valid || !explicit.length && ![
|
|
237
|
+
"brief",
|
|
238
|
+
"json",
|
|
239
|
+
"jsonl"
|
|
240
|
+
].includes(configured)) error = new OutputError({
|
|
241
|
+
code: "E_FORMAT_UNSUPPORTED",
|
|
242
|
+
message: `Unknown output format: ${String(requested)}`
|
|
243
|
+
});
|
|
244
|
+
if (typeof values.fields === "string") {
|
|
245
|
+
options.fields = values.fields.split(",").map((field) => field.trim());
|
|
246
|
+
if (options.fields.some((field) => !field)) error = new OutputError({
|
|
247
|
+
code: "E_ARGUMENT_INVALID",
|
|
248
|
+
message: "--fields requires comma-separated field names."
|
|
249
|
+
});
|
|
250
|
+
}
|
|
251
|
+
return {
|
|
252
|
+
options,
|
|
253
|
+
...error ? { error } : {}
|
|
254
|
+
};
|
|
255
|
+
}
|
|
256
|
+
// src/core/cli/output/configuration.ts
|
|
257
|
+
const PERSISTED_FORMATS = [
|
|
258
|
+
"brief",
|
|
259
|
+
"json",
|
|
260
|
+
"jsonl"
|
|
261
|
+
];
|
|
262
|
+
function outputFiles(projectDir) {
|
|
263
|
+
return {
|
|
264
|
+
global: settingsFileFor(credentialsFile(process.env, process.platform, node_os.default.homedir())),
|
|
265
|
+
project: node_path.default.join(node_path.default.dirname(projectPaths(projectDir).root), "config.json")
|
|
266
|
+
};
|
|
267
|
+
}
|
|
268
|
+
function read(file) {
|
|
269
|
+
try {
|
|
270
|
+
const raw = JSON.parse(node_fs.default.readFileSync(file, "utf8"));
|
|
271
|
+
if (!raw || typeof raw !== "object" || Array.isArray(raw)) throw new Error("Expected an object");
|
|
272
|
+
return raw;
|
|
273
|
+
} catch (error) {
|
|
274
|
+
if (error.code === "ENOENT") return {};
|
|
275
|
+
throw new OutputError({
|
|
276
|
+
code: "E_CONFIG_INVALID",
|
|
277
|
+
message: `Cannot read ${file}: ${error.message}`
|
|
278
|
+
});
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
function outputValues(projectDir) {
|
|
282
|
+
const files = outputFiles(projectDir);
|
|
283
|
+
const get = (file) => {
|
|
284
|
+
const output = read(file).output;
|
|
285
|
+
if (output?.format !== void 0 && !PERSISTED_FORMATS.includes(output.format)) throw new OutputError({
|
|
286
|
+
code: "E_FORMAT_UNSUPPORTED",
|
|
287
|
+
message: `Unsupported output format in ${file}: ${String(output.format)}`
|
|
288
|
+
});
|
|
289
|
+
return output && PERSISTED_FORMATS.includes(output.format) ? output.format : null;
|
|
290
|
+
};
|
|
291
|
+
const global = get(files.global), project = get(files.project);
|
|
292
|
+
return {
|
|
293
|
+
global,
|
|
294
|
+
project,
|
|
295
|
+
effective: project ?? global ?? "brief",
|
|
296
|
+
source: project ? "project" : global ? "global" : "default"
|
|
297
|
+
};
|
|
298
|
+
}
|
|
299
|
+
function configuredEnvironment(argv, specs, env = process.env) {
|
|
300
|
+
if (env.RYUGI_ARTIFACTS_FORMAT !== void 0) return env;
|
|
301
|
+
const values = scanOptions(argv, specs);
|
|
302
|
+
if ([
|
|
303
|
+
"format",
|
|
304
|
+
"json",
|
|
305
|
+
"quiet",
|
|
306
|
+
"source"
|
|
307
|
+
].some((key) => values[key] !== void 0)) return env;
|
|
308
|
+
let project = typeof values["project-dir"] === "string" ? values["project-dir"] : process.cwd();
|
|
309
|
+
if (!values["project-dir"] && argv[0] && !argv[0].startsWith("-")) try {
|
|
310
|
+
if (node_fs.default.statSync(argv[0]).isDirectory()) project = argv[0];
|
|
311
|
+
} catch {}
|
|
312
|
+
const config = outputValues(project);
|
|
313
|
+
return {
|
|
314
|
+
...env,
|
|
315
|
+
RYUGI_ARTIFACTS_FORMAT: config.effective
|
|
316
|
+
};
|
|
317
|
+
}
|
|
318
|
+
// src/core/cli/output/protocol.ts
|
|
319
|
+
function result(data, completion = { kind: "succeeded" }, extra = {}) {
|
|
320
|
+
return {
|
|
321
|
+
data,
|
|
322
|
+
completion,
|
|
323
|
+
coverage: {},
|
|
324
|
+
effects: [],
|
|
325
|
+
warnings: [],
|
|
326
|
+
actions: [],
|
|
327
|
+
...extra
|
|
328
|
+
};
|
|
329
|
+
}
|
|
330
|
+
// src/core/cli/output/time.ts
|
|
331
|
+
const ISO = /^\d{4}-\d\d-\d\dT\d\d:\d\d(?::\d\d(?:\.\d+)?)?(?:Z|[+-]\d\d:?\d\d)$/;
|
|
332
|
+
const two = (n) => String(n).padStart(2, "0");
|
|
333
|
+
const isIsoTime = (value) => typeof value === "string" && ISO.test(value) && !Number.isNaN(Date.parse(value));
|
|
334
|
+
function formatTime(iso, now = /* @__PURE__ */ new Date()) {
|
|
335
|
+
const at = new Date(iso);
|
|
336
|
+
if (Number.isNaN(at.getTime())) return iso;
|
|
337
|
+
const clock = `${two(at.getHours())}:${two(at.getMinutes())}`;
|
|
338
|
+
if (at.getFullYear() !== now.getFullYear()) return `${at.getFullYear()}-${two(at.getMonth() + 1)}-${two(at.getDate())}`;
|
|
339
|
+
if (at.getMonth() === now.getMonth() && at.getDate() === now.getDate()) return clock;
|
|
340
|
+
return `${two(at.getMonth() + 1)}-${two(at.getDate())} ${clock}`;
|
|
341
|
+
}
|
|
342
|
+
// src/core/cli/output/view.ts
|
|
343
|
+
function recoveryActions(error, subject) {
|
|
344
|
+
const details = error.details;
|
|
345
|
+
if (!details || typeof details !== "object" || Array.isArray(details)) return [];
|
|
346
|
+
return Object.entries(details).flatMap(([key, url]) => typeof url === "string" && /^https?:\/\/\S+$/i.test(url) ? [{
|
|
347
|
+
kind: "url",
|
|
348
|
+
label: subject ? `${subject} ${key}` : key,
|
|
349
|
+
url
|
|
350
|
+
}] : []);
|
|
351
|
+
}
|
|
352
|
+
// src/core/cli/output/render.ts
|
|
353
|
+
const clean = (text) => text.replaceAll(/\p{Cc}/gu, " ");
|
|
354
|
+
function flatten(value, nested = false) {
|
|
355
|
+
if (value === null || value === void 0) return "";
|
|
356
|
+
if (Array.isArray(value)) return value.map((item) => flatten(item, true)).join(", ");
|
|
357
|
+
if (typeof value === "object") {
|
|
358
|
+
const text = Object.entries(value).filter(([, item]) => !absent(item)).map(([key, item]) => `${key} ${flatten(item, true)}`).join(nested ? ", " : " · ");
|
|
359
|
+
return nested ? `(${text})` : text;
|
|
360
|
+
}
|
|
361
|
+
return isIsoTime(value) ? formatTime(value) : String(value);
|
|
362
|
+
}
|
|
363
|
+
const scalar = (value, path, loose) => {
|
|
364
|
+
if (value !== null && typeof value === "object") {
|
|
365
|
+
if (!loose) throw new Error(`Brief cannot print the object at ${path}; flatten it in the view.`);
|
|
366
|
+
return flatten(value);
|
|
367
|
+
}
|
|
368
|
+
return flatten(value);
|
|
369
|
+
};
|
|
370
|
+
const absent = (value, fallback) => value === void 0 || value === null || value === "" || value === false || fallback !== void 0 && value === fallback;
|
|
371
|
+
const EXIT_WORDS = {
|
|
372
|
+
1: "FAILED",
|
|
373
|
+
2: "NEEDS YOU",
|
|
374
|
+
3: "ISSUES",
|
|
375
|
+
4: "INCOMPLETE",
|
|
376
|
+
5: "PARTIAL",
|
|
377
|
+
130: "INTERRUPTED",
|
|
378
|
+
143: "INTERRUPTED"
|
|
379
|
+
};
|
|
380
|
+
const RECOVERY = {
|
|
381
|
+
E_ARTIFACT_NOT_FOUND: "check --artifact and --project-dir; artifacts live in <project>/.ryugi/artifacts/<type>/<id>/",
|
|
382
|
+
E_ARGUMENT_INVALID: "run the command with --help for its options",
|
|
383
|
+
E_CURSOR_EXPIRED: "run the read again without --cursor or --snapshot",
|
|
384
|
+
E_CURSOR_MISMATCH: "run the read again without --cursor or --snapshot"
|
|
385
|
+
};
|
|
386
|
+
const statusWord = (status, code) => code ? EXIT_WORDS[code] ?? "FAILED" : clean(status).replaceAll("_", " ").toUpperCase();
|
|
387
|
+
const commandName = (id) => {
|
|
388
|
+
const words = id.replaceAll(/[._]/g, " ").trim();
|
|
389
|
+
return words ? words[0].toUpperCase() + words.slice(1) : "Command";
|
|
390
|
+
};
|
|
391
|
+
function pageText(page) {
|
|
392
|
+
const offset = page.offset ?? 0;
|
|
393
|
+
if (!page.hasMore && offset === 0) return null;
|
|
394
|
+
const of = page.total === null ? "" : ` of ${page.total}`;
|
|
395
|
+
if (page.offset === void 0) return `${page.returned}${of} shown${page.total === null && page.hasMore ? " · more available" : ""}`;
|
|
396
|
+
return `${page.returned ? `${offset + 1}–${offset + page.returned}` : "none"}${of}`;
|
|
397
|
+
}
|
|
398
|
+
const quote = (value) => /^[\w./:@=+-]+$/.test(value) ? value : `'${value.replaceAll("'", "'\\''")}'`;
|
|
399
|
+
function actionText(action) {
|
|
400
|
+
return action.kind === "command" ? action.argv.map(quote).join(" ") : action.url;
|
|
401
|
+
}
|
|
402
|
+
const effectLines = (effects) => effects.map((effect) => `Effect: ${clean(effect.operation)} ${clean(effect.target)} · ${effect.state}`);
|
|
403
|
+
const lastSegment = (path) => path.split(".").filter(Boolean).at(-1) ?? path;
|
|
404
|
+
function renderText(view, wire, options, collection, requiredFields = [], code = 0) {
|
|
405
|
+
const head = [
|
|
406
|
+
statusWord(view.status, code),
|
|
407
|
+
view.subject && clean(view.subject),
|
|
408
|
+
view.summary && clean(view.summary)
|
|
409
|
+
].filter(Boolean);
|
|
410
|
+
const lines = [head.length ? `${clean(view.heading)}: ${head.join(" · ")}` : clean(view.heading)];
|
|
411
|
+
const omissions = [...wire.omitted ?? []];
|
|
412
|
+
const selected = (key, required = false) => required || requiredFields.includes(key) || !options.fields || options.fields.includes(key);
|
|
413
|
+
const value = (input, path, loose = false) => clean(scalar(input, path, loose));
|
|
414
|
+
const cell = (label, key, input, path, positional, fallback, loose = false) => {
|
|
415
|
+
if (absent(input, fallback)) return null;
|
|
416
|
+
const name = clean(label ?? key);
|
|
417
|
+
if (input === true) return name;
|
|
418
|
+
const text = value(input, path, loose);
|
|
419
|
+
return positional ? text : `${name} ${text}`;
|
|
420
|
+
};
|
|
421
|
+
const facts = (items, loose = false) => {
|
|
422
|
+
for (const item of items) {
|
|
423
|
+
if (!collection && !selected(item.binding.key, item.required)) continue;
|
|
424
|
+
if (absent(item.binding.value)) continue;
|
|
425
|
+
const text = item.binding.value === true ? "yes" : value(item.binding.value, `data.${item.binding.key}`, loose);
|
|
426
|
+
lines.push(`${clean(item.label)}: ${text}`);
|
|
427
|
+
}
|
|
428
|
+
};
|
|
429
|
+
const metadata = (items, path) => items.map((item) => cell(item.label, item.binding.key, item.binding.value, `${path}.${item.binding.key}`, item.positional)).filter((text) => text !== null).join(" · ");
|
|
430
|
+
const title = (text, summary) => {
|
|
431
|
+
if (text) lines.push(summary ? `${clean(text)} · ${clean(summary)}` : clean(text));
|
|
432
|
+
};
|
|
433
|
+
const pageLine = (page) => {
|
|
434
|
+
const text = page && pageText(page);
|
|
435
|
+
if (text) lines.push(text);
|
|
436
|
+
};
|
|
437
|
+
facts(view.facts);
|
|
438
|
+
const errorActions = wire.error ? recoveryActions(wire.error) : [];
|
|
439
|
+
if (wire.error) {
|
|
440
|
+
lines.push(`${clean(wire.error.code)}: ${clean(wire.error.message)}`);
|
|
441
|
+
if (wire.error.httpStatus !== void 0 && wire.error.httpStatus >= 500) lines.push(`HTTP: ${wire.error.httpStatus}`);
|
|
442
|
+
const hint = RECOVERY[wire.error.code];
|
|
443
|
+
if (hint) lines.push(`Next: ${hint}`);
|
|
444
|
+
const details = wire.error.details;
|
|
445
|
+
if (details && typeof details === "object" && !Array.isArray(details)) {
|
|
446
|
+
for (const [key, detail] of Object.entries(details)) if (!errorActions.some((action) => action.label === key)) facts([{
|
|
447
|
+
label: key,
|
|
448
|
+
binding: {
|
|
449
|
+
key,
|
|
450
|
+
value: detail
|
|
451
|
+
},
|
|
452
|
+
required: true
|
|
453
|
+
}], true);
|
|
454
|
+
} else if (details !== void 0) facts([{
|
|
455
|
+
label: "Details",
|
|
456
|
+
binding: {
|
|
457
|
+
key: "details",
|
|
458
|
+
value: details
|
|
459
|
+
},
|
|
460
|
+
required: true
|
|
461
|
+
}], true);
|
|
462
|
+
}
|
|
463
|
+
if (!collection && options.fields && wire.data && typeof wire.data === "object") {
|
|
464
|
+
const bound = /* @__PURE__ */ new Set([...view.facts.map((item) => item.binding.key), ...view.sections.flatMap((section) => section.kind === "fields" ? section.facts.map((item) => item.binding.key) : [section.key])]);
|
|
465
|
+
const data = wire.data;
|
|
466
|
+
facts([.../* @__PURE__ */ new Set([...options.fields, ...requiredFields])].filter((key) => !bound.has(key) && Object.hasOwn(data, key)).map((key) => ({
|
|
467
|
+
label: key,
|
|
468
|
+
binding: {
|
|
469
|
+
key,
|
|
470
|
+
value: data[key]
|
|
471
|
+
}
|
|
472
|
+
})), true);
|
|
473
|
+
}
|
|
474
|
+
for (const section of view.sections) {
|
|
475
|
+
if (section.kind === "fields") {
|
|
476
|
+
facts(section.facts);
|
|
477
|
+
continue;
|
|
478
|
+
}
|
|
479
|
+
if (!collection && !selected(section.key)) continue;
|
|
480
|
+
const named = "title" in section && section.title ? section.title : void 0;
|
|
481
|
+
if (section.kind === "records") {
|
|
482
|
+
title(named ?? (section.page ? section.key : void 0), section.summary);
|
|
483
|
+
const declared = new Set(section.columns.map((column) => column.key));
|
|
484
|
+
const extra = section.key === collection ? [.../* @__PURE__ */ new Set([...options.fields ?? [], ...options.fields ? requiredFields : []])].filter((key) => !declared.has(key)).map((key) => ({
|
|
485
|
+
key,
|
|
486
|
+
label: key
|
|
487
|
+
})) : [];
|
|
488
|
+
const loose = new Set(extra.map((column) => column.key));
|
|
489
|
+
const columns = [...section.columns, ...extra].filter((column) => section.key !== collection || selected(column.key, column.required));
|
|
490
|
+
if (options.format === "table") {
|
|
491
|
+
const labels = columns.map((column) => column.label ?? column.key);
|
|
492
|
+
const rows = section.rows.map((row, i) => columns.map((column) => absent(row[column.key], column.default) ? "" : value(row[column.key], `data.${section.key}.${i}.${column.key}`, loose.has(column.key))));
|
|
493
|
+
const widths = labels.map((label, i) => Math.max(label.length, ...rows.map((row) => row[i]?.length ?? 0)));
|
|
494
|
+
lines.push(...[labels, ...rows].map((row) => row.map((text, i) => text.padEnd(widths[i] ?? text.length)).join(" ").trimEnd()));
|
|
495
|
+
} else for (const [i, row] of section.rows.entries()) lines.push(` ${columns.map((column) => cell(column.label, column.key, row[column.key], `data.${section.key}.${i}.${column.key}`, column.positional, column.default, loose.has(column.key))).filter((text) => text !== null).join(" · ")}`);
|
|
496
|
+
if (!section.rows.length && !named && !section.page) lines.push("No records.");
|
|
497
|
+
pageLine(section.page);
|
|
498
|
+
} else if (section.kind === "messages") {
|
|
499
|
+
title(named, section.summary);
|
|
500
|
+
for (const [g, group] of section.groups.entries()) {
|
|
501
|
+
lines.push(` ${metadata(group.facts, `data.${section.key}.${g}`)}`);
|
|
502
|
+
for (const [m, message] of group.messages.entries()) {
|
|
503
|
+
lines.push(` ${metadata(message.facts, `data.${section.key}.${g}.messages.${m}`)}`);
|
|
504
|
+
lines.push(...message.text.split("\n").map((line) => ` ${line.replaceAll(/\p{Cc}/gu, (char) => char === " " ? char : "")}`));
|
|
505
|
+
}
|
|
506
|
+
}
|
|
507
|
+
if (!section.groups.length && !named && !section.page) lines.push("No messages.");
|
|
508
|
+
pageLine(section.page);
|
|
509
|
+
} else if (section.kind === "diagnostics") {
|
|
510
|
+
const limit = options.detail ? section.items.length : section.preview ?? 3;
|
|
511
|
+
for (const item of section.items.slice(0, limit)) lines.push(` ${item.location ? `${clean(item.location)} ` : ""}${clean(item.code)}: ${value(item.message, `data.${section.key}`)}`);
|
|
512
|
+
if (limit < section.items.length) omissions.push({
|
|
513
|
+
path: `data.${section.key}`,
|
|
514
|
+
reason: "preview",
|
|
515
|
+
count: section.items.length - limit
|
|
516
|
+
});
|
|
517
|
+
} else {
|
|
518
|
+
title(named && `${named}:`, section.summary);
|
|
519
|
+
lines.push(...section.text.trimEnd().split("\n").map((line) => ` ${line.replaceAll(/\p{Cc}/gu, (char) => char === " " || char === "\n" ? char : "")}`));
|
|
520
|
+
}
|
|
521
|
+
}
|
|
522
|
+
if (wire.page) pageLine(wire.page);
|
|
523
|
+
if (code || (wire.effects ?? []).some((effect) => effect.state !== "confirmed")) lines.push(...effectLines(wire.effects ?? []));
|
|
524
|
+
for (const warning of wire.warnings ?? []) lines.push(`Warning: ${clean(warning.message)}`);
|
|
525
|
+
const given = view.actions ?? wire.next ?? [];
|
|
526
|
+
const actions = [...given, ...errorActions.filter((action) => !given.some((other) => actionText(other) === actionText(action)))];
|
|
527
|
+
const used = /* @__PURE__ */ new Set();
|
|
528
|
+
const details = actions.find((action) => action.label === "Details");
|
|
529
|
+
for (const omission of omissions) {
|
|
530
|
+
if (omission.count === void 0) continue;
|
|
531
|
+
const more = `${omission.count} more ${lastSegment(omission.path)}`;
|
|
532
|
+
if (details && !used.has(details)) {
|
|
533
|
+
used.add(details);
|
|
534
|
+
lines.push(`${more} · Details: ${actionText(details)}`);
|
|
535
|
+
} else lines.push(more);
|
|
536
|
+
}
|
|
537
|
+
for (const action of actions) if (!used.has(action)) lines.push(`${clean(action.label ?? "Next")}: ${action.reason ? `${clean(action.reason)} · ` : ""}${actionText(action)}`);
|
|
538
|
+
return `${lines.join("\n")}\n`;
|
|
539
|
+
}
|
|
540
|
+
function renderFailure(wire, options, code = 1) {
|
|
541
|
+
return renderText({
|
|
542
|
+
heading: commandName(wire.command),
|
|
543
|
+
status: "",
|
|
544
|
+
facts: [],
|
|
545
|
+
sections: []
|
|
546
|
+
}, wire, {
|
|
547
|
+
...options,
|
|
548
|
+
fields: void 0
|
|
549
|
+
}, void 0, [], code);
|
|
550
|
+
}
|
|
551
|
+
// src/core/cli/output/bootstrap/index.ts
|
|
552
|
+
function resolveSelection(argv) {
|
|
553
|
+
return selectOutput(argv, {
|
|
554
|
+
"format": { "type": "string" },
|
|
555
|
+
"json": { "type": "boolean" },
|
|
556
|
+
"detail": { "type": "boolean" },
|
|
557
|
+
"fields": { "type": "string" },
|
|
558
|
+
"quiet": { "type": "boolean" },
|
|
559
|
+
"verbose": { "type": "boolean" },
|
|
560
|
+
"project-dir": { "type": "string" },
|
|
561
|
+
"artifact": { "type": "string" },
|
|
562
|
+
"host": { "type": "string" },
|
|
563
|
+
"url-host": { "type": "string" },
|
|
564
|
+
"port": { "type": "string" },
|
|
565
|
+
"open": { "type": "boolean" },
|
|
566
|
+
"no-open": { "type": "boolean" },
|
|
567
|
+
"foreground": { "type": "boolean" },
|
|
568
|
+
"background": { "type": "boolean" },
|
|
569
|
+
"mockup": { "type": "boolean" },
|
|
570
|
+
"base": { "type": "string" },
|
|
571
|
+
"input": { "type": "string" },
|
|
572
|
+
"page": { "type": "string" },
|
|
573
|
+
"visibility": { "type": "string" },
|
|
574
|
+
"type": { "type": "string" },
|
|
575
|
+
"project": { "type": "boolean" },
|
|
576
|
+
"module": { "type": "string" },
|
|
577
|
+
"limit": { "type": "string" },
|
|
578
|
+
"cursor": { "type": "string" },
|
|
579
|
+
"public": { "type": "boolean" },
|
|
580
|
+
"private": { "type": "boolean" },
|
|
581
|
+
"key": { "type": "boolean" },
|
|
582
|
+
"expires": { "type": "string" },
|
|
583
|
+
"new-key": { "type": "boolean" },
|
|
584
|
+
"revoke-key": { "type": "boolean" },
|
|
585
|
+
"profile": { "type": "boolean" },
|
|
586
|
+
"no-profile": { "type": "boolean" },
|
|
587
|
+
"unpublish": { "type": "boolean" },
|
|
588
|
+
"list": { "type": "boolean" },
|
|
589
|
+
"delete": { "type": "string" },
|
|
590
|
+
"space": { "type": "string" },
|
|
591
|
+
"move-to": { "type": "string" },
|
|
592
|
+
"no-refs": { "type": "boolean" },
|
|
593
|
+
"login": { "type": "boolean" },
|
|
594
|
+
"with-token": { "type": "boolean" },
|
|
595
|
+
"from": { "type": "string" },
|
|
596
|
+
"logout": { "type": "boolean" },
|
|
597
|
+
"as": { "type": "string" },
|
|
598
|
+
"dry-run": { "type": "boolean" },
|
|
599
|
+
"force": { "type": "boolean" },
|
|
600
|
+
"only": { "type": "string" },
|
|
601
|
+
"line": { "type": "string" },
|
|
602
|
+
"wait": { "type": "boolean" },
|
|
603
|
+
"file": { "type": "string" },
|
|
604
|
+
"map": { "type": "string" },
|
|
605
|
+
"master": { "type": "string" },
|
|
606
|
+
"id": { "type": "string" },
|
|
607
|
+
"url": { "type": "string" },
|
|
608
|
+
"all": { "type": "boolean" },
|
|
609
|
+
"thread": { "type": "string" },
|
|
610
|
+
"text": { "type": "string" },
|
|
611
|
+
"receipt": { "type": "string" },
|
|
612
|
+
"agent": { "type": "string" },
|
|
613
|
+
"set": { "type": "string" },
|
|
614
|
+
"sections": { "type": "string" },
|
|
615
|
+
"section": { "type": "string" },
|
|
616
|
+
"snapshot": { "type": "string" },
|
|
617
|
+
"status": { "type": "string" },
|
|
618
|
+
"waiting-on": { "type": "string" },
|
|
619
|
+
"kind": { "type": "string" },
|
|
620
|
+
"claim": { "type": "string" },
|
|
621
|
+
"gap": { "type": "string" },
|
|
622
|
+
"choice-state": { "type": "string" },
|
|
623
|
+
"block": { "type": "string" },
|
|
624
|
+
"quote": { "type": "string" },
|
|
625
|
+
"node": { "type": "string" },
|
|
626
|
+
"edge": { "type": "string" },
|
|
627
|
+
"board": { "type": "string" },
|
|
628
|
+
"element": { "type": "string" },
|
|
629
|
+
"slide": { "type": "string" },
|
|
630
|
+
"shot": { "type": "string" },
|
|
631
|
+
"at": { "type": "string" },
|
|
632
|
+
"cut": { "type": "string" },
|
|
633
|
+
"point": { "type": "string" },
|
|
634
|
+
"row": { "type": "string" },
|
|
635
|
+
"x": { "type": "string" },
|
|
636
|
+
"y": { "type": "string" },
|
|
637
|
+
"group": { "type": "string" },
|
|
638
|
+
"clear": { "type": "boolean" },
|
|
639
|
+
"ask": { "type": "string" },
|
|
640
|
+
"choice": { "type": "string" },
|
|
641
|
+
"round": { "type": "string" },
|
|
642
|
+
"withdraw": { "type": "boolean" },
|
|
643
|
+
"save": { "type": "string" },
|
|
644
|
+
"frame": { "type": "string" },
|
|
645
|
+
"source": { "type": "boolean" },
|
|
646
|
+
"download": { "type": "boolean" },
|
|
647
|
+
"out": { "type": "string" },
|
|
648
|
+
"no-comments": { "type": "boolean" },
|
|
649
|
+
"output-format": { "type": "string" },
|
|
650
|
+
"auto-publish": { "type": "string" },
|
|
651
|
+
"check": { "type": "boolean" },
|
|
652
|
+
"cli-only": { "type": "boolean" },
|
|
653
|
+
"plugins-only": { "type": "boolean" },
|
|
654
|
+
"install-dir": { "type": "string" },
|
|
655
|
+
"plugin-source": { "type": "string" },
|
|
656
|
+
"pm": { "type": "string" },
|
|
657
|
+
"mode": { "type": "string" },
|
|
658
|
+
"harness": { "type": "string" },
|
|
659
|
+
"yes": { "type": "boolean" },
|
|
660
|
+
"no-cli": { "type": "boolean" },
|
|
661
|
+
"bin-dir": { "type": "string" },
|
|
662
|
+
"binary": { "type": "string" },
|
|
663
|
+
"label": { "type": "string" },
|
|
664
|
+
"plugin": { "type": "string" }
|
|
665
|
+
}, configuredEnvironment(argv, {
|
|
666
|
+
"format": { "type": "string" },
|
|
667
|
+
"json": { "type": "boolean" },
|
|
668
|
+
"detail": { "type": "boolean" },
|
|
669
|
+
"fields": { "type": "string" },
|
|
670
|
+
"quiet": { "type": "boolean" },
|
|
671
|
+
"verbose": { "type": "boolean" },
|
|
672
|
+
"project-dir": { "type": "string" },
|
|
673
|
+
"artifact": { "type": "string" },
|
|
674
|
+
"host": { "type": "string" },
|
|
675
|
+
"url-host": { "type": "string" },
|
|
676
|
+
"port": { "type": "string" },
|
|
677
|
+
"open": { "type": "boolean" },
|
|
678
|
+
"no-open": { "type": "boolean" },
|
|
679
|
+
"foreground": { "type": "boolean" },
|
|
680
|
+
"background": { "type": "boolean" },
|
|
681
|
+
"mockup": { "type": "boolean" },
|
|
682
|
+
"base": { "type": "string" },
|
|
683
|
+
"input": { "type": "string" },
|
|
684
|
+
"page": { "type": "string" },
|
|
685
|
+
"visibility": { "type": "string" },
|
|
686
|
+
"type": { "type": "string" },
|
|
687
|
+
"project": { "type": "boolean" },
|
|
688
|
+
"module": { "type": "string" },
|
|
689
|
+
"limit": { "type": "string" },
|
|
690
|
+
"cursor": { "type": "string" },
|
|
691
|
+
"public": { "type": "boolean" },
|
|
692
|
+
"private": { "type": "boolean" },
|
|
693
|
+
"key": { "type": "boolean" },
|
|
694
|
+
"expires": { "type": "string" },
|
|
695
|
+
"new-key": { "type": "boolean" },
|
|
696
|
+
"revoke-key": { "type": "boolean" },
|
|
697
|
+
"profile": { "type": "boolean" },
|
|
698
|
+
"no-profile": { "type": "boolean" },
|
|
699
|
+
"unpublish": { "type": "boolean" },
|
|
700
|
+
"list": { "type": "boolean" },
|
|
701
|
+
"delete": { "type": "string" },
|
|
702
|
+
"space": { "type": "string" },
|
|
703
|
+
"move-to": { "type": "string" },
|
|
704
|
+
"no-refs": { "type": "boolean" },
|
|
705
|
+
"login": { "type": "boolean" },
|
|
706
|
+
"with-token": { "type": "boolean" },
|
|
707
|
+
"from": { "type": "string" },
|
|
708
|
+
"logout": { "type": "boolean" },
|
|
709
|
+
"as": { "type": "string" },
|
|
710
|
+
"dry-run": { "type": "boolean" },
|
|
711
|
+
"force": { "type": "boolean" },
|
|
712
|
+
"only": { "type": "string" },
|
|
713
|
+
"line": { "type": "string" },
|
|
714
|
+
"wait": { "type": "boolean" },
|
|
715
|
+
"file": { "type": "string" },
|
|
716
|
+
"map": { "type": "string" },
|
|
717
|
+
"master": { "type": "string" },
|
|
718
|
+
"id": { "type": "string" },
|
|
719
|
+
"url": { "type": "string" },
|
|
720
|
+
"all": { "type": "boolean" },
|
|
721
|
+
"thread": { "type": "string" },
|
|
722
|
+
"text": { "type": "string" },
|
|
723
|
+
"receipt": { "type": "string" },
|
|
724
|
+
"agent": { "type": "string" },
|
|
725
|
+
"set": { "type": "string" },
|
|
726
|
+
"sections": { "type": "string" },
|
|
727
|
+
"section": { "type": "string" },
|
|
728
|
+
"snapshot": { "type": "string" },
|
|
729
|
+
"status": { "type": "string" },
|
|
730
|
+
"waiting-on": { "type": "string" },
|
|
731
|
+
"kind": { "type": "string" },
|
|
732
|
+
"claim": { "type": "string" },
|
|
733
|
+
"gap": { "type": "string" },
|
|
734
|
+
"choice-state": { "type": "string" },
|
|
735
|
+
"block": { "type": "string" },
|
|
736
|
+
"quote": { "type": "string" },
|
|
737
|
+
"node": { "type": "string" },
|
|
738
|
+
"edge": { "type": "string" },
|
|
739
|
+
"board": { "type": "string" },
|
|
740
|
+
"element": { "type": "string" },
|
|
741
|
+
"slide": { "type": "string" },
|
|
742
|
+
"shot": { "type": "string" },
|
|
743
|
+
"at": { "type": "string" },
|
|
744
|
+
"cut": { "type": "string" },
|
|
745
|
+
"point": { "type": "string" },
|
|
746
|
+
"row": { "type": "string" },
|
|
747
|
+
"x": { "type": "string" },
|
|
748
|
+
"y": { "type": "string" },
|
|
749
|
+
"group": { "type": "string" },
|
|
750
|
+
"clear": { "type": "boolean" },
|
|
751
|
+
"ask": { "type": "string" },
|
|
752
|
+
"choice": { "type": "string" },
|
|
753
|
+
"round": { "type": "string" },
|
|
754
|
+
"withdraw": { "type": "boolean" },
|
|
755
|
+
"save": { "type": "string" },
|
|
756
|
+
"frame": { "type": "string" },
|
|
757
|
+
"source": { "type": "boolean" },
|
|
758
|
+
"download": { "type": "boolean" },
|
|
759
|
+
"out": { "type": "string" },
|
|
760
|
+
"no-comments": { "type": "boolean" },
|
|
761
|
+
"output-format": { "type": "string" },
|
|
762
|
+
"auto-publish": { "type": "string" },
|
|
763
|
+
"check": { "type": "boolean" },
|
|
764
|
+
"cli-only": { "type": "boolean" },
|
|
765
|
+
"plugins-only": { "type": "boolean" },
|
|
766
|
+
"install-dir": { "type": "string" },
|
|
767
|
+
"plugin-source": { "type": "string" },
|
|
768
|
+
"pm": { "type": "string" },
|
|
769
|
+
"mode": { "type": "string" },
|
|
770
|
+
"harness": { "type": "string" },
|
|
771
|
+
"yes": { "type": "boolean" },
|
|
772
|
+
"no-cli": { "type": "boolean" },
|
|
773
|
+
"bin-dir": { "type": "string" },
|
|
774
|
+
"binary": { "type": "string" },
|
|
775
|
+
"label": { "type": "string" },
|
|
776
|
+
"plugin": { "type": "string" }
|
|
777
|
+
}));
|
|
778
|
+
}
|
|
779
|
+
function reportFailure(argv, error, selection) {
|
|
780
|
+
let selected;
|
|
781
|
+
try {
|
|
782
|
+
selected = selection ?? resolveSelection(argv);
|
|
783
|
+
} catch {
|
|
784
|
+
selected = selectOutput(argv, {
|
|
785
|
+
"format": { "type": "string" },
|
|
786
|
+
"json": { "type": "boolean" },
|
|
787
|
+
"detail": { "type": "boolean" },
|
|
788
|
+
"fields": { "type": "string" },
|
|
789
|
+
"quiet": { "type": "boolean" },
|
|
790
|
+
"verbose": { "type": "boolean" },
|
|
791
|
+
"project-dir": { "type": "string" },
|
|
792
|
+
"artifact": { "type": "string" },
|
|
793
|
+
"host": { "type": "string" },
|
|
794
|
+
"url-host": { "type": "string" },
|
|
795
|
+
"port": { "type": "string" },
|
|
796
|
+
"open": { "type": "boolean" },
|
|
797
|
+
"no-open": { "type": "boolean" },
|
|
798
|
+
"foreground": { "type": "boolean" },
|
|
799
|
+
"background": { "type": "boolean" },
|
|
800
|
+
"mockup": { "type": "boolean" },
|
|
801
|
+
"base": { "type": "string" },
|
|
802
|
+
"input": { "type": "string" },
|
|
803
|
+
"page": { "type": "string" },
|
|
804
|
+
"visibility": { "type": "string" },
|
|
805
|
+
"type": { "type": "string" },
|
|
806
|
+
"project": { "type": "boolean" },
|
|
807
|
+
"module": { "type": "string" },
|
|
808
|
+
"limit": { "type": "string" },
|
|
809
|
+
"cursor": { "type": "string" },
|
|
810
|
+
"public": { "type": "boolean" },
|
|
811
|
+
"private": { "type": "boolean" },
|
|
812
|
+
"key": { "type": "boolean" },
|
|
813
|
+
"expires": { "type": "string" },
|
|
814
|
+
"new-key": { "type": "boolean" },
|
|
815
|
+
"revoke-key": { "type": "boolean" },
|
|
816
|
+
"profile": { "type": "boolean" },
|
|
817
|
+
"no-profile": { "type": "boolean" },
|
|
818
|
+
"unpublish": { "type": "boolean" },
|
|
819
|
+
"list": { "type": "boolean" },
|
|
820
|
+
"delete": { "type": "string" },
|
|
821
|
+
"space": { "type": "string" },
|
|
822
|
+
"move-to": { "type": "string" },
|
|
823
|
+
"no-refs": { "type": "boolean" },
|
|
824
|
+
"login": { "type": "boolean" },
|
|
825
|
+
"with-token": { "type": "boolean" },
|
|
826
|
+
"from": { "type": "string" },
|
|
827
|
+
"logout": { "type": "boolean" },
|
|
828
|
+
"as": { "type": "string" },
|
|
829
|
+
"dry-run": { "type": "boolean" },
|
|
830
|
+
"force": { "type": "boolean" },
|
|
831
|
+
"only": { "type": "string" },
|
|
832
|
+
"line": { "type": "string" },
|
|
833
|
+
"wait": { "type": "boolean" },
|
|
834
|
+
"file": { "type": "string" },
|
|
835
|
+
"map": { "type": "string" },
|
|
836
|
+
"master": { "type": "string" },
|
|
837
|
+
"id": { "type": "string" },
|
|
838
|
+
"url": { "type": "string" },
|
|
839
|
+
"all": { "type": "boolean" },
|
|
840
|
+
"thread": { "type": "string" },
|
|
841
|
+
"text": { "type": "string" },
|
|
842
|
+
"receipt": { "type": "string" },
|
|
843
|
+
"agent": { "type": "string" },
|
|
844
|
+
"set": { "type": "string" },
|
|
845
|
+
"sections": { "type": "string" },
|
|
846
|
+
"section": { "type": "string" },
|
|
847
|
+
"snapshot": { "type": "string" },
|
|
848
|
+
"status": { "type": "string" },
|
|
849
|
+
"waiting-on": { "type": "string" },
|
|
850
|
+
"kind": { "type": "string" },
|
|
851
|
+
"claim": { "type": "string" },
|
|
852
|
+
"gap": { "type": "string" },
|
|
853
|
+
"choice-state": { "type": "string" },
|
|
854
|
+
"block": { "type": "string" },
|
|
855
|
+
"quote": { "type": "string" },
|
|
856
|
+
"node": { "type": "string" },
|
|
857
|
+
"edge": { "type": "string" },
|
|
858
|
+
"board": { "type": "string" },
|
|
859
|
+
"element": { "type": "string" },
|
|
860
|
+
"slide": { "type": "string" },
|
|
861
|
+
"shot": { "type": "string" },
|
|
862
|
+
"at": { "type": "string" },
|
|
863
|
+
"cut": { "type": "string" },
|
|
864
|
+
"point": { "type": "string" },
|
|
865
|
+
"row": { "type": "string" },
|
|
866
|
+
"x": { "type": "string" },
|
|
867
|
+
"y": { "type": "string" },
|
|
868
|
+
"group": { "type": "string" },
|
|
869
|
+
"clear": { "type": "boolean" },
|
|
870
|
+
"ask": { "type": "string" },
|
|
871
|
+
"choice": { "type": "string" },
|
|
872
|
+
"round": { "type": "string" },
|
|
873
|
+
"withdraw": { "type": "boolean" },
|
|
874
|
+
"save": { "type": "string" },
|
|
875
|
+
"frame": { "type": "string" },
|
|
876
|
+
"source": { "type": "boolean" },
|
|
877
|
+
"download": { "type": "boolean" },
|
|
878
|
+
"out": { "type": "string" },
|
|
879
|
+
"no-comments": { "type": "boolean" },
|
|
880
|
+
"output-format": { "type": "string" },
|
|
881
|
+
"auto-publish": { "type": "string" },
|
|
882
|
+
"check": { "type": "boolean" },
|
|
883
|
+
"cli-only": { "type": "boolean" },
|
|
884
|
+
"plugins-only": { "type": "boolean" },
|
|
885
|
+
"install-dir": { "type": "string" },
|
|
886
|
+
"plugin-source": { "type": "string" },
|
|
887
|
+
"pm": { "type": "string" },
|
|
888
|
+
"mode": { "type": "string" },
|
|
889
|
+
"harness": { "type": "string" },
|
|
890
|
+
"yes": { "type": "boolean" },
|
|
891
|
+
"no-cli": { "type": "boolean" },
|
|
892
|
+
"bin-dir": { "type": "string" },
|
|
893
|
+
"binary": { "type": "string" },
|
|
894
|
+
"label": { "type": "string" },
|
|
895
|
+
"plugin": { "type": "string" }
|
|
896
|
+
});
|
|
897
|
+
}
|
|
898
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
899
|
+
const detail = selected.error?.error ?? (error instanceof OutputError ? error.error : {
|
|
900
|
+
code: "E_BOOTSTRAP_FAILED",
|
|
901
|
+
message
|
|
902
|
+
});
|
|
903
|
+
const failure = result(null, {
|
|
904
|
+
kind: "failed",
|
|
905
|
+
error: detail
|
|
906
|
+
});
|
|
907
|
+
const wire = {
|
|
908
|
+
...normalize(argv[0] && !argv[0].startsWith("-") ? argv[0] : "browse", failure, { format: selected.options.format }, { formats: [selected.options.format] }),
|
|
909
|
+
error: detail
|
|
910
|
+
};
|
|
911
|
+
if (selected.options.format === "json") process.stdout.write(`${JSON.stringify(wire)}\n`);
|
|
912
|
+
else if (selected.options.format === "jsonl") process.stdout.write(`${JSON.stringify({
|
|
913
|
+
...wire,
|
|
914
|
+
seq: 0,
|
|
915
|
+
kind: "result"
|
|
916
|
+
})}\n`);
|
|
917
|
+
else process.stderr.write(renderFailure(wire, selected.options));
|
|
918
|
+
process.exitCode = 1;
|
|
919
|
+
}
|
|
920
|
+
exports.reportFailure = reportFailure;
|
|
921
|
+
exports.resolveSelection = resolveSelection;
|