@zubriq/code 0.19.8-1 → 0.19.9-1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundled/qc-helper/docs/features/channels/_meta.ts +1 -0
- package/dist/bundled/qc-helper/docs/features/channels/overview.md +23 -12
- package/dist/bundled/qc-helper/docs/features/channels/plugins.md +1 -0
- package/dist/bundled/qc-helper/docs/features/channels/wecom.md +111 -0
- package/dist/bundled/qc-helper/docs/features/hooks.md +36 -34
- package/dist/bundled/qc-helper/docs/features/memory.md +1 -1
- package/dist/bundled/qc-helper/docs/qwen-serve.md +17 -10
- package/dist/bundled/review/SKILL.md +6 -2
- package/dist/chunks/{MaxSizedBox-OWTCJQNO.js → MaxSizedBox-W6SAJMJC.js} +13 -11
- package/dist/chunks/{StandaloneSessionPicker-6NGEQFBH.js → StandaloneSessionPicker-YBKZZKIA.js} +28 -23
- package/dist/chunks/{acpAgent-XPRWSNOW.js → acpAgent-SQJQBOTS.js} +110 -80
- package/dist/chunks/{agent-TB6S4VXU.js → agent-QU7Q2RZN.js} +8 -8
- package/dist/chunks/{agent-headless-R3XYK5TT.js → agent-headless-PBHLWHND.js} +8 -8
- package/dist/chunks/{anthropicContentGenerator-FZQAEMYK.js → anthropicContentGenerator-52G6ZA3D.js} +31 -4
- package/dist/chunks/{artifact-tool-H2TNPNP5.js → artifact-tool-D233YJFH.js} +25 -6
- package/dist/chunks/{bridge-HVRG6SMU.js → bridge-LJLLDUMW.js} +17 -14
- package/dist/chunks/{ca-HCMB2I54.js → ca-MKD32FQL.js} +26 -1
- package/dist/chunks/{channel-worker-supervisor-B7MSMB5K.js → channel-worker-supervisor-NZQUOEFJ.js} +3 -3
- package/dist/chunks/{chunk-YRM6BC6H.js → chunk-27AYMAL6.js} +506 -63
- package/dist/chunks/{chunk-536GZ6UF.js → chunk-2MDC5WDB.js} +17 -111
- package/dist/chunks/{chunk-H3D6XAOL.js → chunk-2PRSBVPI.js} +3 -3
- package/dist/chunks/chunk-332PWN27.js +19 -0
- package/dist/chunks/{chunk-FVMWEHWU.js → chunk-3B26UVCX.js} +114 -12
- package/dist/chunks/{chunk-ZM5BPDXV.js → chunk-3F22JT4E.js} +1 -1
- package/dist/chunks/{chunk-W6RH6KHR.js → chunk-3GPVYALM.js} +4 -2
- package/dist/chunks/{chunk-G7ZG7CA6.js → chunk-3UP777ZS.js} +8 -7
- package/dist/chunks/{chunk-PA7QS4X5.js → chunk-43W4YSO6.js} +1 -12
- package/dist/chunks/{chunk-5EB2HK3X.js → chunk-4IK56VLC.js} +1 -1
- package/dist/chunks/{chunk-UE5TCZE6.js → chunk-5FAUIGXH.js} +5 -13
- package/dist/chunks/{chunk-VEB3NYSO.js → chunk-5MBO76SL.js} +5 -0
- package/dist/chunks/{chunk-PDITONOB.js → chunk-5MRUKUOG.js} +5347 -4132
- package/dist/chunks/{chunk-4UC3U66K.js → chunk-6EUMFVPJ.js} +5 -5
- package/dist/chunks/{chunk-YOGGIAGF.js → chunk-6JL5OVLX.js} +1 -1
- package/dist/chunks/{chunk-QG4ZO2EB.js → chunk-74E6VVF6.js} +11 -11
- package/dist/chunks/chunk-A2X3KLC3.js +3807 -0
- package/dist/chunks/{chunk-BA4HLTG2.js → chunk-B6B2MUUF.js} +5 -5
- package/dist/chunks/{chunk-XKYOIERV.js → chunk-BN5VYAOZ.js} +681 -1239
- package/dist/chunks/{chunk-IO76BGJ3.js → chunk-BYUA6YYS.js} +15 -9
- package/dist/chunks/{chunk-NCFY7PWS.js → chunk-CCGOFQV3.js} +51 -2
- package/dist/chunks/{chunk-66KNL43D.js → chunk-CD6USWHZ.js} +1 -1
- package/dist/chunks/{chunk-ZWSTIPSW.js → chunk-CEITMQ62.js} +2 -2
- package/dist/chunks/{chunk-7AQTBTVY.js → chunk-EJP6Z7NU.js} +4 -3
- package/dist/chunks/{chunk-RTW5ZXHO.js → chunk-EZTNYRHH.js} +6 -5
- package/dist/chunks/{chunk-MJQFA66Z.js → chunk-FAATDXYS.js} +308 -81
- package/dist/chunks/{chunk-DNV4FSN5.js → chunk-FBET5XZ2.js} +6 -4
- package/dist/chunks/{chunk-HTC4R67V.js → chunk-FES4YXJ3.js} +9 -9
- package/dist/chunks/{chunk-NBKE6QRZ.js → chunk-FHTUTVIQ.js} +10 -5
- package/dist/chunks/chunk-FII3C4E7.js +168 -0
- package/dist/chunks/{chunk-2NL7ED5Q.js → chunk-FV7425LN.js} +22 -1
- package/dist/chunks/{chunk-J6OET6C3.js → chunk-GAI76CFX.js} +4 -4
- package/dist/chunks/{chunk-B34OV7K2.js → chunk-GGQQA4JW.js} +13 -0
- package/dist/chunks/chunk-GLE2YUPU.js +34 -0
- package/dist/chunks/{chunk-X265R5C6.js → chunk-GN3F6PIU.js} +1 -1
- package/dist/chunks/{chunk-SM624MOZ.js → chunk-GWUN54UD.js} +1 -1
- package/dist/chunks/chunk-H3TELH3H.js +942 -0
- package/dist/chunks/{chunk-XZULYFIX.js → chunk-HD4DZI2L.js} +2 -2
- package/dist/chunks/{chunk-KLLLWQM2.js → chunk-HPQIVXSP.js} +1 -1
- package/dist/chunks/{chunk-WSVZFWN4.js → chunk-IBY3Q3HG.js} +693 -104
- package/dist/chunks/{chunk-JSEOX4CM.js → chunk-JGR6W4IX.js} +14 -8
- package/dist/chunks/chunk-K652V4NH.js +283 -0
- package/dist/chunks/{chunk-OCBJKHF2.js → chunk-KH2CZZDD.js} +2 -2
- package/dist/chunks/chunk-LGFAYIKX.js +115 -0
- package/dist/chunks/{chunk-QG5KDB6X.js → chunk-LZDW5TDV.js} +5 -5
- package/dist/chunks/{chunk-ENKWIF75.js → chunk-MA4AZNP7.js} +10 -10
- package/dist/chunks/{chunk-4RQIB5UZ.js → chunk-O2YT7VB4.js} +0 -34
- package/dist/chunks/{chunk-4KJ2BPIT.js → chunk-OACJLMLD.js} +2 -38
- package/dist/chunks/{chunk-ML2ZWH2K.js → chunk-PCWYMX57.js} +14 -153
- package/dist/chunks/{chunk-NHFBLJOI.js → chunk-Q3PQ5VGJ.js} +1 -1
- package/dist/chunks/{chunk-LGXBB2R2.js → chunk-QK3I36QG.js} +1 -1
- package/dist/chunks/chunk-RA7TR75G.js +8223 -0
- package/dist/chunks/{chunk-KSPVDFE4.js → chunk-SAIILPQ3.js} +0 -3
- package/dist/chunks/{chunk-DHKDK57Q.js → chunk-SNZPA74J.js} +146 -54
- package/dist/chunks/{chunk-PWR5MVM3.js → chunk-SSP3UT5C.js} +4 -4
- package/dist/chunks/{chunk-4LETJLG2.js → chunk-SUCRVT5L.js} +1 -1
- package/dist/chunks/{chunk-5YLZHETW.js → chunk-TRR5KGDN.js} +1 -1
- package/dist/chunks/chunk-UIDXQNMV.js +13 -0
- package/dist/chunks/{chunk-PIORL4OD.js → chunk-UKV3D7WB.js} +0 -44
- package/dist/chunks/chunk-UYNUIGUR.js +167 -0
- package/dist/chunks/chunk-V2TYBEWU.js +28 -0
- package/dist/chunks/chunk-V35MD7KN.js +13 -0
- package/dist/chunks/{chunk-N4HTVZDZ.js → chunk-VR3KCBHH.js} +1 -1
- package/dist/chunks/{chunk-APYUOROB.js → chunk-W4CTWW7M.js} +423 -61
- package/dist/chunks/{chunk-ABANKQYY.js → chunk-WJAW2O5H.js} +92 -465
- package/dist/chunks/{chunk-6RSBRKF5.js → chunk-WN4YJJGH.js} +2 -2
- package/dist/chunks/chunk-XNXVCNAT.js +88 -0
- package/dist/chunks/{chunk-TDGF35EN.js → chunk-XOHNA2S6.js} +1 -1
- package/dist/chunks/chunk-XQPMKWSV.js +487 -0
- package/dist/chunks/{chunk-4FQL7KUS.js → chunk-XWDHZP7P.js} +8 -8
- package/dist/chunks/{chunk-REPRY4F7.js → chunk-YCKKP4QA.js} +10 -10
- package/dist/chunks/{chunk-YNWQ3PUQ.js → chunk-YJWMOGGZ.js} +3 -3
- package/dist/chunks/{chunk-RFIL6REB.js → chunk-YKZIAK7C.js} +119 -29
- package/dist/chunks/{chunk-45YCXM2H.js → chunk-YZDBUH6S.js} +45 -9
- package/dist/chunks/chunk-Z3I3QJK3.js +47 -0
- package/dist/chunks/{chunk-G23FFNLT.js → chunk-ZDGPPCTW.js} +20 -8
- package/dist/chunks/chunk-ZL5HN75Q.js +61 -0
- package/dist/chunks/{chunk-IQX5S2RS.js → chunk-ZL7JCYWM.js} +66 -7
- package/dist/chunks/{computer-use-A72BECH4.js → computer-use-4B45EG2F.js} +8 -8
- package/dist/chunks/{contextCommand-RREXA4B7.js → contextCommand-GIVRWNTS.js} +12 -11
- package/dist/chunks/{cron-create-DDYU4DIR.js → cron-create-JSXEIPVS.js} +1 -1
- package/dist/chunks/{cron-delete-DFKOUZWN.js → cron-delete-OIFVEPGU.js} +1 -1
- package/dist/chunks/{cron-list-ME5QGAR5.js → cron-list-D4ZX4IOE.js} +1 -1
- package/dist/chunks/{daemon-XWG2EGFX.js → daemon-WPAENEBW.js} +71 -3
- package/dist/chunks/{daemon-status-provider-Y6AFXTET.js → daemon-status-provider-WBOAMCHE.js} +20 -17
- package/dist/chunks/{de-PLLFDERI.js → de-ZFPPQVSF.js} +26 -1
- package/dist/chunks/{dist-LPVU3L2M.js → dist-BEXOZXLQ.js} +6 -3792
- package/dist/chunks/{dist-7GU63KI5.js → dist-E6UANPIM.js} +1 -1
- package/dist/chunks/{dist-VHBP2PIG.js → dist-H2AEJCZ5.js} +2 -2
- package/dist/chunks/{dist-3UDX5T4T.js → dist-O2IRTRPP.js} +1 -1
- package/dist/chunks/dist-SCFLLYMK.js +3217 -0
- package/dist/chunks/{dist-H4HHZYCI.js → dist-Z34QPAQW.js} +2 -2
- package/dist/chunks/{earlyInputCapture-OAHBOGOO.js → earlyInputCapture-JWMCAJZR.js} +8 -8
- package/dist/chunks/{edit-SFYW3FOV.js → edit-O5FUVHBE.js} +9 -9
- package/dist/chunks/{en-AXARKOWO.js → en-N4EPZAQI.js} +31 -2
- package/dist/chunks/{enter-worktree-LUPPQ2NH.js → enter-worktree-LOJFRC3D.js} +8 -8
- package/dist/chunks/{enterPlanMode-44GEN5U6.js → enterPlanMode-VS3FAUPX.js} +8 -8
- package/dist/chunks/environment-WKW5TLSH.js +90 -0
- package/dist/chunks/{errors-H3Q3W3DL.js → errors-LEZXHJMR.js} +10 -10
- package/dist/chunks/{exit-worktree-34CVVWT4.js → exit-worktree-RN2NXRMP.js} +8 -8
- package/dist/chunks/{exitPlanMode-5G5BHNUP.js → exitPlanMode-EPC424I4.js} +8 -8
- package/dist/chunks/{fast-path-7PKGFBRM.js → fast-path-UUPAFOSQ.js} +12 -3
- package/dist/chunks/{fast-path-settings-RCRXH2JG.js → fast-path-settings-7RIFI3PK.js} +3 -2
- package/dist/chunks/{fr-MBMNQSQ6.js → fr-5WWMY53B.js} +30 -1
- package/dist/chunks/{gemini-2II6JH4H.js → gemini-QCKK4XNU.js} +438 -265
- package/dist/chunks/{geminiContentGenerator-SWEJVOC4.js → geminiContentGenerator-DX4SRXJA.js} +1 -1
- package/dist/chunks/{glob-5DFC7DXW.js → glob-4URMJWRX.js} +8 -8
- package/dist/chunks/{grep-QYVXGRRJ.js → grep-AEQB5KED.js} +8 -8
- package/dist/chunks/handleAutoUpdate-Y4YNG34Y.js +65 -0
- package/dist/chunks/{initializer-XX3UGUHE.js → initializer-NDEBMSOG.js} +17 -13
- package/dist/chunks/{ja-HFV5QCHR.js → ja-CUHZOLEJ.js} +30 -1
- package/dist/chunks/{list-AX5FWBVC.js → list-VSCBNOWT.js} +17 -15
- package/dist/chunks/{loadedSettingsAdapter-ISOM6GJ7.js → loadedSettingsAdapter-FDO752BA.js} +15 -13
- package/dist/chunks/{loop-wakeup-ZW5P6VPY.js → loop-wakeup-OHWEMFP5.js} +2 -2
- package/dist/chunks/{ls-L654WOAT.js → ls-7MFU2QYW.js} +1 -1
- package/dist/chunks/{lsp-M35KE54Y.js → lsp-XHDTPTGV.js} +2 -4
- package/dist/chunks/{mcp-74F6725E.js → mcp-MLPWTHUV.js} +15 -13
- package/dist/chunks/{monitor-W4WRSC2C.js → monitor-WCVHIJUJ.js} +16 -11
- package/dist/chunks/{nonInteractiveCli-4QMV6C4J.js → nonInteractiveCli-32HZK274.js} +52 -44
- package/dist/chunks/{notebook-edit-XBZEIP42.js → notebook-edit-NPOMPKS4.js} +9 -9
- package/dist/chunks/{openaiContentGenerator-RTUJDESE.js → openaiContentGenerator-6AIBSRQK.js} +6 -6
- package/dist/chunks/{pidfile-YWSGNTPK.js → pidfile-7Y3QEDSZ.js} +8 -8
- package/dist/chunks/{pt-2THT3YHA.js → pt-OLYN42DS.js} +26 -1
- package/dist/chunks/{qwenContentGenerator-4ZFYAZLY.js → qwenContentGenerator-OUYOAYT4.js} +10 -10
- package/dist/chunks/{read-file-D7DKDIAC.js → read-file-EESFA24L.js} +3 -3
- package/dist/chunks/{record-artifact-PP3LKHTS.js → record-artifact-SQ2OKRJW.js} +3 -3
- package/dist/chunks/{ripGrep-KG7JYNER.js → ripGrep-DLYV7ZZG.js} +8 -8
- package/dist/chunks/{ru-PER5I4OI.js → ru-MKM2HFDS.js} +26 -1
- package/dist/chunks/{run-qwen-serve-XGJSNF6S.js → run-qwen-serve-WUEHQROF.js} +602 -143
- package/dist/chunks/{scheduler-MOLWOE4G.js → scheduler-SK4Y66V4.js} +8 -8
- package/dist/chunks/{send-message-OA6MV4EU.js → send-message-76GT3JMC.js} +1 -1
- package/dist/chunks/{serve-4ZNVPYND.js → serve-UCDGVZFI.js} +17 -14
- package/dist/chunks/{server-ACWDFHIF.js → server-FVGFFVZ4.js} +1394 -328
- package/dist/chunks/{session-VYO2GRO2.js → session-RIGKDMGR.js} +53 -45
- package/dist/chunks/{settings-4J2O3K22.js → settings-LVFFGXGE.js} +24 -20
- package/dist/chunks/{shell-RKERJYXR.js → shell-PAWNAFYN.js} +8 -8
- package/dist/chunks/{skill-JYACZJ5V.js → skill-5YIN3Z6Y.js} +15 -5
- package/dist/chunks/{spawnChannel-BA3U3RGX.js → spawnChannel-KIMZHWNR.js} +10 -10
- package/dist/chunks/{src-3P337V4P.js → src-BIWCD3VX.js} +21 -9
- package/dist/chunks/{startInteractiveUI-SUSZ6FWB.js → startInteractiveUI-AFXLGUFI.js} +33759 -41620
- package/dist/chunks/{task-create-RPFZNB4B.js → task-create-WCHTB435.js} +2 -2
- package/dist/chunks/{task-update-5WUG5MVQ.js → task-update-XYWMHJGJ.js} +2 -2
- package/dist/chunks/{team-create-YVWGRZEA.js → team-create-26WOMISV.js} +8 -8
- package/dist/chunks/{team-plan-approval-VRF54TTI.js → team-plan-approval-B5XB6UQC.js} +8 -8
- package/dist/chunks/{theme-manager-JW2KOACL.js → theme-manager-4TJ5TEFD.js} +8 -8
- package/dist/chunks/{tool-search-KUSMAZBN.js → tool-search-FFU63E6M.js} +6 -23
- package/dist/chunks/total-session-admission-JOD7SMPJ.js +72 -0
- package/dist/chunks/{trustedFolders-ERGSUCDK.js → trustedFolders-IJ2QHXSC.js} +9 -9
- package/dist/chunks/updateCheck-5Z25DCBP.js +65 -0
- package/dist/chunks/{validateNonInterActiveAuth-DDI62H5X.js → validateNonInterActiveAuth-G5EY47DE.js} +49 -41
- package/dist/chunks/{version-VB3AHVUF.js → version-LGO3GOKQ.js} +2 -1
- package/dist/chunks/{workflow-WINKRCI4.js → workflow-ZTK3WT3D.js} +9 -9
- package/dist/chunks/{workspace-providers-status-ZVZPXKSO.js → workspace-providers-status-YMPTRKW2.js} +18 -15
- package/dist/chunks/workspace-registry-NBUL6LBH.js +74 -0
- package/dist/chunks/{workspace-service-GAS2LV2P.js → workspace-service-V6G2RCD4.js} +21 -19
- package/dist/chunks/{workspace-skills-status-4WGKYJVA.js → workspace-skills-status-ZCW44BCH.js} +16 -14
- package/dist/chunks/{write-file-UTLKVZNN.js → write-file-4FUTAEW6.js} +9 -9
- package/dist/chunks/{zh-RS3HZHFH.js → zh-J4F6QWQV.js} +31 -2
- package/dist/chunks/{zh-TW-L5GRQ4S4.js → zh-TW-XVDWOLSW.js} +31 -2
- package/dist/cli.js +11 -11
- package/dist/locales/ca.js +30 -0
- package/dist/locales/de.js +30 -0
- package/dist/locales/en.js +38 -2
- package/dist/locales/fr.js +36 -0
- package/dist/locales/ja.js +36 -0
- package/dist/locales/pt.js +30 -0
- package/dist/locales/ru.js +30 -0
- package/dist/locales/zh-TW.js +38 -2
- package/dist/locales/zh.js +38 -2
- package/dist/package.json +3 -3
- package/dist/web-shell/assets/{arc-C6tzvtOa.js → arc-BWyoJpY2.js} +1 -1
- package/dist/web-shell/assets/{architectureDiagram-3BPJPVTR-DSYQFGn9.js → architectureDiagram-3BPJPVTR-BT0mGrz2.js} +1 -1
- package/dist/web-shell/assets/{blockDiagram-GPEHLZMM-CHjBdXAD.js → blockDiagram-GPEHLZMM-BLgUWvyf.js} +1 -1
- package/dist/web-shell/assets/{c4Diagram-AAUBKEIU-BQzK6Yyb.js → c4Diagram-AAUBKEIU-DYx9M7oU.js} +1 -1
- package/dist/web-shell/assets/channel-wmPUGHtg.js +1 -0
- package/dist/web-shell/assets/{chunk-2J33WTMH-hpP2p3Ij.js → chunk-2J33WTMH-CfMHWbuZ.js} +1 -1
- package/dist/web-shell/assets/{chunk-4BX2VUAB-B5KtK1JJ.js → chunk-4BX2VUAB-B1URoqEV.js} +1 -1
- package/dist/web-shell/assets/{chunk-55IACEB6-BDv6Mfr2.js → chunk-55IACEB6-DAIaM4QF.js} +1 -1
- package/dist/web-shell/assets/{chunk-727SXJPM-BevPWfrX.js → chunk-727SXJPM-B2X34knw.js} +1 -1
- package/dist/web-shell/assets/{chunk-AQP2D5EJ-ChDrz2ad.js → chunk-AQP2D5EJ-Cif-zLTQ.js} +1 -1
- package/dist/web-shell/assets/{chunk-FMBD7UC4-ClMdVSDs.js → chunk-FMBD7UC4-H18WCXdY.js} +1 -1
- package/dist/web-shell/assets/{chunk-ND2GUHAM-BceV8kZS.js → chunk-ND2GUHAM-YFtetHi0.js} +1 -1
- package/dist/web-shell/assets/{chunk-QZHKN3VN-DtyK2wwc.js → chunk-QZHKN3VN-By2hiH3r.js} +1 -1
- package/dist/web-shell/assets/classDiagram-4FO5ZUOK-BA2ljEjW.js +1 -0
- package/dist/web-shell/assets/classDiagram-v2-Q7XG4LA2-BA2ljEjW.js +1 -0
- package/dist/web-shell/assets/{cose-bilkent-S5V4N54A-BGMsqwmE.js → cose-bilkent-S5V4N54A-VrcnnLZu.js} +1 -1
- package/dist/web-shell/assets/{dagre-BM42HDAG-C-71clpF.js → dagre-BM42HDAG-CGo-IaVV.js} +1 -1
- package/dist/web-shell/assets/{diagram-2AECGRRQ-WIzzlkec.js → diagram-2AECGRRQ-Dl4QjzIB.js} +1 -1
- package/dist/web-shell/assets/{diagram-5GNKFQAL-CtnhZUP1.js → diagram-5GNKFQAL-qMLmsO0u.js} +1 -1
- package/dist/web-shell/assets/{diagram-KO2AKTUF-CS_IUezp.js → diagram-KO2AKTUF-CHlmuxPI.js} +1 -1
- package/dist/web-shell/assets/{diagram-LMA3HP47-BQnGRwN9.js → diagram-LMA3HP47-BUwU3GwT.js} +1 -1
- package/dist/web-shell/assets/{diagram-OG6HWLK6-By2VIocq.js → diagram-OG6HWLK6-HEhwPDUM.js} +1 -1
- package/dist/web-shell/assets/{erDiagram-TEJ5UH35-Dy8WeNkr.js → erDiagram-TEJ5UH35-1n0llBmM.js} +1 -1
- package/dist/web-shell/assets/{flowDiagram-I6XJVG4X-Diu_4y0w.js → flowDiagram-I6XJVG4X-BN74uMnt.js} +1 -1
- package/dist/web-shell/assets/{ganttDiagram-6RSMTGT7-CH8euujP.js → ganttDiagram-6RSMTGT7-BoOq78i3.js} +1 -1
- package/dist/web-shell/assets/{gitGraphDiagram-PVQCEYII-DHiObZq1.js → gitGraphDiagram-PVQCEYII-CN8b00c8.js} +1 -1
- package/dist/web-shell/assets/index-CNwoO1Cn.js +783 -0
- package/dist/web-shell/assets/index-CWQ0z6kZ.css +5 -0
- package/dist/web-shell/assets/{infoDiagram-5YYISTIA-CvC9A6fh.js → infoDiagram-5YYISTIA-CCurnIna.js} +1 -1
- package/dist/web-shell/assets/{ishikawaDiagram-YF4QCWOH-BK46kC4E.js → ishikawaDiagram-YF4QCWOH-AwuRqdUP.js} +1 -1
- package/dist/web-shell/assets/{journeyDiagram-JHISSGLW-B2TIiKq4.js → journeyDiagram-JHISSGLW-B7IICk-E.js} +1 -1
- package/dist/web-shell/assets/{kanban-definition-UN3LZRKU-Bh0WAulO.js → kanban-definition-UN3LZRKU-BYF0OKhx.js} +1 -1
- package/dist/web-shell/assets/{linear-Bxe9SHMk.js → linear-GWWguGfD.js} +1 -1
- package/dist/web-shell/assets/{mermaid.core-B1Pv6D5B.js → mermaid.core-JqtkxvCl.js} +5 -5
- package/dist/web-shell/assets/{mindmap-definition-RKZ34NQL-Bz0joLH8.js → mindmap-definition-RKZ34NQL-B0MmHsZ6.js} +1 -1
- package/dist/web-shell/assets/{pieDiagram-4H26LBE5-CnN4x-VS.js → pieDiagram-4H26LBE5-DhImUZLQ.js} +1 -1
- package/dist/web-shell/assets/{quadrantDiagram-W4KKPZXB-BYWD4xO4.js → quadrantDiagram-W4KKPZXB-DGeSC3DT.js} +1 -1
- package/dist/web-shell/assets/{requirementDiagram-4Y6WPE33-B4MEhI9h.js → requirementDiagram-4Y6WPE33-DkspY6Re.js} +1 -1
- package/dist/web-shell/assets/{sankeyDiagram-5OEKKPKP-Dk_FgKLp.js → sankeyDiagram-5OEKKPKP-CaOofS2x.js} +1 -1
- package/dist/web-shell/assets/{sequenceDiagram-3UESZ5HK-B4ksiBZQ.js → sequenceDiagram-3UESZ5HK-DFQ_kFnN.js} +1 -1
- package/dist/web-shell/assets/{stateDiagram-AJRCARHV-CYf0xSPl.js → stateDiagram-AJRCARHV-D3snw0Tz.js} +1 -1
- package/dist/web-shell/assets/stateDiagram-v2-BHNVJYJU-BbSm_9d0.js +1 -0
- package/dist/web-shell/assets/{timeline-definition-PNZ67QCA-0CXeWHNY.js → timeline-definition-PNZ67QCA-l4zH8nLM.js} +1 -1
- package/dist/web-shell/assets/{vennDiagram-CIIHVFJN-DHoYY9v2.js → vennDiagram-CIIHVFJN-BnRlA98M.js} +1 -1
- package/dist/web-shell/assets/{wardley-L42UT6IY-D_65qshr.js → wardley-L42UT6IY-BS0xUdmd.js} +1 -1
- package/dist/web-shell/assets/{wardleyDiagram-YWT4CUSO-Cv90x1sd.js → wardleyDiagram-YWT4CUSO-DKGBUWyQ.js} +1 -1
- package/dist/web-shell/assets/{xychartDiagram-2RQKCTM6-5FQCYJyh.js → xychartDiagram-2RQKCTM6-DVb2HuOB.js} +1 -1
- package/dist/web-shell/index.html +2 -2
- package/package.json +3 -2
- package/dist/web-shell/assets/channel-V-ZaJrA6.js +0 -1
- package/dist/web-shell/assets/classDiagram-4FO5ZUOK-s-H0snGT.js +0 -1
- package/dist/web-shell/assets/classDiagram-v2-Q7XG4LA2-s-H0snGT.js +0 -1
- package/dist/web-shell/assets/index-DW75jq0K.css +0 -5
- package/dist/web-shell/assets/index-tiCo0xbZ.js +0 -779
- package/dist/web-shell/assets/stateDiagram-v2-BHNVJYJU-CMtrFRUb.js +0 -1
|
@@ -6,18 +6,18 @@ import {
|
|
|
6
6
|
getLanguageNameFromLocale,
|
|
7
7
|
getLanguageSettingsOptions,
|
|
8
8
|
t
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-MA4AZNP7.js";
|
|
10
10
|
import {
|
|
11
11
|
DEFAULT_DARK_THEME_NAME,
|
|
12
12
|
DEFAULT_LIGHT_THEME_NAME
|
|
13
13
|
} from "./chunk-TLRYABYP.js";
|
|
14
|
+
import {
|
|
15
|
+
getHomeEnvFallbackVars,
|
|
16
|
+
loadEnvironment,
|
|
17
|
+
preResolveHomeEnvOverrides
|
|
18
|
+
} from "./chunk-XQPMKWSV.js";
|
|
14
19
|
import {
|
|
15
20
|
CONSOLIDATED_DISABLE_KEYS,
|
|
16
|
-
DEFAULT_EXCLUDED_ENV_VARS,
|
|
17
|
-
ENV_CORRUPTED_PATH,
|
|
18
|
-
ENV_WAS_RECOVERED,
|
|
19
|
-
HOME_ENV_BOOTSTRAP_KEYS,
|
|
20
|
-
PROJECT_ENV_HARDCODED_EXCLUSIONS,
|
|
21
21
|
V1_INDICATOR_KEYS,
|
|
22
22
|
V1_TO_V2_MIGRATION_MAP,
|
|
23
23
|
V1_TO_V2_PRESERVE_DISABLE_MAP,
|
|
@@ -25,11 +25,15 @@ import {
|
|
|
25
25
|
getSystemDefaultsPath,
|
|
26
26
|
getSystemSettingsPath,
|
|
27
27
|
resolveEnvVarsInObject
|
|
28
|
-
} from "./chunk-
|
|
28
|
+
} from "./chunk-O2YT7VB4.js";
|
|
29
|
+
import {
|
|
30
|
+
ENV_CORRUPTED_PATH,
|
|
31
|
+
ENV_WAS_RECOVERED
|
|
32
|
+
} from "./chunk-Z3I3QJK3.js";
|
|
29
33
|
import {
|
|
30
34
|
isWorkspaceTrusted,
|
|
31
35
|
updateSettingsFilePreservingFormat
|
|
32
|
-
} from "./chunk-
|
|
36
|
+
} from "./chunk-VR3KCBHH.js";
|
|
33
37
|
import {
|
|
34
38
|
require_strip_json_comments
|
|
35
39
|
} from "./chunk-QYUE6W3T.js";
|
|
@@ -42,20 +46,16 @@ import {
|
|
|
42
46
|
DEFAULT_TRUNCATE_TOOL_OUTPUT_LINES,
|
|
43
47
|
DEFAULT_TRUNCATE_TOOL_OUTPUT_THRESHOLD,
|
|
44
48
|
stripRuntimeSnapshotPrefix
|
|
45
|
-
} from "./chunk-
|
|
46
|
-
import {
|
|
47
|
-
require_main
|
|
48
|
-
} from "./chunk-SKAZWEV5.js";
|
|
49
|
+
} from "./chunk-5MRUKUOG.js";
|
|
49
50
|
import {
|
|
50
51
|
DEFAULT_QWEN_CUSTOM_IGNORE_FILE_NAMES
|
|
51
52
|
} from "./chunk-TLWA7TPR.js";
|
|
52
53
|
import {
|
|
53
54
|
DEFAULT_SENSITIVE_SPAN_ATTRIBUTE_MAX_LENGTH,
|
|
54
55
|
SENSITIVE_SPAN_ATTRIBUTE_MAX_LENGTH_LIMIT
|
|
55
|
-
} from "./chunk-
|
|
56
|
+
} from "./chunk-27AYMAL6.js";
|
|
56
57
|
import {
|
|
57
58
|
FatalConfigError,
|
|
58
|
-
QWEN_DIR,
|
|
59
59
|
Storage,
|
|
60
60
|
createDebugLogger,
|
|
61
61
|
getErrorMessage
|
|
@@ -70,10 +70,10 @@ import {
|
|
|
70
70
|
|
|
71
71
|
// packages/cli/src/config/settings.ts
|
|
72
72
|
init_esbuild_shims();
|
|
73
|
-
import * as
|
|
74
|
-
import * as
|
|
75
|
-
import { homedir
|
|
76
|
-
import
|
|
73
|
+
import * as fs3 from "node:fs";
|
|
74
|
+
import * as path2 from "node:path";
|
|
75
|
+
import { homedir } from "node:os";
|
|
76
|
+
import process from "node:process";
|
|
77
77
|
var import_strip_json_comments = __toESM(require_strip_json_comments(), 1);
|
|
78
78
|
|
|
79
79
|
// packages/cli/src/config/modelProvidersScope.ts
|
|
@@ -1905,8 +1905,8 @@ var SETTINGS_SCHEMA = {
|
|
|
1905
1905
|
label: "Pager",
|
|
1906
1906
|
category: "Tools",
|
|
1907
1907
|
requiresRestart: false,
|
|
1908
|
-
default:
|
|
1909
|
-
description: "The pager command to use for shell output. Defaults to `cat
|
|
1908
|
+
default: void 0,
|
|
1909
|
+
description: "The pager command to use for shell output. Defaults to `cat` on non-Windows platforms and unset on Windows. Set to an empty string to disable pager environment variables.",
|
|
1910
1910
|
showInDialog: false
|
|
1911
1911
|
},
|
|
1912
1912
|
showColor: {
|
|
@@ -1960,6 +1960,16 @@ var SETTINGS_SCHEMA = {
|
|
|
1960
1960
|
showInDialog: false,
|
|
1961
1961
|
mergeStrategy: "union" /* UNION */
|
|
1962
1962
|
},
|
|
1963
|
+
visible: {
|
|
1964
|
+
type: "array",
|
|
1965
|
+
label: "Visible Deferred Tools",
|
|
1966
|
+
category: "Tools",
|
|
1967
|
+
requiresRestart: true,
|
|
1968
|
+
default: void 0,
|
|
1969
|
+
description: "Deferred tool names made visible at startup without requiring tool_search. Listed tools appear alongside core tools in the initial session.",
|
|
1970
|
+
showInDialog: false,
|
|
1971
|
+
mergeStrategy: "union" /* UNION */
|
|
1972
|
+
},
|
|
1963
1973
|
approvalMode: {
|
|
1964
1974
|
type: "enum",
|
|
1965
1975
|
label: "Tool Approval Mode",
|
|
@@ -2362,6 +2372,20 @@ var SETTINGS_SCHEMA = {
|
|
|
2362
2372
|
description: "Settings for multi-agent collaboration features (Arena, Team, Swarm).",
|
|
2363
2373
|
showInDialog: false,
|
|
2364
2374
|
properties: {
|
|
2375
|
+
maxParallelAgents: {
|
|
2376
|
+
type: "number",
|
|
2377
|
+
label: "Max Parallel Agents",
|
|
2378
|
+
category: "Advanced",
|
|
2379
|
+
requiresRestart: true,
|
|
2380
|
+
default: void 0,
|
|
2381
|
+
minimum: 1,
|
|
2382
|
+
description: "Global maximum number of background sub-agents that can run concurrently. Additional background agents wait in a queue until a slot is available. Per-model limits are not supported yet.",
|
|
2383
|
+
showInDialog: false,
|
|
2384
|
+
jsonSchemaOverride: {
|
|
2385
|
+
type: "integer",
|
|
2386
|
+
minimum: 1
|
|
2387
|
+
}
|
|
2388
|
+
},
|
|
2365
2389
|
displayMode: {
|
|
2366
2390
|
type: "enum",
|
|
2367
2391
|
label: "Display Mode",
|
|
@@ -3023,8 +3047,8 @@ function getDefaultValue(key) {
|
|
|
3023
3047
|
return getFlattenedSchema()[key]?.default;
|
|
3024
3048
|
}
|
|
3025
3049
|
__name(getDefaultValue, "getDefaultValue");
|
|
3026
|
-
function getNestedValue(obj,
|
|
3027
|
-
const [first, ...rest] =
|
|
3050
|
+
function getNestedValue(obj, path3) {
|
|
3051
|
+
const [first, ...rest] = path3;
|
|
3028
3052
|
if (!first || !(first in obj)) {
|
|
3029
3053
|
return void 0;
|
|
3030
3054
|
}
|
|
@@ -3038,8 +3062,8 @@ function getNestedValue(obj, path4) {
|
|
|
3038
3062
|
return void 0;
|
|
3039
3063
|
}
|
|
3040
3064
|
__name(getNestedValue, "getNestedValue");
|
|
3041
|
-
function getNestedProperty(obj,
|
|
3042
|
-
return getNestedValue(obj,
|
|
3065
|
+
function getNestedProperty(obj, path3) {
|
|
3066
|
+
return getNestedValue(obj, path3.split("."));
|
|
3043
3067
|
}
|
|
3044
3068
|
__name(getNestedProperty, "getNestedProperty");
|
|
3045
3069
|
function getEffectiveValue(key, settings, mergedSettings) {
|
|
@@ -3047,12 +3071,12 @@ function getEffectiveValue(key, settings, mergedSettings) {
|
|
|
3047
3071
|
if (!definition) {
|
|
3048
3072
|
return void 0;
|
|
3049
3073
|
}
|
|
3050
|
-
const
|
|
3051
|
-
let value = getNestedValue(settings,
|
|
3074
|
+
const path3 = key.split(".");
|
|
3075
|
+
let value = getNestedValue(settings, path3);
|
|
3052
3076
|
if (value !== void 0) {
|
|
3053
3077
|
return value;
|
|
3054
3078
|
}
|
|
3055
|
-
value = getNestedValue(mergedSettings,
|
|
3079
|
+
value = getNestedValue(mergedSettings, path3);
|
|
3056
3080
|
if (value !== void 0) {
|
|
3057
3081
|
return value;
|
|
3058
3082
|
}
|
|
@@ -3138,8 +3162,8 @@ function getDialogSettingKeys() {
|
|
|
3138
3162
|
}
|
|
3139
3163
|
__name(getDialogSettingKeys, "getDialogSettingKeys");
|
|
3140
3164
|
function settingExistsInScope(key, scopeSettings) {
|
|
3141
|
-
const
|
|
3142
|
-
const value = getNestedValue(scopeSettings,
|
|
3165
|
+
const path3 = key.split(".");
|
|
3166
|
+
const value = getNestedValue(scopeSettings, path3);
|
|
3143
3167
|
return value !== void 0;
|
|
3144
3168
|
}
|
|
3145
3169
|
__name(settingExistsInScope, "settingExistsInScope");
|
|
@@ -3152,8 +3176,8 @@ function pathHasUnsafeSegment(keys) {
|
|
|
3152
3176
|
return false;
|
|
3153
3177
|
}
|
|
3154
3178
|
__name(pathHasUnsafeSegment, "pathHasUnsafeSegment");
|
|
3155
|
-
function setNestedPropertyForce(obj,
|
|
3156
|
-
const keys =
|
|
3179
|
+
function setNestedPropertyForce(obj, path3, value) {
|
|
3180
|
+
const keys = path3.split(".");
|
|
3157
3181
|
if (pathHasUnsafeSegment(keys)) return;
|
|
3158
3182
|
const lastKey = keys.pop();
|
|
3159
3183
|
if (!lastKey) return;
|
|
@@ -3167,8 +3191,8 @@ function setNestedPropertyForce(obj, path4, value) {
|
|
|
3167
3191
|
current[lastKey] = value;
|
|
3168
3192
|
}
|
|
3169
3193
|
__name(setNestedPropertyForce, "setNestedPropertyForce");
|
|
3170
|
-
function setNestedPropertySafe(obj,
|
|
3171
|
-
const keys =
|
|
3194
|
+
function setNestedPropertySafe(obj, path3, value) {
|
|
3195
|
+
const keys = path3.split(".");
|
|
3172
3196
|
if (pathHasUnsafeSegment(keys)) return;
|
|
3173
3197
|
const lastKey = keys.pop();
|
|
3174
3198
|
if (!lastKey) return;
|
|
@@ -3187,8 +3211,8 @@ function setNestedPropertySafe(obj, path4, value) {
|
|
|
3187
3211
|
current[lastKey] = value;
|
|
3188
3212
|
}
|
|
3189
3213
|
__name(setNestedPropertySafe, "setNestedPropertySafe");
|
|
3190
|
-
function deleteNestedPropertySafe(obj,
|
|
3191
|
-
const keys =
|
|
3214
|
+
function deleteNestedPropertySafe(obj, path3) {
|
|
3215
|
+
const keys = path3.split(".");
|
|
3192
3216
|
const lastKey = keys.pop();
|
|
3193
3217
|
if (!lastKey) return;
|
|
3194
3218
|
let current = obj;
|
|
@@ -3220,10 +3244,10 @@ function getRestartRequiredFromModified(modifiedSettings) {
|
|
|
3220
3244
|
__name(getRestartRequiredFromModified, "getRestartRequiredFromModified");
|
|
3221
3245
|
function saveModifiedSettings(modifiedSettings, pendingSettings, loadedSettings, scope) {
|
|
3222
3246
|
modifiedSettings.forEach((settingKey) => {
|
|
3223
|
-
const
|
|
3247
|
+
const path3 = settingKey.split(".");
|
|
3224
3248
|
const value = getNestedValue(
|
|
3225
3249
|
pendingSettings,
|
|
3226
|
-
|
|
3250
|
+
path3
|
|
3227
3251
|
);
|
|
3228
3252
|
const existsInOriginalFile = settingExistsInScope(
|
|
3229
3253
|
settingKey,
|
|
@@ -3325,12 +3349,12 @@ function isPlainObject(item) {
|
|
|
3325
3349
|
return !!item && typeof item === "object" && !Array.isArray(item);
|
|
3326
3350
|
}
|
|
3327
3351
|
__name(isPlainObject, "isPlainObject");
|
|
3328
|
-
function mergeRecursively(target, source, getMergeStrategyForPath2,
|
|
3352
|
+
function mergeRecursively(target, source, getMergeStrategyForPath2, path3 = []) {
|
|
3329
3353
|
for (const key of Object.keys(source)) {
|
|
3330
3354
|
if (key === "__proto__" || key === "constructor" || key === "prototype") {
|
|
3331
3355
|
continue;
|
|
3332
3356
|
}
|
|
3333
|
-
const newPath = [...
|
|
3357
|
+
const newPath = [...path3, key];
|
|
3334
3358
|
const srcValue = source[key];
|
|
3335
3359
|
const objValue = target[key];
|
|
3336
3360
|
const mergeStrategy = getMergeStrategyForPath2(newPath);
|
|
@@ -3926,400 +3950,12 @@ function needsMigration(settings) {
|
|
|
3926
3950
|
}
|
|
3927
3951
|
__name(needsMigration, "needsMigration");
|
|
3928
3952
|
|
|
3929
|
-
// packages/cli/src/config/environment.ts
|
|
3930
|
-
init_esbuild_shims();
|
|
3931
|
-
var dotenv = __toESM(require_main(), 1);
|
|
3932
|
-
import * as fs3 from "node:fs";
|
|
3933
|
-
import * as path2 from "node:path";
|
|
3934
|
-
import * as os from "node:os";
|
|
3935
|
-
var SETTINGS_DIRECTORY_NAME = QWEN_DIR;
|
|
3936
|
-
var RELOAD_EXCLUDED_KEYS = /* @__PURE__ */ new Set([
|
|
3937
|
-
...PROJECT_ENV_HARDCODED_EXCLUSIONS,
|
|
3938
|
-
"QWEN_SERVER_TOKEN",
|
|
3939
|
-
"QWEN_CLI_ENTRY",
|
|
3940
|
-
"NODE_OPTIONS",
|
|
3941
|
-
"NODE_PATH",
|
|
3942
|
-
"NODE_TLS_REJECT_UNAUTHORIZED",
|
|
3943
|
-
"LD_PRELOAD",
|
|
3944
|
-
"LD_AUDIT",
|
|
3945
|
-
"LD_LIBRARY_PATH",
|
|
3946
|
-
"DYLD_INSERT_LIBRARIES",
|
|
3947
|
-
"DYLD_LIBRARY_PATH",
|
|
3948
|
-
"BASH_ENV",
|
|
3949
|
-
"ENV",
|
|
3950
|
-
"PATH",
|
|
3951
|
-
"HOME",
|
|
3952
|
-
"TMPDIR",
|
|
3953
|
-
"TMP",
|
|
3954
|
-
"TEMP"
|
|
3955
|
-
]);
|
|
3956
|
-
var dotEnvSourcedKeys = /* @__PURE__ */ new Set();
|
|
3957
|
-
var settingsEnvSourcedKeys = /* @__PURE__ */ new Set();
|
|
3958
|
-
var lastReloadSnapshot = /* @__PURE__ */ new Map();
|
|
3959
|
-
var lastReloadSnapshotSeeded = false;
|
|
3960
|
-
function getUserLevelEnvPaths() {
|
|
3961
|
-
const homeDir = os.homedir();
|
|
3962
|
-
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
3963
|
-
const paths = /* @__PURE__ */ new Set([
|
|
3964
|
-
path2.normalize(path2.join(homeDir, ".env")),
|
|
3965
|
-
path2.normalize(path2.join(globalQwenDir, ".env"))
|
|
3966
|
-
]);
|
|
3967
|
-
const legacyQwenEnv = path2.normalize(path2.join(homeDir, QWEN_DIR, ".env"));
|
|
3968
|
-
paths.add(legacyQwenEnv);
|
|
3969
|
-
return paths;
|
|
3970
|
-
}
|
|
3971
|
-
__name(getUserLevelEnvPaths, "getUserLevelEnvPaths");
|
|
3972
|
-
var homeEnvBootstrapped = false;
|
|
3973
|
-
function preResolveHomeEnvOverrides() {
|
|
3974
|
-
if (homeEnvBootstrapped) {
|
|
3975
|
-
return;
|
|
3976
|
-
}
|
|
3977
|
-
homeEnvBootstrapped = true;
|
|
3978
|
-
if (HOME_ENV_BOOTSTRAP_KEYS.every((key) => process.env[key])) {
|
|
3979
|
-
return;
|
|
3980
|
-
}
|
|
3981
|
-
const initialQwenHome = process.env["QWEN_HOME"];
|
|
3982
|
-
const initialQwenDir = Storage.getGlobalQwenDir();
|
|
3983
|
-
const candidates = [path2.join(initialQwenDir, ".env")];
|
|
3984
|
-
if (!initialQwenHome) {
|
|
3985
|
-
candidates.push(path2.join(path2.dirname(initialQwenDir), ".env"));
|
|
3986
|
-
}
|
|
3987
|
-
for (const candidate of candidates) {
|
|
3988
|
-
readHomeEnvInto(candidate);
|
|
3989
|
-
}
|
|
3990
|
-
const discoveredQwenHome = process.env["QWEN_HOME"];
|
|
3991
|
-
if (discoveredQwenHome && discoveredQwenHome !== initialQwenHome) {
|
|
3992
|
-
const discoveredDir = Storage.getGlobalQwenDir();
|
|
3993
|
-
if (discoveredDir !== initialQwenDir) {
|
|
3994
|
-
readHomeEnvInto(path2.join(discoveredDir, ".env"));
|
|
3995
|
-
}
|
|
3996
|
-
}
|
|
3997
|
-
}
|
|
3998
|
-
__name(preResolveHomeEnvOverrides, "preResolveHomeEnvOverrides");
|
|
3999
|
-
function readHomeEnvInto(file) {
|
|
4000
|
-
if (!fs3.existsSync(file)) {
|
|
4001
|
-
return;
|
|
4002
|
-
}
|
|
4003
|
-
try {
|
|
4004
|
-
const parsed = dotenv.parse(fs3.readFileSync(file, "utf-8"));
|
|
4005
|
-
for (const key of PROJECT_ENV_HARDCODED_EXCLUSIONS) {
|
|
4006
|
-
if (parsed[key] && !Object.hasOwn(process.env, key)) {
|
|
4007
|
-
process.env[key] = parsed[key];
|
|
4008
|
-
}
|
|
4009
|
-
}
|
|
4010
|
-
} catch (_e) {
|
|
4011
|
-
}
|
|
4012
|
-
}
|
|
4013
|
-
__name(readHomeEnvInto, "readHomeEnvInto");
|
|
4014
|
-
function resetHomeEnvBootstrapForTesting() {
|
|
4015
|
-
homeEnvBootstrapped = false;
|
|
4016
|
-
}
|
|
4017
|
-
__name(resetHomeEnvBootstrapForTesting, "resetHomeEnvBootstrapForTesting");
|
|
4018
|
-
function resetEnvironmentTrackingForTesting() {
|
|
4019
|
-
dotEnvSourcedKeys.clear();
|
|
4020
|
-
settingsEnvSourcedKeys.clear();
|
|
4021
|
-
lastReloadSnapshot.clear();
|
|
4022
|
-
lastReloadSnapshotSeeded = false;
|
|
4023
|
-
}
|
|
4024
|
-
__name(resetEnvironmentTrackingForTesting, "resetEnvironmentTrackingForTesting");
|
|
4025
|
-
function getHomeEnvFallbackVars(onReadError) {
|
|
4026
|
-
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
4027
|
-
const candidates = [path2.join(globalQwenDir, ".env")];
|
|
4028
|
-
if (!process.env["QWEN_HOME"]) {
|
|
4029
|
-
candidates.push(path2.join(path2.dirname(globalQwenDir), ".env"));
|
|
4030
|
-
}
|
|
4031
|
-
const result = {};
|
|
4032
|
-
for (const candidate of candidates) {
|
|
4033
|
-
if (!fs3.existsSync(candidate)) {
|
|
4034
|
-
continue;
|
|
4035
|
-
}
|
|
4036
|
-
try {
|
|
4037
|
-
const parsed = dotenv.parse(fs3.readFileSync(candidate, "utf-8"));
|
|
4038
|
-
for (const key in parsed) {
|
|
4039
|
-
if (Object.hasOwn(parsed, key) && !Object.hasOwn(process.env, key)) {
|
|
4040
|
-
result[key] ??= parsed[key];
|
|
4041
|
-
}
|
|
4042
|
-
}
|
|
4043
|
-
} catch (e) {
|
|
4044
|
-
onReadError?.(
|
|
4045
|
-
`Failed to read home .env candidate ${candidate}: ${getErrorMessage(e)}`
|
|
4046
|
-
);
|
|
4047
|
-
}
|
|
4048
|
-
}
|
|
4049
|
-
return result;
|
|
4050
|
-
}
|
|
4051
|
-
__name(getHomeEnvFallbackVars, "getHomeEnvFallbackVars");
|
|
4052
|
-
function findEnvFiles(settings, startDir, userLevelPaths = getUserLevelEnvPaths()) {
|
|
4053
|
-
const homeDir = os.homedir();
|
|
4054
|
-
let realStartDir = path2.resolve(startDir);
|
|
4055
|
-
try {
|
|
4056
|
-
realStartDir = fs3.realpathSync(realStartDir);
|
|
4057
|
-
} catch {
|
|
4058
|
-
}
|
|
4059
|
-
const isTrusted = isWorkspaceTrusted(
|
|
4060
|
-
settings,
|
|
4061
|
-
void 0,
|
|
4062
|
-
realStartDir
|
|
4063
|
-
).isTrusted;
|
|
4064
|
-
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
4065
|
-
const legacyQwenDir = path2.normalize(path2.join(homeDir, QWEN_DIR));
|
|
4066
|
-
const hasCustomConfigDir = path2.normalize(globalQwenDir) !== legacyQwenDir;
|
|
4067
|
-
const found = [];
|
|
4068
|
-
const seen = /* @__PURE__ */ new Set();
|
|
4069
|
-
const canUseEnvFile = /* @__PURE__ */ __name((filePath) => isTrusted !== false || userLevelPaths.has(path2.normalize(filePath)), "canUseEnvFile");
|
|
4070
|
-
const pushCandidate = /* @__PURE__ */ __name((filePath) => {
|
|
4071
|
-
const normalized = path2.normalize(filePath);
|
|
4072
|
-
if (!seen.has(normalized) && fs3.existsSync(filePath) && canUseEnvFile(filePath)) {
|
|
4073
|
-
seen.add(normalized);
|
|
4074
|
-
found.push(filePath);
|
|
4075
|
-
return true;
|
|
4076
|
-
}
|
|
4077
|
-
return false;
|
|
4078
|
-
}, "pushCandidate");
|
|
4079
|
-
const pushHomeCandidates = /* @__PURE__ */ __name(() => {
|
|
4080
|
-
const candidates = [path2.join(globalQwenDir, ".env")];
|
|
4081
|
-
if (hasCustomConfigDir) {
|
|
4082
|
-
candidates.push(path2.join(legacyQwenDir, ".env"));
|
|
4083
|
-
}
|
|
4084
|
-
candidates.push(path2.join(homeDir, ".env"));
|
|
4085
|
-
for (const candidate of candidates) {
|
|
4086
|
-
pushCandidate(candidate);
|
|
4087
|
-
}
|
|
4088
|
-
}, "pushHomeCandidates");
|
|
4089
|
-
let currentDir = realStartDir;
|
|
4090
|
-
let visitedHomeDir = false;
|
|
4091
|
-
while (true) {
|
|
4092
|
-
if (currentDir === homeDir) {
|
|
4093
|
-
visitedHomeDir = true;
|
|
4094
|
-
pushHomeCandidates();
|
|
4095
|
-
return found;
|
|
4096
|
-
} else {
|
|
4097
|
-
const geminiEnvPath = path2.join(currentDir, QWEN_DIR, ".env");
|
|
4098
|
-
if (pushCandidate(geminiEnvPath)) {
|
|
4099
|
-
pushHomeCandidates();
|
|
4100
|
-
return found;
|
|
4101
|
-
}
|
|
4102
|
-
const envPath = path2.join(currentDir, ".env");
|
|
4103
|
-
if (pushCandidate(envPath)) {
|
|
4104
|
-
pushHomeCandidates();
|
|
4105
|
-
return found;
|
|
4106
|
-
}
|
|
4107
|
-
}
|
|
4108
|
-
const parentDir = path2.dirname(currentDir);
|
|
4109
|
-
if (parentDir === currentDir || !parentDir) {
|
|
4110
|
-
if (!visitedHomeDir) {
|
|
4111
|
-
pushHomeCandidates();
|
|
4112
|
-
}
|
|
4113
|
-
return found;
|
|
4114
|
-
}
|
|
4115
|
-
currentDir = parentDir;
|
|
4116
|
-
}
|
|
4117
|
-
}
|
|
4118
|
-
__name(findEnvFiles, "findEnvFiles");
|
|
4119
|
-
function setUpCloudShellEnvironment(envFilePath) {
|
|
4120
|
-
if (envFilePath && fs3.existsSync(envFilePath)) {
|
|
4121
|
-
const envFileContent = fs3.readFileSync(envFilePath);
|
|
4122
|
-
const parsedEnv = dotenv.parse(envFileContent);
|
|
4123
|
-
if (parsedEnv["GOOGLE_CLOUD_PROJECT"]) {
|
|
4124
|
-
process.env["GOOGLE_CLOUD_PROJECT"] = parsedEnv["GOOGLE_CLOUD_PROJECT"];
|
|
4125
|
-
} else {
|
|
4126
|
-
process.env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
4127
|
-
}
|
|
4128
|
-
} else {
|
|
4129
|
-
process.env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
4130
|
-
}
|
|
4131
|
-
}
|
|
4132
|
-
__name(setUpCloudShellEnvironment, "setUpCloudShellEnvironment");
|
|
4133
|
-
function setUpCloudShellEnvironmentFromFiles(envFilePaths) {
|
|
4134
|
-
for (const envFilePath of envFilePaths) {
|
|
4135
|
-
if (!fs3.existsSync(envFilePath)) {
|
|
4136
|
-
continue;
|
|
4137
|
-
}
|
|
4138
|
-
const envFileContent = fs3.readFileSync(envFilePath);
|
|
4139
|
-
const parsedEnv = dotenv.parse(envFileContent);
|
|
4140
|
-
if (parsedEnv["GOOGLE_CLOUD_PROJECT"]) {
|
|
4141
|
-
process.env["GOOGLE_CLOUD_PROJECT"] = parsedEnv["GOOGLE_CLOUD_PROJECT"];
|
|
4142
|
-
return;
|
|
4143
|
-
}
|
|
4144
|
-
}
|
|
4145
|
-
process.env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
4146
|
-
}
|
|
4147
|
-
__name(setUpCloudShellEnvironmentFromFiles, "setUpCloudShellEnvironmentFromFiles");
|
|
4148
|
-
function loadEnvironment(settings, startDir = process.cwd()) {
|
|
4149
|
-
const userLevelPaths = getUserLevelEnvPaths();
|
|
4150
|
-
const envFilePaths = findEnvFiles(settings, startDir, userLevelPaths);
|
|
4151
|
-
if (process.env["CLOUD_SHELL"] === "true") {
|
|
4152
|
-
setUpCloudShellEnvironmentFromFiles(envFilePaths);
|
|
4153
|
-
}
|
|
4154
|
-
for (const envFilePath of envFilePaths) {
|
|
4155
|
-
try {
|
|
4156
|
-
const envFileContent = fs3.readFileSync(envFilePath, "utf-8");
|
|
4157
|
-
const parsedEnv = dotenv.parse(envFileContent);
|
|
4158
|
-
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
4159
|
-
const normalizedEnvFilePath = path2.normalize(envFilePath);
|
|
4160
|
-
const isHomeScopedEnvFile = userLevelPaths.has(normalizedEnvFilePath);
|
|
4161
|
-
const isQwenScopedEnvFile = isHomeScopedEnvFile || path2.basename(path2.dirname(normalizedEnvFilePath)) === QWEN_DIR;
|
|
4162
|
-
for (const key in parsedEnv) {
|
|
4163
|
-
if (Object.hasOwn(parsedEnv, key)) {
|
|
4164
|
-
if (!isHomeScopedEnvFile && PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) {
|
|
4165
|
-
continue;
|
|
4166
|
-
}
|
|
4167
|
-
if (!isQwenScopedEnvFile && excludedVars.includes(key)) {
|
|
4168
|
-
continue;
|
|
4169
|
-
}
|
|
4170
|
-
const existingValue = process.env[key];
|
|
4171
|
-
const isEffectivelyUnset = !Object.hasOwn(process.env, key) || existingValue === "";
|
|
4172
|
-
if (isEffectivelyUnset) {
|
|
4173
|
-
process.env[key] = parsedEnv[key];
|
|
4174
|
-
dotEnvSourcedKeys.add(key);
|
|
4175
|
-
}
|
|
4176
|
-
if (!lastReloadSnapshotSeeded && !lastReloadSnapshot.has(key)) {
|
|
4177
|
-
lastReloadSnapshot.set(key, parsedEnv[key]);
|
|
4178
|
-
}
|
|
4179
|
-
}
|
|
4180
|
-
}
|
|
4181
|
-
} catch (_e) {
|
|
4182
|
-
}
|
|
4183
|
-
}
|
|
4184
|
-
if (settings.env) {
|
|
4185
|
-
for (const [key, value] of Object.entries(settings.env)) {
|
|
4186
|
-
if (PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) {
|
|
4187
|
-
continue;
|
|
4188
|
-
}
|
|
4189
|
-
const existingValue = process.env[key];
|
|
4190
|
-
const isEffectivelyUnset = !Object.hasOwn(process.env, key) || existingValue === "";
|
|
4191
|
-
if (isEffectivelyUnset && typeof value === "string") {
|
|
4192
|
-
process.env[key] = value;
|
|
4193
|
-
settingsEnvSourcedKeys.add(key);
|
|
4194
|
-
}
|
|
4195
|
-
if (!lastReloadSnapshotSeeded && typeof value === "string" && !lastReloadSnapshot.has(key)) {
|
|
4196
|
-
lastReloadSnapshot.set(key, value);
|
|
4197
|
-
}
|
|
4198
|
-
}
|
|
4199
|
-
}
|
|
4200
|
-
lastReloadSnapshotSeeded = true;
|
|
4201
|
-
applyZubriqDefaults();
|
|
4202
|
-
}
|
|
4203
|
-
__name(loadEnvironment, "loadEnvironment");
|
|
4204
|
-
function applyZubriqDefaults() {
|
|
4205
|
-
if (process.env["ZUBRIQ_API_KEY"] && !process.env["OPENAI_API_KEY"]) {
|
|
4206
|
-
process.env["OPENAI_API_KEY"] = process.env["ZUBRIQ_API_KEY"];
|
|
4207
|
-
}
|
|
4208
|
-
if (process.env["OPENAI_API_KEY"]) {
|
|
4209
|
-
if (!process.env["OPENAI_BASE_URL"]) {
|
|
4210
|
-
process.env["OPENAI_BASE_URL"] = "https://api.zubriq.by/v1";
|
|
4211
|
-
}
|
|
4212
|
-
if (!process.env["OPENAI_MODEL"] && !process.env["QWEN_MODEL"]) {
|
|
4213
|
-
process.env["OPENAI_MODEL"] = "qwen3.6-35b";
|
|
4214
|
-
}
|
|
4215
|
-
if (!process.env["QWEN_CODE_MAX_OUTPUT_TOKENS"]) {
|
|
4216
|
-
process.env["QWEN_CODE_MAX_OUTPUT_TOKENS"] = "8192";
|
|
4217
|
-
}
|
|
4218
|
-
}
|
|
4219
|
-
}
|
|
4220
|
-
__name(applyZubriqDefaults, "applyZubriqDefaults");
|
|
4221
|
-
function reloadEnvironment(settings, workspaceCwd) {
|
|
4222
|
-
const userLevelPaths = getUserLevelEnvPaths();
|
|
4223
|
-
const envFilePaths = findEnvFiles(settings, workspaceCwd, userLevelPaths);
|
|
4224
|
-
if (process.env["CLOUD_SHELL"] === "true") {
|
|
4225
|
-
setUpCloudShellEnvironmentFromFiles(envFilePaths);
|
|
4226
|
-
}
|
|
4227
|
-
let dotEnvReadFailed = false;
|
|
4228
|
-
const newDotEnvKeys = /* @__PURE__ */ new Map();
|
|
4229
|
-
const newSettingsEnvKeys = /* @__PURE__ */ new Map();
|
|
4230
|
-
for (const envFilePath of envFilePaths) {
|
|
4231
|
-
try {
|
|
4232
|
-
const envFileContent = fs3.readFileSync(envFilePath, "utf-8");
|
|
4233
|
-
const parsedEnv = dotenv.parse(envFileContent);
|
|
4234
|
-
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
4235
|
-
const normalizedEnvFilePath = path2.normalize(envFilePath);
|
|
4236
|
-
const isHomeScopedEnvFile = userLevelPaths.has(normalizedEnvFilePath);
|
|
4237
|
-
const isQwenScopedEnvFile = isHomeScopedEnvFile || path2.basename(path2.dirname(normalizedEnvFilePath)) === QWEN_DIR;
|
|
4238
|
-
for (const key in parsedEnv) {
|
|
4239
|
-
if (!Object.hasOwn(parsedEnv, key)) continue;
|
|
4240
|
-
if (RELOAD_EXCLUDED_KEYS.has(key)) continue;
|
|
4241
|
-
if (!isHomeScopedEnvFile && PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) {
|
|
4242
|
-
continue;
|
|
4243
|
-
}
|
|
4244
|
-
if (!isQwenScopedEnvFile && excludedVars.includes(key)) continue;
|
|
4245
|
-
if (!newDotEnvKeys.has(key)) {
|
|
4246
|
-
newDotEnvKeys.set(key, parsedEnv[key]);
|
|
4247
|
-
}
|
|
4248
|
-
}
|
|
4249
|
-
} catch {
|
|
4250
|
-
dotEnvReadFailed = true;
|
|
4251
|
-
}
|
|
4252
|
-
}
|
|
4253
|
-
if (settings.env) {
|
|
4254
|
-
for (const [key, value] of Object.entries(settings.env)) {
|
|
4255
|
-
if (RELOAD_EXCLUDED_KEYS.has(key)) continue;
|
|
4256
|
-
if (PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) continue;
|
|
4257
|
-
if (typeof value !== "string") continue;
|
|
4258
|
-
const dotEnvValue = newDotEnvKeys.get(key);
|
|
4259
|
-
if (dotEnvValue !== void 0 && dotEnvValue !== "") continue;
|
|
4260
|
-
if (dotEnvReadFailed && lastReloadSnapshot.has(key)) continue;
|
|
4261
|
-
newSettingsEnvKeys.set(key, value);
|
|
4262
|
-
}
|
|
4263
|
-
}
|
|
4264
|
-
const allNewKeys = /* @__PURE__ */ new Set([
|
|
4265
|
-
...newDotEnvKeys.keys(),
|
|
4266
|
-
...newSettingsEnvKeys.keys()
|
|
4267
|
-
]);
|
|
4268
|
-
const updatedKeys = [];
|
|
4269
|
-
const removedKeys = [];
|
|
4270
|
-
if (!dotEnvReadFailed) {
|
|
4271
|
-
const previouslyKnown = /* @__PURE__ */ new Set([
|
|
4272
|
-
...lastReloadSnapshot.keys(),
|
|
4273
|
-
...dotEnvSourcedKeys,
|
|
4274
|
-
...settingsEnvSourcedKeys
|
|
4275
|
-
]);
|
|
4276
|
-
for (const key of previouslyKnown) {
|
|
4277
|
-
if (!allNewKeys.has(key) && !RELOAD_EXCLUDED_KEYS.has(key)) {
|
|
4278
|
-
delete process.env[key];
|
|
4279
|
-
removedKeys.push(key);
|
|
4280
|
-
}
|
|
4281
|
-
}
|
|
4282
|
-
}
|
|
4283
|
-
for (const [key, value] of newDotEnvKeys) {
|
|
4284
|
-
if (value === "" && newSettingsEnvKeys.has(key)) continue;
|
|
4285
|
-
if (process.env[key] !== value) {
|
|
4286
|
-
updatedKeys.push(key);
|
|
4287
|
-
}
|
|
4288
|
-
process.env[key] = value;
|
|
4289
|
-
}
|
|
4290
|
-
for (const [key, value] of newSettingsEnvKeys) {
|
|
4291
|
-
if (process.env[key] !== value) {
|
|
4292
|
-
updatedKeys.push(key);
|
|
4293
|
-
}
|
|
4294
|
-
process.env[key] = value;
|
|
4295
|
-
}
|
|
4296
|
-
if (!dotEnvReadFailed) {
|
|
4297
|
-
dotEnvSourcedKeys.clear();
|
|
4298
|
-
for (const key of newDotEnvKeys.keys()) {
|
|
4299
|
-
dotEnvSourcedKeys.add(key);
|
|
4300
|
-
}
|
|
4301
|
-
lastReloadSnapshot.clear();
|
|
4302
|
-
for (const [key, value] of newDotEnvKeys) {
|
|
4303
|
-
lastReloadSnapshot.set(key, value);
|
|
4304
|
-
}
|
|
4305
|
-
for (const [key, value] of newSettingsEnvKeys) {
|
|
4306
|
-
lastReloadSnapshot.set(key, value);
|
|
4307
|
-
}
|
|
4308
|
-
}
|
|
4309
|
-
settingsEnvSourcedKeys.clear();
|
|
4310
|
-
for (const key of newSettingsEnvKeys.keys()) {
|
|
4311
|
-
settingsEnvSourcedKeys.add(key);
|
|
4312
|
-
}
|
|
4313
|
-
return { updatedKeys, removedKeys };
|
|
4314
|
-
}
|
|
4315
|
-
__name(reloadEnvironment, "reloadEnvironment");
|
|
4316
|
-
|
|
4317
3953
|
// packages/cli/src/config/settings.ts
|
|
4318
3954
|
var debugLogger2 = createDebugLogger("SETTINGS");
|
|
4319
|
-
function getMergeStrategyForPath(
|
|
3955
|
+
function getMergeStrategyForPath(path3) {
|
|
4320
3956
|
let current = void 0;
|
|
4321
3957
|
let currentSchema = getSettingsSchema();
|
|
4322
|
-
for (const key of
|
|
3958
|
+
for (const key of path3) {
|
|
4323
3959
|
if (!currentSchema || !currentSchema[key]) {
|
|
4324
3960
|
return void 0;
|
|
4325
3961
|
}
|
|
@@ -4334,7 +3970,7 @@ function getUserSettingsPath() {
|
|
|
4334
3970
|
}
|
|
4335
3971
|
__name(getUserSettingsPath, "getUserSettingsPath");
|
|
4336
3972
|
function getUserSettingsDir() {
|
|
4337
|
-
return
|
|
3973
|
+
return path2.dirname(getUserSettingsPath());
|
|
4338
3974
|
}
|
|
4339
3975
|
__name(getUserSettingsDir, "getUserSettingsDir");
|
|
4340
3976
|
var SETTINGS_VERSION = 4;
|
|
@@ -4596,14 +4232,14 @@ var LoadedSettings = class {
|
|
|
4596
4232
|
reloadScopeFromDisk(scope) {
|
|
4597
4233
|
const file = this.forScope(scope);
|
|
4598
4234
|
try {
|
|
4599
|
-
if (!
|
|
4235
|
+
if (!fs3.existsSync(file.path)) {
|
|
4600
4236
|
file.settings = {};
|
|
4601
4237
|
file.originalSettings = {};
|
|
4602
4238
|
file.rawJson = void 0;
|
|
4603
4239
|
this._merged = this.computeMergedSettings();
|
|
4604
4240
|
return;
|
|
4605
4241
|
}
|
|
4606
|
-
const content =
|
|
4242
|
+
const content = fs3.readFileSync(file.path, "utf-8");
|
|
4607
4243
|
const parsed = JSON.parse((0, import_strip_json_comments.default)(content));
|
|
4608
4244
|
if (parsed && typeof parsed === "object" && !Array.isArray(parsed)) {
|
|
4609
4245
|
const resolved = resolveEnvVarsInObject(
|
|
@@ -4660,33 +4296,33 @@ function createMinimalSettings() {
|
|
|
4660
4296
|
}
|
|
4661
4297
|
__name(createMinimalSettings, "createMinimalSettings");
|
|
4662
4298
|
function detectQwenHomeRedirectWithoutMigration(activeUserSettingsPath) {
|
|
4663
|
-
if (!
|
|
4299
|
+
if (!process.env["QWEN_HOME"]) {
|
|
4664
4300
|
return null;
|
|
4665
4301
|
}
|
|
4666
4302
|
const activeQwenDir = Storage.getGlobalQwenDir();
|
|
4667
|
-
const savedQwenHome =
|
|
4668
|
-
delete
|
|
4303
|
+
const savedQwenHome = process.env["QWEN_HOME"];
|
|
4304
|
+
delete process.env["QWEN_HOME"];
|
|
4669
4305
|
let legacyQwenDir;
|
|
4670
4306
|
try {
|
|
4671
4307
|
legacyQwenDir = Storage.getGlobalQwenDir();
|
|
4672
4308
|
} finally {
|
|
4673
|
-
|
|
4309
|
+
process.env["QWEN_HOME"] = savedQwenHome;
|
|
4674
4310
|
}
|
|
4675
|
-
if (
|
|
4311
|
+
if (path2.resolve(activeQwenDir) === path2.resolve(legacyQwenDir)) {
|
|
4676
4312
|
return null;
|
|
4677
4313
|
}
|
|
4678
|
-
if (
|
|
4314
|
+
if (fs3.existsSync(activeUserSettingsPath)) {
|
|
4679
4315
|
return null;
|
|
4680
4316
|
}
|
|
4681
|
-
const legacyUserSettings =
|
|
4682
|
-
if (!
|
|
4317
|
+
const legacyUserSettings = path2.join(legacyQwenDir, "settings.json");
|
|
4318
|
+
if (!fs3.existsSync(legacyUserSettings)) {
|
|
4683
4319
|
return null;
|
|
4684
4320
|
}
|
|
4685
4321
|
return `QWEN_HOME points to "${activeQwenDir}" but no settings.json was found there. Existing config remains at "${legacyQwenDir}" \u2014 OAuth tokens, settings, memory, extensions, and skills are not auto-migrated. Copy them manually if you want them to apply at the new location.`;
|
|
4686
4322
|
}
|
|
4687
4323
|
__name(detectQwenHomeRedirectWithoutMigration, "detectQwenHomeRedirectWithoutMigration");
|
|
4688
4324
|
var CORRUPTED_SUFFIX = ".corrupted";
|
|
4689
|
-
function loadSettings(workspaceDir =
|
|
4325
|
+
function loadSettings(workspaceDir = process.cwd(), consumeCorruptionEnvVars = true) {
|
|
4690
4326
|
const opts = typeof consumeCorruptionEnvVars === "object" ? consumeCorruptionEnvVars : { consumeCorruptionEnvVars };
|
|
4691
4327
|
preResolveHomeEnvOverrides();
|
|
4692
4328
|
const userSettingsPath = getUserSettingsPath();
|
|
@@ -4699,21 +4335,21 @@ function loadSettings(workspaceDir = process2.cwd(), consumeCorruptionEnvVars =
|
|
|
4699
4335
|
const systemSettingsPath = getSystemSettingsPath();
|
|
4700
4336
|
const systemDefaultsPath = getSystemDefaultsPath();
|
|
4701
4337
|
const migratedInMemorScopes = /* @__PURE__ */ new Set();
|
|
4702
|
-
const resolvedWorkspaceDir =
|
|
4703
|
-
const resolvedHomeDir =
|
|
4338
|
+
const resolvedWorkspaceDir = path2.resolve(workspaceDir);
|
|
4339
|
+
const resolvedHomeDir = path2.resolve(homedir());
|
|
4704
4340
|
let realWorkspaceDir = resolvedWorkspaceDir;
|
|
4705
4341
|
try {
|
|
4706
|
-
realWorkspaceDir =
|
|
4342
|
+
realWorkspaceDir = fs3.realpathSync(resolvedWorkspaceDir);
|
|
4707
4343
|
} catch (_e) {
|
|
4708
4344
|
}
|
|
4709
|
-
const realHomeDir =
|
|
4345
|
+
const realHomeDir = fs3.realpathSync(resolvedHomeDir);
|
|
4710
4346
|
const workspaceSettingsPath = new Storage(
|
|
4711
4347
|
workspaceDir
|
|
4712
4348
|
).getWorkspaceSettingsPath();
|
|
4713
4349
|
const loadAndMigrate = /* @__PURE__ */ __name((filePath, scope) => {
|
|
4714
4350
|
try {
|
|
4715
|
-
if (
|
|
4716
|
-
const content =
|
|
4351
|
+
if (fs3.existsSync(filePath)) {
|
|
4352
|
+
const content = fs3.readFileSync(filePath, "utf-8");
|
|
4717
4353
|
let rawSettings;
|
|
4718
4354
|
const corruptedPath = `${filePath}${CORRUPTED_SUFFIX}`;
|
|
4719
4355
|
let corruptedSaved = false;
|
|
@@ -4725,7 +4361,7 @@ function loadSettings(workspaceDir = process2.cwd(), consumeCorruptionEnvVars =
|
|
|
4725
4361
|
`Settings file ${filePath} has invalid JSON (${getErrorMessage(parseError)}). Resetting to empty settings.`
|
|
4726
4362
|
);
|
|
4727
4363
|
try {
|
|
4728
|
-
|
|
4364
|
+
fs3.copyFileSync(filePath, corruptedPath);
|
|
4729
4365
|
corruptedSaved = true;
|
|
4730
4366
|
} catch (copyError) {
|
|
4731
4367
|
debugLogger2.warn(
|
|
@@ -4737,7 +4373,7 @@ function loadSettings(workspaceDir = process2.cwd(), consumeCorruptionEnvVars =
|
|
|
4737
4373
|
debugLogger2.warn(warningMsg);
|
|
4738
4374
|
if (corruptedSaved) {
|
|
4739
4375
|
try {
|
|
4740
|
-
|
|
4376
|
+
fs3.writeFileSync(filePath, "{}", "utf-8");
|
|
4741
4377
|
} catch {
|
|
4742
4378
|
}
|
|
4743
4379
|
}
|
|
@@ -4749,12 +4385,12 @@ function loadSettings(workspaceDir = process2.cwd(), consumeCorruptionEnvVars =
|
|
|
4749
4385
|
};
|
|
4750
4386
|
}
|
|
4751
4387
|
}
|
|
4752
|
-
const envCorruptedPath =
|
|
4388
|
+
const envCorruptedPath = process.env[ENV_CORRUPTED_PATH];
|
|
4753
4389
|
if ((opts.consumeCorruptionEnvVars ?? true) && envCorruptedPath && envCorruptedPath === corruptedPath && scope === "User" /* User */) {
|
|
4754
4390
|
corruptedSaved = true;
|
|
4755
|
-
recoveredFromEnvVar =
|
|
4756
|
-
delete
|
|
4757
|
-
delete
|
|
4391
|
+
recoveredFromEnvVar = process.env[ENV_WAS_RECOVERED] === "1";
|
|
4392
|
+
delete process.env[ENV_CORRUPTED_PATH];
|
|
4393
|
+
delete process.env[ENV_WAS_RECOVERED];
|
|
4758
4394
|
}
|
|
4759
4395
|
if (typeof rawSettings !== "object" || rawSettings === null || Array.isArray(rawSettings)) {
|
|
4760
4396
|
settingsErrors.push({
|
|
@@ -4949,9 +4585,9 @@ function createSettingsUpdate(key, value) {
|
|
|
4949
4585
|
__name(createSettingsUpdate, "createSettingsUpdate");
|
|
4950
4586
|
function saveSettings(settingsFile, updates = settingsFile.originalSettings, replacePath = [], opts = {}) {
|
|
4951
4587
|
try {
|
|
4952
|
-
const dirPath =
|
|
4953
|
-
if (!
|
|
4954
|
-
|
|
4588
|
+
const dirPath = path2.dirname(settingsFile.path);
|
|
4589
|
+
if (!fs3.existsSync(dirPath)) {
|
|
4590
|
+
fs3.mkdirSync(dirPath, { recursive: true });
|
|
4955
4591
|
}
|
|
4956
4592
|
const written = updateSettingsFilePreservingFormat(
|
|
4957
4593
|
settingsFile.path,
|
|
@@ -5004,15 +4640,6 @@ export {
|
|
|
5004
4640
|
backupSettingsFile,
|
|
5005
4641
|
restoreSettingsFromBackup,
|
|
5006
4642
|
cleanupSettingsBackup,
|
|
5007
|
-
SETTINGS_DIRECTORY_NAME,
|
|
5008
|
-
preResolveHomeEnvOverrides,
|
|
5009
|
-
resetHomeEnvBootstrapForTesting,
|
|
5010
|
-
resetEnvironmentTrackingForTesting,
|
|
5011
|
-
getHomeEnvFallbackVars,
|
|
5012
|
-
findEnvFiles,
|
|
5013
|
-
setUpCloudShellEnvironment,
|
|
5014
|
-
loadEnvironment,
|
|
5015
|
-
reloadEnvironment,
|
|
5016
4643
|
getUserSettingsPath,
|
|
5017
4644
|
getUserSettingsDir,
|
|
5018
4645
|
SETTINGS_VERSION,
|