@qwen-code/qwen-code 0.19.7 → 0.19.8-nightly.20260710.205430235
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/bundled/qc-helper/SKILL.md +1 -0
- package/bundled/qc-helper/docs/configuration/auth.md +40 -55
- package/bundled/qc-helper/docs/configuration/model-providers.md +224 -218
- package/bundled/qc-helper/docs/configuration/settings.md +43 -36
- package/bundled/qc-helper/docs/features/_meta.ts +1 -0
- package/bundled/qc-helper/docs/features/channels/overview.md +20 -12
- package/bundled/qc-helper/docs/features/channels/plugins.md +1 -0
- package/bundled/qc-helper/docs/features/code-review.md +2 -1
- package/bundled/qc-helper/docs/features/commands.md +39 -38
- package/bundled/qc-helper/docs/features/computer-use.md +77 -0
- package/bundled/qc-helper/docs/features/hooks.md +36 -34
- package/bundled/qc-helper/docs/features/memory.md +1 -1
- package/bundled/qc-helper/docs/features/tool-use-summaries.md +19 -23
- package/bundled/qc-helper/docs/qwen-serve.md +22 -12
- package/bundled/qc-helper/docs/reference/keyboard-shortcuts.md +1 -1
- package/bundled/review/DESIGN.md +14 -13
- package/bundled/review/SKILL.md +38 -61
- package/chunks/{MaxSizedBox-XY5LIO5O.js → MaxSizedBox-LOFYQFYJ.js} +13 -14
- package/chunks/{StandaloneSessionPicker-APISIRJZ.js → StandaloneSessionPicker-U5OQBGEB.js} +31 -29
- package/chunks/{acpAgent-MMOSC2YA.js → acpAgent-SDIFRIED.js} +637 -131
- package/chunks/{agent-TKIBLLQT.js → agent-JIBBVHNQ.js} +10 -10
- package/chunks/{agent-headless-VLX4C7KX.js → agent-headless-6LGZYJYU.js} +10 -10
- package/chunks/{anthropicContentGenerator-AKYPSZIV.js → anthropicContentGenerator-55REPTTF.js} +30 -3
- package/chunks/{artifact-tool-D233YJFH.js → artifact-tool-EIN46DPM.js} +1 -1
- package/chunks/{askUserQuestion-MKL5ZTMC.js → askUserQuestion-6YX6ZRX7.js} +1 -1
- package/chunks/{bridge-BCU73DZO.js → bridge-HVPFYNM4.js} +17 -16
- package/chunks/{ca-HCMB2I54.js → ca-MULEGDVS.js} +89 -5
- package/chunks/{channel-worker-supervisor-CRCVYQIE.js → channel-worker-supervisor-OPXXT4JK.js} +20 -3
- package/chunks/{chunk-DGHJTO2K.js → chunk-2AF26HVM.js} +31 -2
- package/chunks/{chunk-3B26UVCX.js → chunk-2GUVUHJY.js} +6 -4
- package/chunks/{chunk-FV7425LN.js → chunk-2SZOMGOR.js} +4 -1
- package/chunks/{chunk-CNSF3WO5.js → chunk-32KS5XSX.js} +3 -3
- package/chunks/{chunk-4UCTWSTP.js → chunk-34UUM3IN.js} +1 -1
- package/chunks/{chunk-G7ZG7CA6.js → chunk-3UP777ZS.js} +8 -7
- package/chunks/{chunk-MIG5SQNL.js → chunk-4CSVIZLT.js} +4 -4
- package/chunks/{chunk-GD236YPV.js → chunk-4ONWIT5C.js} +1 -1
- package/chunks/{chunk-4ZJIPVPB.js → chunk-4XK7TNBP.js} +8 -8
- package/chunks/{chunk-I4A4K72C.js → chunk-5F2H3PXG.js} +446 -232
- package/chunks/chunk-5HOF2K5U.js +19 -0
- package/chunks/{chunk-GMOWQOQQ.js → chunk-5ZVIYNLN.js} +228 -36
- package/chunks/chunk-6O6Z2I5Q.js +292 -0
- package/chunks/{chunk-RYFZCUJO.js → chunk-6QKT5VNZ.js} +14 -6
- package/chunks/{chunk-SD4N3QJ2.js → chunk-6ZPSVWLF.js} +61 -17
- package/chunks/{chunk-X265R5C6.js → chunk-7YGSDQ5J.js} +2 -2
- package/chunks/{chunk-PRDFOIZF.js → chunk-A6KEUFJO.js} +32 -5
- package/chunks/{chunk-OWVIH4HY.js → chunk-B5OAMPJ5.js} +389 -87
- package/chunks/{chunk-ME3YSROJ.js → chunk-CV2AT2WJ.js} +22 -10
- package/chunks/{chunk-U4FRHCLA.js → chunk-DDKUYKHA.js} +1912 -201
- package/chunks/{chunk-YDSYD7UI.js → chunk-E3SA2LY4.js} +2 -2
- package/chunks/{chunk-6IAWPIQ6.js → chunk-EDM5O3SX.js} +2 -2
- package/chunks/{chunk-CISB3IQF.js → chunk-FONJQQWI.js} +65 -6
- package/chunks/{chunk-FRFFNYUY.js → chunk-G3WIMNL4.js} +3 -3
- package/chunks/{chunk-B34OV7K2.js → chunk-GGQQA4JW.js} +13 -0
- package/chunks/chunk-GLE2YUPU.js +34 -0
- package/chunks/{chunk-MJI36HER.js → chunk-GOTMC3BX.js} +1 -1
- package/chunks/{chunk-RFIL6REB.js → chunk-GRB4QSBD.js} +168 -31
- package/chunks/chunk-GVVY7GSP.js +38 -0
- package/chunks/{chunk-7JGISHHZ.js → chunk-HDEUQRAR.js} +14 -156
- package/chunks/{chunk-NZEGNV4V.js → chunk-HPRI22FZ.js} +6 -6
- package/chunks/{chunk-STAZRKOT.js → chunk-I34IHZFJ.js} +117 -459
- package/chunks/{chunk-JF7DFPQ5.js → chunk-I3MBKL6Z.js} +12 -2
- package/chunks/{chunk-DNV4FSN5.js → chunk-I5XN6KDI.js} +21 -4
- package/chunks/{chunk-VZ7HY3YU.js → chunk-IAMRWMFU.js} +1 -1
- package/chunks/{chunk-44NROQYV.js → chunk-JOQMY62N.js} +1 -1
- package/chunks/{chunk-VQWAZSXN.js → chunk-JW4IKIZ2.js} +57 -35
- package/chunks/{chunk-SAIILPQ3.js → chunk-KJMYXFUR.js} +3 -1
- package/chunks/{chunk-AFOLR6YL.js → chunk-KQ6MKCFE.js} +102 -16
- package/chunks/{chunk-X3YGAX7V.js → chunk-KS2FRTYI.js} +2 -0
- package/chunks/{chunk-IUE7YWC3.js → chunk-LE7EF36E.js} +7 -7
- package/chunks/{chunk-B4U2M63D.js → chunk-LRY7HD3Q.js} +2101 -11
- package/chunks/{chunk-PUQLHSQ2.js → chunk-ME7E6WZB.js} +6 -8
- package/chunks/{chunk-LEIJKM7Q.js → chunk-MEK7ZRJ3.js} +1 -1
- package/chunks/{chunk-AJBEAUIS.js → chunk-MG2TNCRX.js} +4 -3
- package/chunks/{chunk-GL5TV7B5.js → chunk-MSMQURDV.js} +21 -5
- package/chunks/{chunk-6BN7NZ5Z.js → chunk-NXDJLKKX.js} +4 -6
- package/chunks/{chunk-FEJ2FZ3U.js → chunk-NY2ZOFMM.js} +1 -1
- package/chunks/{chunk-QZF5U5KA.js → chunk-NY5BE643.js} +8 -8
- package/chunks/{chunk-4RQIB5UZ.js → chunk-O2YT7VB4.js} +0 -34
- package/chunks/{chunk-4KJ2BPIT.js → chunk-OACJLMLD.js} +2 -38
- package/chunks/chunk-PCWSPWXZ.js +168 -0
- package/chunks/{chunk-XPJH4PKR.js → chunk-PJ74K3DH.js} +1 -1
- package/chunks/{chunk-FTFXDZYI.js → chunk-PW7VWRLX.js} +45 -29
- package/chunks/chunk-R3SLDK6Y.js +468 -0
- package/chunks/{chunk-4O344UEE.js → chunk-SDJOZOYY.js} +38 -18
- package/chunks/{chunk-ALZ75L2X.js → chunk-SMYIBRAA.js} +412 -376
- package/chunks/{chunk-CCGOFQV3.js → chunk-SS5P6JM6.js} +6 -5
- package/chunks/{chunk-AIY5UTFI.js → chunk-T3XHYGMG.js} +925 -2872
- package/chunks/{chunk-Q6OEPOOC.js → chunk-TB6GWNV4.js} +1 -1
- package/chunks/{chunk-24XYI5EI.js → chunk-TERKDCOZ.js} +3 -3
- package/chunks/chunk-TVO5C767.js +159 -0
- package/chunks/{chunk-TBAZMRW3.js → chunk-TVW53EK7.js} +1 -1
- package/chunks/chunk-TX5QZYK6.js +296 -0
- package/chunks/{chunk-JD33UY7E.js → chunk-TZRVTPJ6.js} +15 -9
- package/chunks/{chunk-65CFHNSE.js → chunk-UAFB2DNB.js} +59 -59
- package/chunks/{chunk-QAKFYMJI.js → chunk-UOXLB2LY.js} +152 -17
- package/chunks/chunk-V35MD7KN.js +13 -0
- package/chunks/{chunk-XSAFNANZ.js → chunk-VWDJHVXM.js} +12 -12
- package/chunks/{chunk-XISQIIT7.js → chunk-W77ZLCSX.js} +1 -1
- package/chunks/{chunk-BWVQN2HV.js → chunk-WTEIUA2V.js} +4 -4
- package/chunks/{chunk-TDGF35EN.js → chunk-XOHNA2S6.js} +1 -1
- package/chunks/{chunk-HJ3GX3Y3.js → chunk-XZVUZSDG.js} +25 -11
- package/chunks/{chunk-ADZG46HR.js → chunk-YHGCTQG3.js} +1 -1
- package/chunks/{chunk-2NPS2UDH.js → chunk-YUNPEB3Q.js} +478 -43
- package/chunks/chunk-Z3I3QJK3.js +47 -0
- package/chunks/{chunk-P7I3D7FM.js → chunk-Z466FBSA.js} +1 -1
- package/chunks/{chunk-YEGT55NW.js → chunk-ZDAZSR2O.js} +3009 -1220
- package/chunks/{chunk-VEB3NYSO.js → chunk-ZJQBTFJ6.js} +6 -1
- package/chunks/chunk-ZL5HN75Q.js +61 -0
- package/chunks/{computer-use-X4KUU3NM.js → computer-use-IW5XBECT.js} +10 -10
- package/chunks/{contextCommand-LAYJZF7H.js → contextCommand-4QPLK2SH.js} +14 -14
- package/chunks/create-sub-session-7JK3EYWA.js +212 -0
- package/chunks/create-sub-session-EVYZYAE3.js +364 -0
- package/chunks/{cron-create-JSXEIPVS.js → cron-create-2CCO2PW6.js} +2 -2
- package/chunks/{cron-delete-OIFVEPGU.js → cron-delete-ETVTP5IV.js} +2 -2
- package/chunks/{cron-list-D4ZX4IOE.js → cron-list-FS3KWOY5.js} +2 -2
- package/chunks/{daemon-F3I2RXP6.js → daemon-NNUYIBWA.js} +461 -0
- package/chunks/{daemon-status-provider-XSAFKVDS.js → daemon-status-provider-3EPG6BXX.js} +21 -19
- package/chunks/{de-PLLFDERI.js → de-QRG6J2CM.js} +89 -5
- package/chunks/{dist-YTRKAVUB.js → dist-3EIIFOJV.js} +1 -1
- package/chunks/{dist-PKFTNUHO.js → dist-7F5GWZDZ.js} +2 -1
- package/chunks/{dist-FQ5WRJPL.js → dist-CBJ7OJ5R.js} +2 -2
- package/chunks/{dist-OT7G2WNM.js → dist-LIFJ2YAI.js} +1 -1
- package/chunks/{dist-573HNSVO.js → dist-OKXOQ63L.js} +2 -1
- package/chunks/{dist-IMFFBMAT.js → dist-SU5LY5R4.js} +3 -1
- package/chunks/{earlyInputCapture-AERYYGXE.js → earlyInputCapture-HP5XAS7A.js} +10 -10
- package/chunks/{edit-WZTZDGCI.js → edit-MDICC6KH.js} +11 -11
- package/chunks/{en-GA2RMXY5.js → en-HF3KFWZG.js} +91 -5
- package/chunks/{enter-worktree-DEPXBJEL.js → enter-worktree-JWTRNEN4.js} +10 -10
- package/chunks/{enterPlanMode-JFGXZHHJ.js → enterPlanMode-GMRZMTBQ.js} +10 -10
- package/chunks/environment-2CJAFOFN.js +88 -0
- package/chunks/{errors-GMZL4QV7.js → errors-UZOVFD2U.js} +13 -13
- package/chunks/{exit-worktree-Y7XBK3VV.js → exit-worktree-QQGEG343.js} +10 -10
- package/chunks/{exitPlanMode-WQQER65F.js → exitPlanMode-YK2JVAAB.js} +10 -10
- package/chunks/{fast-path-W2U6XDNO.js → fast-path-6SD4JNQW.js} +12 -3
- package/chunks/{fast-path-settings-RCRXH2JG.js → fast-path-settings-RAQGCIT7.js} +3 -2
- package/chunks/{fr-GWNQG4XH.js → fr-RSCO6HHD.js} +89 -5
- package/chunks/{gemini-T4WX6SRW.js → gemini-TFQXPUZB.js} +436 -140
- package/chunks/{geminiContentGenerator-MKQACXEJ.js → geminiContentGenerator-LJ2BNXHX.js} +1 -1
- package/chunks/{glob-4KKSHZDF.js → glob-3IJ6JR5W.js} +10 -10
- package/chunks/{grep-GHRYXSLZ.js → grep-UFZ2RFQZ.js} +10 -10
- package/chunks/{handleAutoUpdate-HN7ZOSXY.js → handleAutoUpdate-TEZC5ZIR.js} +17 -13
- package/chunks/i18n-5QEODTJV.js +84 -0
- package/chunks/{initializer-SRN3IM42.js → initializer-222MPCLQ.js} +18 -16
- package/chunks/installationInfo-OZ62OHZ2.js +65 -0
- package/chunks/{ja-2HOTA47X.js → ja-RRFGG2DC.js} +89 -5
- package/chunks/{list-INTVXUPA.js → list-BN5VBIIE.js} +20 -18
- package/chunks/{loadedSettingsAdapter-QVHHQPGM.js → loadedSettingsAdapter-EHTUJRFB.js} +18 -16
- package/chunks/{loop-wakeup-OHWEMFP5.js → loop-wakeup-SR2KWT4B.js} +3 -3
- package/chunks/{ls-L654WOAT.js → ls-RUBQK5Q2.js} +2 -2
- package/chunks/{lsp-M35KE54Y.js → lsp-DUTVY2ZA.js} +3 -5
- package/chunks/{mcp-7V4T46RG.js → mcp-OPGHD26Y.js} +18 -16
- package/chunks/{monitor-464OY2UE.js → monitor-WXBDVYYV.js} +10 -10
- package/chunks/{nonInteractiveCli-LJEEODU2.js → nonInteractiveCli-CWIBGJ4U.js} +54 -49
- package/chunks/{notebook-edit-BLJYCNDO.js → notebook-edit-T7P7M73F.js} +11 -11
- package/chunks/{openaiContentGenerator-PFF6HYB2.js → openaiContentGenerator-OES264C3.js} +7 -7
- package/chunks/{pidfile-LIBUENIV.js → pidfile-LJ3NLS2P.js} +10 -10
- package/chunks/{pt-2THT3YHA.js → pt-D4CG46JM.js} +89 -5
- package/chunks/{qwenContentGenerator-SUUHZ6CR.js → qwenContentGenerator-QJ67LAJ5.js} +12 -12
- package/chunks/{read-file-L7TBQVX7.js → read-file-KZD7TLU7.js} +5 -5
- package/chunks/{read-mcp-resource-CNQHBSJM.js → read-mcp-resource-Q56IMYOH.js} +1 -1
- package/chunks/{record-artifact-PP3LKHTS.js → record-artifact-GZ5D5HZX.js} +4 -4
- package/chunks/{ripGrep-CKKX3GRB.js → ripGrep-KUJLX75U.js} +10 -10
- package/chunks/{ru-Z67YJHBG.js → ru-O2QUEL22.js} +89 -5
- package/chunks/{run-qwen-serve-5OKADVLE.js → run-qwen-serve-M52KVRGI.js} +664 -153
- package/chunks/{scheduler-ZRW3AIDU.js → scheduler-FFATTAYZ.js} +10 -10
- package/chunks/{send-message-OA6MV4EU.js → send-message-HAGK3VTV.js} +2 -2
- package/chunks/{serve-36WS32W6.js → serve-B5S32524.js} +21 -18
- package/chunks/{server-M372UENX.js → server-6HK5FJMR.js} +3301 -665
- package/chunks/{session-F5KSNP2N.js → session-3WB76VTQ.js} +55 -50
- package/chunks/{settings-WFLNS3WT.js → settings-W3IX7NHK.js} +27 -23
- package/chunks/{shell-DEDSWN56.js → shell-HZIU2ZG7.js} +10 -10
- package/chunks/{skill-A2TL2NPC.js → skill-34OUFB65.js} +5 -5
- package/chunks/{spawnChannel-RQHUWTCL.js → spawnChannel-FTZJ3I5O.js} +12 -12
- package/chunks/{src-XKZMNHXS.js → src-NELBIIGI.js} +48 -10
- package/chunks/standalone-update-LICI2VSK.js +79 -0
- package/chunks/{startInteractiveUI-REKSTOHU.js → startInteractiveUI-LZEV5YI2.js} +2203 -1764
- package/chunks/stdioHelpers-CA7MG65Z.js +14 -0
- package/chunks/{syntheticOutput-F7LSDCAR.js → syntheticOutput-XFFJVCGV.js} +2 -2
- package/chunks/{task-create-RPFZNB4B.js → task-create-VINUSVBF.js} +3 -3
- package/chunks/{task-list-TGGJX7EA.js → task-list-YZ2AWQEG.js} +1 -1
- package/chunks/{task-stop-W7NGTMYQ.js → task-stop-PEXPKUW3.js} +1 -1
- package/chunks/{task-update-5WUG5MVQ.js → task-update-BHIX57YH.js} +3 -3
- package/chunks/{team-create-TBQVWAG7.js → team-create-2JS2OYSF.js} +10 -10
- package/chunks/{team-delete-UHQQ2QQX.js → team-delete-2OHXSBVS.js} +1 -1
- package/chunks/{team-plan-approval-FZPGUSHJ.js → team-plan-approval-PHLGYUY7.js} +10 -10
- package/chunks/{theme-manager-DQZVNSOC.js → theme-manager-UYXLX37P.js} +10 -10
- package/chunks/{todoWrite-C4ZAMSR3.js → todoWrite-7Q4ELT4F.js} +1 -1
- package/chunks/{tool-search-FDQ3SLNJ.js → tool-search-2MWA3GWE.js} +6 -6
- package/chunks/total-session-admission-PRZK35X4.js +72 -0
- package/chunks/{trustedFolders-Z475EIHL.js → trustedFolders-IT4JBNPG.js} +12 -12
- package/chunks/{updateCheck-E2ZX7RL7.js → updateCheck-X3ZWDO3Z.js} +17 -13
- package/chunks/updateEventEmitter-NXWTRHXY.js +10 -0
- package/chunks/{validateNonInterActiveAuth-O4ECBHQL.js → validateNonInterActiveAuth-IAOL7CM3.js} +51 -45
- package/chunks/{version-CEDD6ZZR.js → version-25QF6A5H.js} +1 -1
- package/chunks/{web-fetch-UYGMOHW4.js → web-fetch-I7FOWHGA.js} +2 -2
- package/chunks/{workflow-CQQ4J4I6.js → workflow-LZZ5U3IT.js} +11 -11
- package/chunks/{workspace-providers-status-MVYXMYDG.js → workspace-providers-status-7DTOAWEL.js} +21 -18
- package/chunks/workspace-registry-BBIPESIZ.js +76 -0
- package/chunks/{workspace-service-OMBR6ZLG.js → workspace-service-SY3P3FUY.js} +25 -23
- package/chunks/{workspace-skills-status-IMMQ7CAY.js → workspace-skills-status-GTT2A4WN.js} +20 -18
- package/chunks/{write-file-VWGY7AJP.js → write-file-M6IHNW3V.js} +11 -11
- package/chunks/{zh-7XVVRTDH.js → zh-K2EH6BDD.js} +91 -5
- package/chunks/{zh-TW-DPH554OG.js → zh-TW-4GPXJ7ZY.js} +91 -5
- package/cli.js +13 -12
- package/locales/ca.js +115 -7
- package/locales/de.js +114 -7
- package/locales/en.js +118 -7
- package/locales/fr.js +115 -7
- package/locales/ja.js +116 -6
- package/locales/pt.js +114 -7
- package/locales/ru.js +114 -7
- package/locales/zh-TW.js +114 -6
- package/locales/zh.js +114 -6
- package/package.json +3 -6
- package/web-shell/assets/{arc-C7hjaa7g.js → arc-G3HZaqaL.js} +1 -1
- package/web-shell/assets/{architectureDiagram-3BPJPVTR-pm9KtMZY.js → architectureDiagram-3BPJPVTR-DhBrwwch.js} +1 -1
- package/web-shell/assets/{blockDiagram-GPEHLZMM-CApElKsU.js → blockDiagram-GPEHLZMM-16JbbF0N.js} +1 -1
- package/web-shell/assets/{c4Diagram-AAUBKEIU-BeDe0-9N.js → c4Diagram-AAUBKEIU-DQ3-pKgc.js} +1 -1
- package/web-shell/assets/channel-CX7ZHuuL.js +1 -0
- package/web-shell/assets/{chunk-2J33WTMH-DJEkmLdl.js → chunk-2J33WTMH-ERCn30sp.js} +1 -1
- package/web-shell/assets/{chunk-4BX2VUAB-DXX8gdpe.js → chunk-4BX2VUAB-DTysfbFi.js} +1 -1
- package/web-shell/assets/{chunk-55IACEB6-DORmk1kQ.js → chunk-55IACEB6-BFGrbTBi.js} +1 -1
- package/web-shell/assets/{chunk-727SXJPM-DWmO4mCZ.js → chunk-727SXJPM-DCX4Oar-.js} +1 -1
- package/web-shell/assets/{chunk-AQP2D5EJ-C7LRaYw2.js → chunk-AQP2D5EJ-CgT6sBr3.js} +1 -1
- package/web-shell/assets/{chunk-FMBD7UC4-CCdXgyC5.js → chunk-FMBD7UC4-C1Uuk1KV.js} +1 -1
- package/web-shell/assets/{chunk-ND2GUHAM-SyL_xvWc.js → chunk-ND2GUHAM-DajgESiu.js} +1 -1
- package/web-shell/assets/{chunk-QZHKN3VN-BzOuCKxa.js → chunk-QZHKN3VN-DLJSvy9X.js} +1 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-B-oT3UI8.js +1 -0
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-B-oT3UI8.js +1 -0
- package/web-shell/assets/{cose-bilkent-S5V4N54A-BMPWyDKc.js → cose-bilkent-S5V4N54A-CH3w3qs7.js} +1 -1
- package/web-shell/assets/{dagre-BM42HDAG-B_GnPWik.js → dagre-BM42HDAG-BloXan9B.js} +1 -1
- package/web-shell/assets/{diagram-2AECGRRQ-fJqMc3S_.js → diagram-2AECGRRQ-BbZiGcmK.js} +1 -1
- package/web-shell/assets/{diagram-5GNKFQAL-ximV3O9D.js → diagram-5GNKFQAL-GQlYvLJv.js} +1 -1
- package/web-shell/assets/{diagram-KO2AKTUF-2vVyjzqw.js → diagram-KO2AKTUF-CtIBvVq3.js} +1 -1
- package/web-shell/assets/{diagram-LMA3HP47-Dckcx1sT.js → diagram-LMA3HP47-D5TBo9a2.js} +1 -1
- package/web-shell/assets/{diagram-OG6HWLK6-BAVv47ga.js → diagram-OG6HWLK6-N0gQhw6R.js} +1 -1
- package/web-shell/assets/{erDiagram-TEJ5UH35-Bn3nf5J0.js → erDiagram-TEJ5UH35-zab9vDj3.js} +1 -1
- package/web-shell/assets/{flowDiagram-I6XJVG4X-BIbGF9JT.js → flowDiagram-I6XJVG4X-BnnjtWJa.js} +1 -1
- package/web-shell/assets/{ganttDiagram-6RSMTGT7-CDbhb3AH.js → ganttDiagram-6RSMTGT7-2T0SQU4f.js} +1 -1
- package/web-shell/assets/{gitGraphDiagram-PVQCEYII-CbKG1a_w.js → gitGraphDiagram-PVQCEYII-DAD6_que.js} +1 -1
- package/web-shell/assets/index-XLkWfLja.css +5 -0
- package/web-shell/assets/index-srlTR1Jg.js +786 -0
- package/web-shell/assets/{infoDiagram-5YYISTIA-DUFxTy8m.js → infoDiagram-5YYISTIA-C-j8d0xO.js} +1 -1
- package/web-shell/assets/{ishikawaDiagram-YF4QCWOH-D69hrBG8.js → ishikawaDiagram-YF4QCWOH-D97bAKoT.js} +1 -1
- package/web-shell/assets/{journeyDiagram-JHISSGLW-DsvEw51Y.js → journeyDiagram-JHISSGLW-BJAHfJmm.js} +1 -1
- package/web-shell/assets/{kanban-definition-UN3LZRKU-lFFjZEYd.js → kanban-definition-UN3LZRKU-CZgR5aac.js} +1 -1
- package/web-shell/assets/{linear-Bo5bWzvo.js → linear-DOd4kYhA.js} +1 -1
- package/web-shell/assets/{mermaid.core-C_HKMJx5.js → mermaid.core-BBaplnXA.js} +5 -5
- package/web-shell/assets/{mindmap-definition-RKZ34NQL-DlV-NUTs.js → mindmap-definition-RKZ34NQL-IhBF_BR5.js} +1 -1
- package/web-shell/assets/{pieDiagram-4H26LBE5-B2e6FH2a.js → pieDiagram-4H26LBE5-B4R4sYyH.js} +1 -1
- package/web-shell/assets/{quadrantDiagram-W4KKPZXB-D75kSk-b.js → quadrantDiagram-W4KKPZXB-DKd1SJ61.js} +1 -1
- package/web-shell/assets/{requirementDiagram-4Y6WPE33-CQ6xakhM.js → requirementDiagram-4Y6WPE33-Cw96V0Xb.js} +1 -1
- package/web-shell/assets/{sankeyDiagram-5OEKKPKP-J_XTKrcY.js → sankeyDiagram-5OEKKPKP-C6ne_yWi.js} +1 -1
- package/web-shell/assets/{sequenceDiagram-3UESZ5HK-D7jTcBtf.js → sequenceDiagram-3UESZ5HK-CCyp4PDp.js} +1 -1
- package/web-shell/assets/{stateDiagram-AJRCARHV-CrlM_OT3.js → stateDiagram-AJRCARHV-DHvIqTmx.js} +1 -1
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-DvFhmpwA.js +1 -0
- package/web-shell/assets/{timeline-definition-PNZ67QCA-5oZi76Ef.js → timeline-definition-PNZ67QCA-amb3n9zH.js} +1 -1
- package/web-shell/assets/{vennDiagram-CIIHVFJN-DO5YptPK.js → vennDiagram-CIIHVFJN-Abf2qRFJ.js} +1 -1
- package/web-shell/assets/{wardley-L42UT6IY-4t1eJDvM.js → wardley-L42UT6IY-BBlOp1av.js} +1 -1
- package/web-shell/assets/{wardleyDiagram-YWT4CUSO-DKZc661S.js → wardleyDiagram-YWT4CUSO-gE_sZ0Ak.js} +1 -1
- package/web-shell/assets/{xychartDiagram-2RQKCTM6-su9hp08G.js → xychartDiagram-2RQKCTM6-BwOni53i.js} +1 -1
- package/web-shell/index.html +16 -4
- package/chunks/chunk-6SHO7WFF.js +0 -79
- package/chunks/chunk-IFEWJXFS.js +0 -37
- package/node_modules/@qwen-code/audio-capture/dist/index.d.ts +0 -35
- package/node_modules/@qwen-code/audio-capture/dist/index.js +0 -48
- package/node_modules/@qwen-code/audio-capture/dist/index.js.map +0 -1
- package/node_modules/@qwen-code/audio-capture/dist/platform.d.ts +0 -7
- package/node_modules/@qwen-code/audio-capture/dist/platform.js +0 -18
- package/node_modules/@qwen-code/audio-capture/dist/platform.js.map +0 -1
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/LICENSE +0 -21
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/README.md +0 -58
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/SECURITY.md +0 -5
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/bin.js +0 -84
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/build-test.js +0 -19
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/index.js +0 -6
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/node-gyp-build.js +0 -207
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/optional.js +0 -7
- package/node_modules/@qwen-code/audio-capture/node_modules/node-gyp-build/package.json +0 -43
- package/node_modules/@qwen-code/audio-capture/package.json +0 -30
- package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-arm64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/darwin-x64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/linux-arm64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/linux-x64/@qwen-code+audio-capture.node +0 -0
- package/node_modules/@qwen-code/audio-capture/prebuilds/win32-x64/@qwen-code+audio-capture.node +0 -0
- package/web-shell/assets/channel-BNf1dW-j.js +0 -1
- package/web-shell/assets/classDiagram-4FO5ZUOK-uOIGlzgi.js +0 -1
- package/web-shell/assets/classDiagram-v2-Q7XG4LA2-uOIGlzgi.js +0 -1
- package/web-shell/assets/index-CnE2ur2L.js +0 -779
- package/web-shell/assets/index-hSKXrlSE.css +0 -5
- package/web-shell/assets/stateDiagram-v2-BHNVJYJU-Bs4TK_84.js +0 -1
- /package/chunks/{chunk-Y6Z2O3WR.js → chunk-JM7BYJO5.js} +0 -0
|
@@ -0,0 +1,468 @@
|
|
|
1
|
+
// Force strict mode and setup for ESM
|
|
2
|
+
"use strict";
|
|
3
|
+
import {
|
|
4
|
+
DEFAULT_EXCLUDED_ENV_VARS,
|
|
5
|
+
HOME_ENV_BOOTSTRAP_KEYS,
|
|
6
|
+
PROJECT_ENV_HARDCODED_EXCLUSIONS
|
|
7
|
+
} from "./chunk-Z3I3QJK3.js";
|
|
8
|
+
import {
|
|
9
|
+
isWorkspaceTrusted
|
|
10
|
+
} from "./chunk-4CSVIZLT.js";
|
|
11
|
+
import {
|
|
12
|
+
require_main
|
|
13
|
+
} from "./chunk-SKAZWEV5.js";
|
|
14
|
+
import {
|
|
15
|
+
QWEN_DIR,
|
|
16
|
+
Storage,
|
|
17
|
+
getErrorMessage
|
|
18
|
+
} from "./chunk-22MNNNXE.js";
|
|
19
|
+
import {
|
|
20
|
+
init_esbuild_shims
|
|
21
|
+
} from "./chunk-A4BMJM77.js";
|
|
22
|
+
import {
|
|
23
|
+
__name,
|
|
24
|
+
__toESM
|
|
25
|
+
} from "./chunk-J2S4EL5Y.js";
|
|
26
|
+
|
|
27
|
+
// packages/cli/src/config/environment.ts
|
|
28
|
+
init_esbuild_shims();
|
|
29
|
+
var dotenv = __toESM(require_main(), 1);
|
|
30
|
+
import * as fs from "node:fs";
|
|
31
|
+
import * as path from "node:path";
|
|
32
|
+
import * as os from "node:os";
|
|
33
|
+
var SETTINGS_DIRECTORY_NAME = QWEN_DIR;
|
|
34
|
+
var RELOAD_EXCLUDED_KEYS = /* @__PURE__ */ new Set([
|
|
35
|
+
...PROJECT_ENV_HARDCODED_EXCLUSIONS,
|
|
36
|
+
"QWEN_SERVER_TOKEN",
|
|
37
|
+
"QWEN_CLI_ENTRY",
|
|
38
|
+
"NODE_OPTIONS",
|
|
39
|
+
"NODE_PATH",
|
|
40
|
+
"NODE_TLS_REJECT_UNAUTHORIZED",
|
|
41
|
+
"LD_PRELOAD",
|
|
42
|
+
"LD_AUDIT",
|
|
43
|
+
"LD_LIBRARY_PATH",
|
|
44
|
+
"DYLD_INSERT_LIBRARIES",
|
|
45
|
+
"DYLD_LIBRARY_PATH",
|
|
46
|
+
"BASH_ENV",
|
|
47
|
+
"ENV",
|
|
48
|
+
"PATH",
|
|
49
|
+
"HOME",
|
|
50
|
+
"TMPDIR",
|
|
51
|
+
"TMP",
|
|
52
|
+
"TEMP"
|
|
53
|
+
]);
|
|
54
|
+
var dotEnvSourcedKeys = /* @__PURE__ */ new Set();
|
|
55
|
+
var settingsEnvSourcedKeys = /* @__PURE__ */ new Set();
|
|
56
|
+
var lastReloadSnapshot = /* @__PURE__ */ new Map();
|
|
57
|
+
var lastReloadSnapshotSeeded = false;
|
|
58
|
+
function getUserLevelEnvPaths() {
|
|
59
|
+
const homeDir = os.homedir();
|
|
60
|
+
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
61
|
+
const paths = /* @__PURE__ */ new Set([
|
|
62
|
+
path.normalize(path.join(homeDir, ".env")),
|
|
63
|
+
path.normalize(path.join(globalQwenDir, ".env"))
|
|
64
|
+
]);
|
|
65
|
+
const legacyQwenEnv = path.normalize(path.join(homeDir, QWEN_DIR, ".env"));
|
|
66
|
+
paths.add(legacyQwenEnv);
|
|
67
|
+
return paths;
|
|
68
|
+
}
|
|
69
|
+
__name(getUserLevelEnvPaths, "getUserLevelEnvPaths");
|
|
70
|
+
var homeEnvBootstrapped = false;
|
|
71
|
+
function preResolveHomeEnvOverrides() {
|
|
72
|
+
if (homeEnvBootstrapped) {
|
|
73
|
+
return;
|
|
74
|
+
}
|
|
75
|
+
homeEnvBootstrapped = true;
|
|
76
|
+
if (HOME_ENV_BOOTSTRAP_KEYS.every((key) => process.env[key])) {
|
|
77
|
+
return;
|
|
78
|
+
}
|
|
79
|
+
const initialQwenHome = process.env["QWEN_HOME"];
|
|
80
|
+
const initialQwenDir = Storage.getGlobalQwenDir();
|
|
81
|
+
const candidates = [path.join(initialQwenDir, ".env")];
|
|
82
|
+
if (!initialQwenHome) {
|
|
83
|
+
candidates.push(path.join(path.dirname(initialQwenDir), ".env"));
|
|
84
|
+
}
|
|
85
|
+
for (const candidate of candidates) {
|
|
86
|
+
readHomeEnvInto(candidate);
|
|
87
|
+
}
|
|
88
|
+
const discoveredQwenHome = process.env["QWEN_HOME"];
|
|
89
|
+
if (discoveredQwenHome && discoveredQwenHome !== initialQwenHome) {
|
|
90
|
+
const discoveredDir = Storage.getGlobalQwenDir();
|
|
91
|
+
if (discoveredDir !== initialQwenDir) {
|
|
92
|
+
readHomeEnvInto(path.join(discoveredDir, ".env"));
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
__name(preResolveHomeEnvOverrides, "preResolveHomeEnvOverrides");
|
|
97
|
+
function readHomeEnvInto(file) {
|
|
98
|
+
if (!fs.existsSync(file)) {
|
|
99
|
+
return;
|
|
100
|
+
}
|
|
101
|
+
try {
|
|
102
|
+
const parsed = dotenv.parse(fs.readFileSync(file, "utf-8"));
|
|
103
|
+
for (const key of PROJECT_ENV_HARDCODED_EXCLUSIONS) {
|
|
104
|
+
if (parsed[key] && !Object.hasOwn(process.env, key)) {
|
|
105
|
+
process.env[key] = parsed[key];
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
} catch (_e) {
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
__name(readHomeEnvInto, "readHomeEnvInto");
|
|
112
|
+
function resetHomeEnvBootstrapForTesting() {
|
|
113
|
+
homeEnvBootstrapped = false;
|
|
114
|
+
}
|
|
115
|
+
__name(resetHomeEnvBootstrapForTesting, "resetHomeEnvBootstrapForTesting");
|
|
116
|
+
function resetEnvironmentTrackingForTesting() {
|
|
117
|
+
dotEnvSourcedKeys.clear();
|
|
118
|
+
settingsEnvSourcedKeys.clear();
|
|
119
|
+
lastReloadSnapshot.clear();
|
|
120
|
+
lastReloadSnapshotSeeded = false;
|
|
121
|
+
}
|
|
122
|
+
__name(resetEnvironmentTrackingForTesting, "resetEnvironmentTrackingForTesting");
|
|
123
|
+
function getHomeEnvFallbackVars(onReadError) {
|
|
124
|
+
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
125
|
+
const candidates = [path.join(globalQwenDir, ".env")];
|
|
126
|
+
if (!process.env["QWEN_HOME"]) {
|
|
127
|
+
candidates.push(path.join(path.dirname(globalQwenDir), ".env"));
|
|
128
|
+
}
|
|
129
|
+
const result = {};
|
|
130
|
+
for (const candidate of candidates) {
|
|
131
|
+
if (!fs.existsSync(candidate)) {
|
|
132
|
+
continue;
|
|
133
|
+
}
|
|
134
|
+
try {
|
|
135
|
+
const parsed = dotenv.parse(fs.readFileSync(candidate, "utf-8"));
|
|
136
|
+
for (const key in parsed) {
|
|
137
|
+
if (Object.hasOwn(parsed, key) && !Object.hasOwn(process.env, key)) {
|
|
138
|
+
result[key] ??= parsed[key];
|
|
139
|
+
}
|
|
140
|
+
}
|
|
141
|
+
} catch (e) {
|
|
142
|
+
onReadError?.(
|
|
143
|
+
`Failed to read home .env candidate ${candidate}: ${getErrorMessage(e)}`
|
|
144
|
+
);
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
return result;
|
|
148
|
+
}
|
|
149
|
+
__name(getHomeEnvFallbackVars, "getHomeEnvFallbackVars");
|
|
150
|
+
function findEnvFiles(settings, startDir, userLevelPaths = getUserLevelEnvPaths()) {
|
|
151
|
+
const homeDir = os.homedir();
|
|
152
|
+
let realStartDir = path.resolve(startDir);
|
|
153
|
+
try {
|
|
154
|
+
realStartDir = fs.realpathSync(realStartDir);
|
|
155
|
+
} catch {
|
|
156
|
+
}
|
|
157
|
+
const isTrusted = isWorkspaceTrusted(
|
|
158
|
+
settings,
|
|
159
|
+
void 0,
|
|
160
|
+
realStartDir
|
|
161
|
+
).isTrusted;
|
|
162
|
+
const globalQwenDir = Storage.getGlobalQwenDir();
|
|
163
|
+
const legacyQwenDir = path.normalize(path.join(homeDir, QWEN_DIR));
|
|
164
|
+
const hasCustomConfigDir = path.normalize(globalQwenDir) !== legacyQwenDir;
|
|
165
|
+
const found = [];
|
|
166
|
+
const seen = /* @__PURE__ */ new Set();
|
|
167
|
+
const canUseEnvFile = /* @__PURE__ */ __name((filePath) => isTrusted !== false || userLevelPaths.has(path.normalize(filePath)), "canUseEnvFile");
|
|
168
|
+
const pushCandidate = /* @__PURE__ */ __name((filePath) => {
|
|
169
|
+
const normalized = path.normalize(filePath);
|
|
170
|
+
if (!seen.has(normalized) && fs.existsSync(filePath) && canUseEnvFile(filePath)) {
|
|
171
|
+
seen.add(normalized);
|
|
172
|
+
found.push(filePath);
|
|
173
|
+
return true;
|
|
174
|
+
}
|
|
175
|
+
return false;
|
|
176
|
+
}, "pushCandidate");
|
|
177
|
+
const pushHomeCandidates = /* @__PURE__ */ __name(() => {
|
|
178
|
+
const candidates = [path.join(globalQwenDir, ".env")];
|
|
179
|
+
if (hasCustomConfigDir) {
|
|
180
|
+
candidates.push(path.join(legacyQwenDir, ".env"));
|
|
181
|
+
}
|
|
182
|
+
candidates.push(path.join(homeDir, ".env"));
|
|
183
|
+
for (const candidate of candidates) {
|
|
184
|
+
pushCandidate(candidate);
|
|
185
|
+
}
|
|
186
|
+
}, "pushHomeCandidates");
|
|
187
|
+
let currentDir = realStartDir;
|
|
188
|
+
let visitedHomeDir = false;
|
|
189
|
+
while (true) {
|
|
190
|
+
if (currentDir === homeDir) {
|
|
191
|
+
visitedHomeDir = true;
|
|
192
|
+
pushHomeCandidates();
|
|
193
|
+
return found;
|
|
194
|
+
} else {
|
|
195
|
+
const geminiEnvPath = path.join(currentDir, QWEN_DIR, ".env");
|
|
196
|
+
if (pushCandidate(geminiEnvPath)) {
|
|
197
|
+
pushHomeCandidates();
|
|
198
|
+
return found;
|
|
199
|
+
}
|
|
200
|
+
const envPath = path.join(currentDir, ".env");
|
|
201
|
+
if (pushCandidate(envPath)) {
|
|
202
|
+
pushHomeCandidates();
|
|
203
|
+
return found;
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
const parentDir = path.dirname(currentDir);
|
|
207
|
+
if (parentDir === currentDir || !parentDir) {
|
|
208
|
+
if (!visitedHomeDir) {
|
|
209
|
+
pushHomeCandidates();
|
|
210
|
+
}
|
|
211
|
+
return found;
|
|
212
|
+
}
|
|
213
|
+
currentDir = parentDir;
|
|
214
|
+
}
|
|
215
|
+
}
|
|
216
|
+
__name(findEnvFiles, "findEnvFiles");
|
|
217
|
+
function setUpCloudShellEnvironment(envFilePath) {
|
|
218
|
+
if (envFilePath && fs.existsSync(envFilePath)) {
|
|
219
|
+
const envFileContent = fs.readFileSync(envFilePath);
|
|
220
|
+
const parsedEnv = dotenv.parse(envFileContent);
|
|
221
|
+
if (parsedEnv["GOOGLE_CLOUD_PROJECT"]) {
|
|
222
|
+
process.env["GOOGLE_CLOUD_PROJECT"] = parsedEnv["GOOGLE_CLOUD_PROJECT"];
|
|
223
|
+
} else {
|
|
224
|
+
process.env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
225
|
+
}
|
|
226
|
+
} else {
|
|
227
|
+
process.env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
__name(setUpCloudShellEnvironment, "setUpCloudShellEnvironment");
|
|
231
|
+
function setUpCloudShellEnvironmentInEnv(env, envFiles) {
|
|
232
|
+
for (const envFile of envFiles) {
|
|
233
|
+
if (envFile.parsedEnv["GOOGLE_CLOUD_PROJECT"]) {
|
|
234
|
+
env["GOOGLE_CLOUD_PROJECT"] = envFile.parsedEnv["GOOGLE_CLOUD_PROJECT"];
|
|
235
|
+
return;
|
|
236
|
+
}
|
|
237
|
+
}
|
|
238
|
+
env["GOOGLE_CLOUD_PROJECT"] = "cloudshell-gca";
|
|
239
|
+
}
|
|
240
|
+
__name(setUpCloudShellEnvironmentInEnv, "setUpCloudShellEnvironmentInEnv");
|
|
241
|
+
function parseEnvFiles(envFilePaths, userLevelPaths) {
|
|
242
|
+
const files = [];
|
|
243
|
+
const readFailures = [];
|
|
244
|
+
for (const envFilePath of envFilePaths) {
|
|
245
|
+
try {
|
|
246
|
+
const envFileContent = fs.readFileSync(envFilePath, "utf-8");
|
|
247
|
+
const parsedEnv = dotenv.parse(envFileContent);
|
|
248
|
+
const normalizedEnvFilePath = path.normalize(envFilePath);
|
|
249
|
+
const isHomeScopedEnvFile = userLevelPaths.has(normalizedEnvFilePath);
|
|
250
|
+
const isQwenScopedEnvFile = isHomeScopedEnvFile || path.basename(path.dirname(normalizedEnvFilePath)) === QWEN_DIR;
|
|
251
|
+
files.push({
|
|
252
|
+
parsedEnv,
|
|
253
|
+
isHomeScopedEnvFile,
|
|
254
|
+
isQwenScopedEnvFile
|
|
255
|
+
});
|
|
256
|
+
} catch (err) {
|
|
257
|
+
readFailures.push({
|
|
258
|
+
path: envFilePath,
|
|
259
|
+
error: getErrorMessage(err)
|
|
260
|
+
});
|
|
261
|
+
}
|
|
262
|
+
}
|
|
263
|
+
return { files, readFailed: readFailures.length > 0, readFailures };
|
|
264
|
+
}
|
|
265
|
+
__name(parseEnvFiles, "parseEnvFiles");
|
|
266
|
+
function canApplyParsedEnvKey(envFile, key, excludedVars, options = {}) {
|
|
267
|
+
if (!Object.hasOwn(envFile.parsedEnv, key)) return false;
|
|
268
|
+
if (options.reload && RELOAD_EXCLUDED_KEYS.has(key)) return false;
|
|
269
|
+
if (!envFile.isHomeScopedEnvFile && PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) {
|
|
270
|
+
return false;
|
|
271
|
+
}
|
|
272
|
+
return envFile.isQwenScopedEnvFile || !excludedVars.includes(key);
|
|
273
|
+
}
|
|
274
|
+
__name(canApplyParsedEnvKey, "canApplyParsedEnvKey");
|
|
275
|
+
function isEffectivelyUnset(env, key) {
|
|
276
|
+
const existingValue = env[key];
|
|
277
|
+
return !Object.hasOwn(env, key) || existingValue === "";
|
|
278
|
+
}
|
|
279
|
+
__name(isEffectivelyUnset, "isEffectivelyUnset");
|
|
280
|
+
function setRuntimeEnvIfUnset(env, key, value) {
|
|
281
|
+
if (isEffectivelyUnset(env, key)) {
|
|
282
|
+
env[key] = value;
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
__name(setRuntimeEnvIfUnset, "setRuntimeEnvIfUnset");
|
|
286
|
+
function buildRuntimeEnvironment(settings, startDir = process.cwd(), baseEnv = process.env) {
|
|
287
|
+
const userLevelPaths = getUserLevelEnvPaths();
|
|
288
|
+
const envFilePaths = findEnvFiles(settings, startDir, userLevelPaths);
|
|
289
|
+
const parsedEnvFiles = parseEnvFiles(envFilePaths, userLevelPaths);
|
|
290
|
+
const effectiveEnv = { ...baseEnv };
|
|
291
|
+
if (baseEnv["CLOUD_SHELL"] === "true") {
|
|
292
|
+
setUpCloudShellEnvironmentInEnv(effectiveEnv, parsedEnvFiles.files);
|
|
293
|
+
}
|
|
294
|
+
for (const envFile of parsedEnvFiles.files) {
|
|
295
|
+
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
296
|
+
for (const key in envFile.parsedEnv) {
|
|
297
|
+
if (!canApplyParsedEnvKey(envFile, key, excludedVars, { reload: true })) {
|
|
298
|
+
continue;
|
|
299
|
+
}
|
|
300
|
+
setRuntimeEnvIfUnset(effectiveEnv, key, envFile.parsedEnv[key]);
|
|
301
|
+
}
|
|
302
|
+
}
|
|
303
|
+
if (settings.env) {
|
|
304
|
+
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
305
|
+
for (const [key, value] of Object.entries(settings.env)) {
|
|
306
|
+
if (RELOAD_EXCLUDED_KEYS.has(key)) continue;
|
|
307
|
+
if (PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) continue;
|
|
308
|
+
if (excludedVars.includes(key)) continue;
|
|
309
|
+
if (typeof value !== "string") continue;
|
|
310
|
+
setRuntimeEnvIfUnset(effectiveEnv, key, value);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
const overlayKeys = Object.keys(effectiveEnv).filter((key) => effectiveEnv[key] !== baseEnv[key]).sort();
|
|
314
|
+
return {
|
|
315
|
+
effectiveEnv: Object.freeze({ ...effectiveEnv }),
|
|
316
|
+
overlayKeys: Object.freeze(overlayKeys),
|
|
317
|
+
envFilePaths: Object.freeze([...envFilePaths]),
|
|
318
|
+
envFileReadFailed: parsedEnvFiles.readFailed,
|
|
319
|
+
envFileReadFailures: Object.freeze([...parsedEnvFiles.readFailures])
|
|
320
|
+
};
|
|
321
|
+
}
|
|
322
|
+
__name(buildRuntimeEnvironment, "buildRuntimeEnvironment");
|
|
323
|
+
function loadEnvironment(settings, startDir = process.cwd()) {
|
|
324
|
+
const userLevelPaths = getUserLevelEnvPaths();
|
|
325
|
+
const envFilePaths = findEnvFiles(settings, startDir, userLevelPaths);
|
|
326
|
+
const parsedEnvFiles = parseEnvFiles(envFilePaths, userLevelPaths);
|
|
327
|
+
if (process.env["CLOUD_SHELL"] === "true") {
|
|
328
|
+
setUpCloudShellEnvironmentInEnv(process.env, parsedEnvFiles.files);
|
|
329
|
+
}
|
|
330
|
+
for (const envFile of parsedEnvFiles.files) {
|
|
331
|
+
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
332
|
+
for (const key in envFile.parsedEnv) {
|
|
333
|
+
if (!canApplyParsedEnvKey(envFile, key, excludedVars)) continue;
|
|
334
|
+
const existingValue = process.env[key];
|
|
335
|
+
const isEffectivelyUnset2 = !Object.hasOwn(process.env, key) || existingValue === "";
|
|
336
|
+
if (isEffectivelyUnset2) {
|
|
337
|
+
process.env[key] = envFile.parsedEnv[key];
|
|
338
|
+
dotEnvSourcedKeys.add(key);
|
|
339
|
+
}
|
|
340
|
+
if (!lastReloadSnapshotSeeded && !lastReloadSnapshot.has(key)) {
|
|
341
|
+
lastReloadSnapshot.set(key, envFile.parsedEnv[key]);
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
}
|
|
345
|
+
if (settings.env) {
|
|
346
|
+
for (const [key, value] of Object.entries(settings.env)) {
|
|
347
|
+
if (RELOAD_EXCLUDED_KEYS.has(key)) {
|
|
348
|
+
continue;
|
|
349
|
+
}
|
|
350
|
+
if (PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) {
|
|
351
|
+
continue;
|
|
352
|
+
}
|
|
353
|
+
const existingValue = process.env[key];
|
|
354
|
+
const isEffectivelyUnset2 = !Object.hasOwn(process.env, key) || existingValue === "";
|
|
355
|
+
if (isEffectivelyUnset2 && typeof value === "string") {
|
|
356
|
+
process.env[key] = value;
|
|
357
|
+
settingsEnvSourcedKeys.add(key);
|
|
358
|
+
}
|
|
359
|
+
if (!lastReloadSnapshotSeeded && typeof value === "string" && !lastReloadSnapshot.has(key)) {
|
|
360
|
+
lastReloadSnapshot.set(key, value);
|
|
361
|
+
}
|
|
362
|
+
}
|
|
363
|
+
}
|
|
364
|
+
lastReloadSnapshotSeeded = true;
|
|
365
|
+
}
|
|
366
|
+
__name(loadEnvironment, "loadEnvironment");
|
|
367
|
+
function reloadEnvironment(settings, workspaceCwd) {
|
|
368
|
+
const userLevelPaths = getUserLevelEnvPaths();
|
|
369
|
+
const envFilePaths = findEnvFiles(settings, workspaceCwd, userLevelPaths);
|
|
370
|
+
const parsedEnvFiles = parseEnvFiles(envFilePaths, userLevelPaths);
|
|
371
|
+
if (process.env["CLOUD_SHELL"] === "true") {
|
|
372
|
+
setUpCloudShellEnvironmentInEnv(process.env, parsedEnvFiles.files);
|
|
373
|
+
}
|
|
374
|
+
const dotEnvReadFailed = parsedEnvFiles.readFailed;
|
|
375
|
+
const newDotEnvKeys = /* @__PURE__ */ new Map();
|
|
376
|
+
const newSettingsEnvKeys = /* @__PURE__ */ new Map();
|
|
377
|
+
for (const envFile of parsedEnvFiles.files) {
|
|
378
|
+
const excludedVars = settings?.advanced?.excludedEnvVars || DEFAULT_EXCLUDED_ENV_VARS;
|
|
379
|
+
for (const key in envFile.parsedEnv) {
|
|
380
|
+
if (!canApplyParsedEnvKey(envFile, key, excludedVars, { reload: true })) {
|
|
381
|
+
continue;
|
|
382
|
+
}
|
|
383
|
+
if (!newDotEnvKeys.has(key)) {
|
|
384
|
+
newDotEnvKeys.set(key, envFile.parsedEnv[key]);
|
|
385
|
+
}
|
|
386
|
+
}
|
|
387
|
+
}
|
|
388
|
+
if (settings.env) {
|
|
389
|
+
for (const [key, value] of Object.entries(settings.env)) {
|
|
390
|
+
if (RELOAD_EXCLUDED_KEYS.has(key)) continue;
|
|
391
|
+
if (PROJECT_ENV_HARDCODED_EXCLUSIONS.includes(key)) continue;
|
|
392
|
+
if (typeof value !== "string") continue;
|
|
393
|
+
const dotEnvValue = newDotEnvKeys.get(key);
|
|
394
|
+
if (dotEnvValue !== void 0 && dotEnvValue !== "") continue;
|
|
395
|
+
if (dotEnvReadFailed && lastReloadSnapshot.has(key)) continue;
|
|
396
|
+
newSettingsEnvKeys.set(key, value);
|
|
397
|
+
}
|
|
398
|
+
}
|
|
399
|
+
const allNewKeys = /* @__PURE__ */ new Set([
|
|
400
|
+
...newDotEnvKeys.keys(),
|
|
401
|
+
...newSettingsEnvKeys.keys()
|
|
402
|
+
]);
|
|
403
|
+
const updatedKeys = [];
|
|
404
|
+
const removedKeys = [];
|
|
405
|
+
if (!dotEnvReadFailed) {
|
|
406
|
+
const previouslyKnown = /* @__PURE__ */ new Set([
|
|
407
|
+
...lastReloadSnapshot.keys(),
|
|
408
|
+
...dotEnvSourcedKeys,
|
|
409
|
+
...settingsEnvSourcedKeys
|
|
410
|
+
]);
|
|
411
|
+
for (const key of previouslyKnown) {
|
|
412
|
+
if (!allNewKeys.has(key) && !RELOAD_EXCLUDED_KEYS.has(key)) {
|
|
413
|
+
delete process.env[key];
|
|
414
|
+
removedKeys.push(key);
|
|
415
|
+
}
|
|
416
|
+
}
|
|
417
|
+
}
|
|
418
|
+
for (const [key, value] of newDotEnvKeys) {
|
|
419
|
+
if (value === "" && newSettingsEnvKeys.has(key)) continue;
|
|
420
|
+
if (process.env[key] !== value) {
|
|
421
|
+
updatedKeys.push(key);
|
|
422
|
+
}
|
|
423
|
+
process.env[key] = value;
|
|
424
|
+
}
|
|
425
|
+
for (const [key, value] of newSettingsEnvKeys) {
|
|
426
|
+
if (process.env[key] !== value) {
|
|
427
|
+
updatedKeys.push(key);
|
|
428
|
+
}
|
|
429
|
+
process.env[key] = value;
|
|
430
|
+
}
|
|
431
|
+
if (!dotEnvReadFailed) {
|
|
432
|
+
dotEnvSourcedKeys.clear();
|
|
433
|
+
for (const key of newDotEnvKeys.keys()) {
|
|
434
|
+
dotEnvSourcedKeys.add(key);
|
|
435
|
+
}
|
|
436
|
+
lastReloadSnapshot.clear();
|
|
437
|
+
for (const [key, value] of newDotEnvKeys) {
|
|
438
|
+
lastReloadSnapshot.set(key, value);
|
|
439
|
+
}
|
|
440
|
+
for (const [key, value] of newSettingsEnvKeys) {
|
|
441
|
+
lastReloadSnapshot.set(key, value);
|
|
442
|
+
}
|
|
443
|
+
}
|
|
444
|
+
settingsEnvSourcedKeys.clear();
|
|
445
|
+
for (const key of newSettingsEnvKeys.keys()) {
|
|
446
|
+
settingsEnvSourcedKeys.add(key);
|
|
447
|
+
}
|
|
448
|
+
return { updatedKeys, removedKeys };
|
|
449
|
+
}
|
|
450
|
+
__name(reloadEnvironment, "reloadEnvironment");
|
|
451
|
+
|
|
452
|
+
export {
|
|
453
|
+
SETTINGS_DIRECTORY_NAME,
|
|
454
|
+
preResolveHomeEnvOverrides,
|
|
455
|
+
resetHomeEnvBootstrapForTesting,
|
|
456
|
+
resetEnvironmentTrackingForTesting,
|
|
457
|
+
getHomeEnvFallbackVars,
|
|
458
|
+
findEnvFiles,
|
|
459
|
+
setUpCloudShellEnvironment,
|
|
460
|
+
buildRuntimeEnvironment,
|
|
461
|
+
loadEnvironment,
|
|
462
|
+
reloadEnvironment
|
|
463
|
+
};
|
|
464
|
+
/**
|
|
465
|
+
* @license
|
|
466
|
+
* Copyright 2025 Qwen Team
|
|
467
|
+
* SPDX-License-Identifier: Apache-2.0
|
|
468
|
+
*/
|
|
@@ -2,8 +2,20 @@
|
|
|
2
2
|
"use strict";
|
|
3
3
|
import {
|
|
4
4
|
getInstallationInfo,
|
|
5
|
+
resolveUpdateCommand
|
|
6
|
+
} from "./chunk-TX5QZYK6.js";
|
|
7
|
+
import {
|
|
5
8
|
performStandaloneUpdate
|
|
6
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-SMYIBRAA.js";
|
|
10
|
+
import {
|
|
11
|
+
updateEventEmitter
|
|
12
|
+
} from "./chunk-5HOF2K5U.js";
|
|
13
|
+
import {
|
|
14
|
+
t
|
|
15
|
+
} from "./chunk-UOXLB2LY.js";
|
|
16
|
+
import {
|
|
17
|
+
createDebugLogger
|
|
18
|
+
} from "./chunk-22MNNNXE.js";
|
|
7
19
|
import {
|
|
8
20
|
init_esbuild_shims
|
|
9
21
|
} from "./chunk-A4BMJM77.js";
|
|
@@ -14,11 +26,6 @@ import {
|
|
|
14
26
|
// packages/cli/src/utils/handleAutoUpdate.ts
|
|
15
27
|
init_esbuild_shims();
|
|
16
28
|
|
|
17
|
-
// packages/cli/src/utils/updateEventEmitter.ts
|
|
18
|
-
init_esbuild_shims();
|
|
19
|
-
import { EventEmitter } from "node:events";
|
|
20
|
-
var updateEventEmitter = new EventEmitter();
|
|
21
|
-
|
|
22
29
|
// packages/cli/src/utils/spawnWrapper.ts
|
|
23
30
|
init_esbuild_shims();
|
|
24
31
|
import { spawn } from "node:child_process";
|
|
@@ -26,6 +33,7 @@ var spawnWrapper = spawn;
|
|
|
26
33
|
|
|
27
34
|
// packages/cli/src/utils/handleAutoUpdate.ts
|
|
28
35
|
import os from "node:os";
|
|
36
|
+
var debugLogger = createDebugLogger("AUTO_UPDATE");
|
|
29
37
|
var UPDATE_SUCCESS_MESSAGE = "Update successful! Please restart Qwen Code to use the new version. Switching model providers before restarting may not work correctly.";
|
|
30
38
|
var UPDATE_FAILED_MESSAGE = "Automatic update failed. Please try updating manually.";
|
|
31
39
|
function handleAutoUpdate(info, settings, projectRoot, spawnFn = spawnWrapper) {
|
|
@@ -47,11 +55,18 @@ ${installationInfo.updateMessage}`;
|
|
|
47
55
|
});
|
|
48
56
|
if (installationInfo.isStandalone && installationInfo.standaloneDir && isAutoUpdateEnabled) {
|
|
49
57
|
performStandaloneUpdate(installationInfo.standaloneDir, info.update.latest).then((result) => {
|
|
50
|
-
const message = result === "deferred" ?
|
|
58
|
+
const message = result === "deferred" ? t(
|
|
59
|
+
"Update downloaded. It will be applied after you exit this session."
|
|
60
|
+
) : t(
|
|
61
|
+
"Update successful! The new version will be used on your next run."
|
|
62
|
+
);
|
|
51
63
|
updateEventEmitter.emit("update-success", { message });
|
|
52
64
|
}).catch((err) => {
|
|
53
65
|
updateEventEmitter.emit("update-failed", {
|
|
54
|
-
message:
|
|
66
|
+
message: t(
|
|
67
|
+
"Automatic update failed: {{error}}. Re-run the installer to update manually.",
|
|
68
|
+
{ error: err.message }
|
|
69
|
+
)
|
|
55
70
|
});
|
|
56
71
|
});
|
|
57
72
|
return;
|
|
@@ -59,15 +74,16 @@ ${installationInfo.updateMessage}`;
|
|
|
59
74
|
if (!installationInfo.updateCommand || !isAutoUpdateEnabled) {
|
|
60
75
|
return;
|
|
61
76
|
}
|
|
62
|
-
const
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
isNightly ? "@nightly" : `@${info.update.latest}`
|
|
77
|
+
const updateCommand = resolveUpdateCommand(
|
|
78
|
+
installationInfo.updateCommand,
|
|
79
|
+
info.update.latest
|
|
66
80
|
);
|
|
67
81
|
const isWindows = os.platform() === "win32";
|
|
68
82
|
const shell = isWindows ? "cmd.exe" : "bash";
|
|
69
83
|
const shellArgs = isWindows ? ["/c", updateCommand] : ["-c", updateCommand];
|
|
70
|
-
const updateProcess = spawnFn(shell, shellArgs, {
|
|
84
|
+
const updateProcess = spawnFn(shell, shellArgs, {
|
|
85
|
+
stdio: ["pipe", "ignore", "pipe"]
|
|
86
|
+
});
|
|
71
87
|
let errorOutput = "";
|
|
72
88
|
updateProcess.stderr.on("data", (data) => {
|
|
73
89
|
errorOutput += data.toString();
|
|
@@ -75,17 +91,21 @@ ${installationInfo.updateMessage}`;
|
|
|
75
91
|
updateProcess.on("close", (code) => {
|
|
76
92
|
if (code === 0) {
|
|
77
93
|
updateEventEmitter.emit("update-success", {
|
|
78
|
-
message: UPDATE_SUCCESS_MESSAGE
|
|
94
|
+
message: t(UPDATE_SUCCESS_MESSAGE)
|
|
79
95
|
});
|
|
80
96
|
} else {
|
|
97
|
+
debugLogger.warn(
|
|
98
|
+
`Automatic update command failed: ${updateCommand}; stderr: ${errorOutput.trim()}`
|
|
99
|
+
);
|
|
81
100
|
updateEventEmitter.emit("update-failed", {
|
|
82
|
-
message:
|
|
101
|
+
message: t(UPDATE_FAILED_MESSAGE)
|
|
83
102
|
});
|
|
84
103
|
}
|
|
85
104
|
});
|
|
86
105
|
updateProcess.on("error", (err) => {
|
|
106
|
+
debugLogger.warn("Automatic update command failed to start:", err);
|
|
87
107
|
updateEventEmitter.emit("update-failed", {
|
|
88
|
-
message:
|
|
108
|
+
message: t(UPDATE_FAILED_MESSAGE)
|
|
89
109
|
});
|
|
90
110
|
});
|
|
91
111
|
return updateProcess;
|
|
@@ -118,7 +138,7 @@ function setUpdateHandler(addItem, setUpdateInfo, isIdleRef = { current: true })
|
|
|
118
138
|
setUpdateInfo(null);
|
|
119
139
|
addItemOrDefer({
|
|
120
140
|
type: "error" /* ERROR */,
|
|
121
|
-
text: data?.message ?? UPDATE_FAILED_MESSAGE
|
|
141
|
+
text: data?.message ?? t(UPDATE_FAILED_MESSAGE)
|
|
122
142
|
});
|
|
123
143
|
}, "handleUpdateFailed");
|
|
124
144
|
const handleUpdateSuccess = /* @__PURE__ */ __name((data) => {
|
|
@@ -126,7 +146,7 @@ function setUpdateHandler(addItem, setUpdateInfo, isIdleRef = { current: true })
|
|
|
126
146
|
setUpdateInfo(null);
|
|
127
147
|
addItemOrDefer({
|
|
128
148
|
type: "info" /* INFO */,
|
|
129
|
-
text: data?.message ?? UPDATE_SUCCESS_MESSAGE
|
|
149
|
+
text: data?.message ?? t(UPDATE_SUCCESS_MESSAGE)
|
|
130
150
|
});
|
|
131
151
|
}, "handleUpdateSuccess");
|
|
132
152
|
const handleUpdateInfo = /* @__PURE__ */ __name((data) => {
|