@qwen-code/qwen-code 0.20.0-preview.0 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (341) hide show
  1. package/bundled/qc-helper/docs/configuration/settings.md +1 -1
  2. package/bundled/qc-helper/docs/features/auto-mode.md +16 -19
  3. package/bundled/qc-helper/docs/features/commands.md +0 -54
  4. package/bundled/qc-helper/docs/features/sub-agents.md +7 -16
  5. package/bundled/qc-helper/docs/integration-github-action.md +10 -10
  6. package/bundled/qc-helper/docs/qwen-serve.md +1 -2
  7. package/bundled/review/DESIGN.md +2 -2
  8. package/bundled/review/SKILL.md +4 -4
  9. package/chunks/{MaxSizedBox-53BTJ3JK.js → MaxSizedBox-B5YGZSYE.js} +34 -41
  10. package/chunks/{StandaloneSessionPicker-VMFIXQ44.js → StandaloneSessionPicker-CEGO2AZX.js} +50 -57
  11. package/chunks/{acpAgent-5WYAVSFG.js → acpAgent-YUR43TLG.js} +496 -1487
  12. package/chunks/{agent-44FM7PBX.js → agent-H4JIDL7S.js} +30 -37
  13. package/chunks/agent-headless-TTBEREQV.js +61 -0
  14. package/chunks/{anthropicContentGenerator-NMSS7IMV.js → anthropicContentGenerator-HVKLXOOU.js} +12 -13
  15. package/chunks/{artifact-tool-56T5IMBP.js → artifact-tool-WBCAMD3O.js} +3 -3
  16. package/chunks/{askUserQuestion-E25OBIC2.js → askUserQuestion-6DZC4UV5.js} +3 -3
  17. package/chunks/{bridge-IQZT3KU2.js → bridge-VL7ITBU5.js} +35 -42
  18. package/chunks/{build-GHIZ4MSZ.js → build-SSCNEHZZ.js} +1 -1
  19. package/chunks/{ca-N6VVUFVB.js → ca-2SL2BXTK.js} +201 -611
  20. package/chunks/{channel-worker-group-LFBT7K64.js → channel-worker-group-53CMOPFT.js} +5 -5
  21. package/chunks/{channel-worker-manager-3RUPERG2.js → channel-worker-manager-UTXILKC2.js} +5 -5
  22. package/chunks/{channel-worker-supervisor-A3KVATD3.js → channel-worker-supervisor-ZGO2W2MD.js} +4 -4
  23. package/chunks/{chunk-2LI23QA6.js → chunk-2HOVDT7W.js} +1 -1
  24. package/chunks/{chunk-JWJVZHT5.js → chunk-2LL7TXB4.js} +2 -2
  25. package/chunks/{chunk-22OH7L7I.js → chunk-333CXMNJ.js} +5 -5
  26. package/chunks/{chunk-J3VSRG5Y.js → chunk-33XUAINQ.js} +21 -61
  27. package/chunks/{chunk-S4BT3PX3.js → chunk-4EP2PYYL.js} +5 -5
  28. package/chunks/{chunk-CJTAUXKG.js → chunk-4ILMYHEI.js} +3 -3
  29. package/chunks/{chunk-JIHHXJFH.js → chunk-4N3KMAIL.js} +32 -128
  30. package/chunks/{chunk-6ZBPS62S.js → chunk-4ODB7WIB.js} +1 -1
  31. package/chunks/{chunk-YDLVKCZJ.js → chunk-4XNLIGVA.js} +298 -576
  32. package/chunks/{chunk-Q6DEGTYO.js → chunk-542SK7KV.js} +1608 -243
  33. package/chunks/{chunk-EPN5MKRH.js → chunk-5JBR5XIK.js} +2 -2
  34. package/chunks/{chunk-E4IMU4Y5.js → chunk-5SCI6E3E.js} +1 -1
  35. package/chunks/{chunk-IE7TPOXP.js → chunk-6AFUCL3D.js} +1 -1
  36. package/chunks/{chunk-5I5BM454.js → chunk-6EFTQYW7.js} +1 -1
  37. package/chunks/{chunk-45AIVIUL.js → chunk-7PZ2ATFZ.js} +29 -54
  38. package/chunks/{chunk-VI7UU7ZI.js → chunk-7RMOXZTC.js} +4 -4
  39. package/chunks/{chunk-C3YZ5CLY.js → chunk-7SXZC7ID.js} +6 -7
  40. package/chunks/{chunk-X6KLM4LZ.js → chunk-A5LYNIW7.js} +8 -8
  41. package/chunks/{chunk-GZBHRTNM.js → chunk-AJSJ5TTU.js} +1 -1
  42. package/chunks/{chunk-IT27F3ES.js → chunk-AKX4WPPP.js} +86 -307
  43. package/chunks/{chunk-EJFHUF3D.js → chunk-ANPINBOF.js} +5 -5
  44. package/chunks/{chunk-JJEFX6U5.js → chunk-AQIEINAY.js} +1766 -28
  45. package/chunks/{chunk-7Z6JQEL6.js → chunk-AYCDXHZB.js} +1 -1
  46. package/chunks/{chunk-BKZEHVPV.js → chunk-B3KGZCQN.js} +169 -177
  47. package/chunks/{chunk-6X4GWOPW.js → chunk-BDBMYST4.js} +1 -1
  48. package/chunks/{chunk-BEKZWVJJ.js → chunk-BMWMT5Y2.js} +373 -3
  49. package/chunks/{chunk-5MZSD2JX.js → chunk-BRRF37CO.js} +6 -6
  50. package/chunks/{chunk-QLJUC7TG.js → chunk-BVLROR2T.js} +1 -1
  51. package/chunks/{chunk-OQB4EXO4.js → chunk-C27BYUX6.js} +11 -14
  52. package/chunks/{chunk-VTKWURCJ.js → chunk-CB2HFGRV.js} +6 -31
  53. package/chunks/chunk-CPCVCKKF.js +358 -0
  54. package/chunks/{chunk-OAGG6CRR.js → chunk-CV63PP6U.js} +1 -1
  55. package/chunks/{chunk-XFWD3PCA.js → chunk-CZF3E5GF.js} +1 -1
  56. package/chunks/{chunk-QF4DPYPH.js → chunk-D22SX43D.js} +1 -1
  57. package/chunks/{chunk-X6N25LXS.js → chunk-D2VIDMVM.js} +2 -2
  58. package/chunks/{chunk-7KZ2KYAD.js → chunk-DBE4QFZS.js} +23 -27
  59. package/chunks/{chunk-VHYCUGOT.js → chunk-DP5GXXNZ.js} +1 -5
  60. package/chunks/{chunk-Q2YKNMLS.js → chunk-EAUYY7SS.js} +3 -3
  61. package/chunks/{chunk-KHOVYUHX.js → chunk-EIAK6Q2B.js} +2 -2
  62. package/chunks/{chunk-NPQDJGKU.js → chunk-EZVDJFZ7.js} +1 -1
  63. package/chunks/{chunk-FODK6UMO.js → chunk-FEOZBUMT.js} +27 -0
  64. package/chunks/{chunk-6NHK6HS7.js → chunk-FLSVD6BS.js} +3 -3
  65. package/chunks/{chunk-XP32LURS.js → chunk-FQD7GFSV.js} +3 -3
  66. package/chunks/{chunk-T2L47JJK.js → chunk-FSL5W5TI.js} +3 -3
  67. package/chunks/{chunk-JCW2R7WC.js → chunk-G45X5TRN.js} +72 -1
  68. package/chunks/{chunk-ZHERRXZJ.js → chunk-GKY2OJ7R.js} +1 -1
  69. package/chunks/{chunk-6IL7KRLE.js → chunk-GMGDLUC7.js} +1 -1
  70. package/chunks/{chunk-E5MVGARW.js → chunk-HZPN55E5.js} +1 -1
  71. package/chunks/{chunk-LMQNDPVP.js → chunk-I2PYAYFM.js} +3 -3
  72. package/chunks/{chunk-JD5FHQ3N.js → chunk-IR46U7RB.js} +3 -3
  73. package/chunks/{chunk-BXXWWCLA.js → chunk-IVPSS6EL.js} +4 -4
  74. package/chunks/{chunk-4K56OJFJ.js → chunk-JD3MKVKL.js} +1 -1
  75. package/chunks/{chunk-SP5WRGVG.js → chunk-JNWZQ27S.js} +3 -3
  76. package/chunks/{chunk-RUNR5DAE.js → chunk-KDC6GNQR.js} +4 -4
  77. package/chunks/{chunk-JT7HACMQ.js → chunk-KG3XV6FH.js} +2 -29
  78. package/chunks/{chunk-BRHHXGWL.js → chunk-KOR3XKCA.js} +4 -10
  79. package/chunks/{chunk-H4OWOFZL.js → chunk-KQNM4EO7.js} +5 -137
  80. package/chunks/{chunk-4K7VDKAD.js → chunk-KTUQMDEP.js} +1 -1
  81. package/chunks/{chunk-6RQ5IPUX.js → chunk-KX6UK4VJ.js} +19929 -22391
  82. package/chunks/{chunk-JYS55H6Z.js → chunk-MAQQGNQ5.js} +7 -66
  83. package/chunks/{chunk-GOWMC4CS.js → chunk-MJ6S23WZ.js} +4 -4
  84. package/chunks/{chunk-D7WXIW7H.js → chunk-NBMIC7DR.js} +4 -4
  85. package/chunks/{chunk-NYPUWHHC.js → chunk-NDMQLV4Y.js} +4 -4
  86. package/chunks/{chunk-FFFM6NJV.js → chunk-NEEB7UEN.js} +2 -1
  87. package/chunks/{chunk-6AWRQ4T2.js → chunk-NGFEPAE6.js} +6 -8
  88. package/chunks/{chunk-RVLZCXEE.js → chunk-NIJEXGV6.js} +10 -79
  89. package/chunks/{chunk-6OHCY3OB.js → chunk-O3OCNYY5.js} +2 -2
  90. package/chunks/{chunk-J63IP5ZT.js → chunk-O3Z73NBP.js} +7 -7
  91. package/chunks/{chunk-RWCQJC5W.js → chunk-OEO2ERWK.js} +33 -54
  92. package/chunks/{chunk-KQQ757OQ.js → chunk-OLMETXLX.js} +2 -2
  93. package/chunks/{chunk-LIZRAKPB.js → chunk-OOCI5VVU.js} +1 -1
  94. package/chunks/{chunk-GPSKDNEE.js → chunk-OONJNQ42.js} +3 -3
  95. package/chunks/{chunk-YM3SZTH4.js → chunk-OP4MOGXF.js} +1 -8
  96. package/chunks/{chunk-CHLNJN3C.js → chunk-OWCALFEG.js} +1 -1
  97. package/chunks/{chunk-5JX7FPHW.js → chunk-OYZWQNWG.js} +2 -2
  98. package/chunks/{chunk-QBUDF33N.js → chunk-PBATSWUQ.js} +1 -1
  99. package/chunks/{chunk-DKZISEDB.js → chunk-PBWEWI4N.js} +69 -76
  100. package/chunks/{chunk-DORJSBMF.js → chunk-PF4CHQOJ.js} +6 -6
  101. package/chunks/{chunk-SOMSZ6W3.js → chunk-PGEPSDJI.js} +8 -13
  102. package/chunks/{chunk-4LVZNIDO.js → chunk-QKYTTBYW.js} +1 -1
  103. package/chunks/{chunk-VYPFXUCB.js → chunk-R3VWUU2E.js} +1 -1
  104. package/chunks/{chunk-RV4C2ZFG.js → chunk-RFIAR4YL.js} +1 -1
  105. package/chunks/{chunk-66RKDODM.js → chunk-S2PD3EZD.js} +1 -1
  106. package/chunks/{chunk-RAUHV362.js → chunk-S2W2LVDU.js} +3 -3
  107. package/chunks/{chunk-VLBJ7ZUG.js → chunk-S2XVRHDN.js} +1 -1
  108. package/chunks/chunk-SEKHYHMS.js +45 -0
  109. package/chunks/{chunk-KNTYRZD4.js → chunk-SJMV7ZBK.js} +8 -8
  110. package/chunks/{chunk-THJNPLI4.js → chunk-TB6UDU4T.js} +16 -16
  111. package/chunks/{chunk-CMRYLH67.js → chunk-TIH2ZTOC.js} +2 -2
  112. package/chunks/{chunk-K4VB66QF.js → chunk-TKLLK6XQ.js} +11 -11
  113. package/chunks/{chunk-QTROYZUC.js → chunk-TMQ6XQCX.js} +53 -170
  114. package/chunks/{chunk-QNLNLENL.js → chunk-UEY4AYUL.js} +2 -2
  115. package/chunks/{chunk-FSXCGBXB.js → chunk-VDWBQ5AW.js} +1 -1
  116. package/chunks/{chunk-45DNGJKC.js → chunk-VEXFOTEO.js} +3 -3
  117. package/chunks/{chunk-A7CUSHP7.js → chunk-VZQUV7VK.js} +1 -1
  118. package/chunks/chunk-W7FJ3N32.js +49 -0
  119. package/chunks/{chunk-UGYMA4EI.js → chunk-W7H223ZZ.js} +1 -1
  120. package/chunks/{chunk-UH3WSE5L.js → chunk-X6YQWCIJ.js} +1 -13
  121. package/chunks/{chunk-H4AR2JQF.js → chunk-XVVH63JG.js} +3 -3
  122. package/chunks/{chunk-QKTHJXCS.js → chunk-Y2ENGUD6.js} +1 -1
  123. package/chunks/{chunk-QD6BRERJ.js → chunk-YWEW33JY.js} +7 -7
  124. package/chunks/{chunk-57FIIFJN.js → chunk-ZEOZL37W.js} +1 -1
  125. package/chunks/chunk-ZFKNWQGQ.js +74639 -0
  126. package/chunks/{computer-use-FMEBQMCB.js → computer-use-NIWQNUZF.js} +35 -42
  127. package/chunks/{config-utils-WYUQ7II4.js → config-utils-AHQ6YZ66.js} +3 -3
  128. package/chunks/contextCommand-L2COEUHS.js +66 -0
  129. package/chunks/{create-sub-session-MLELTOCW.js → create-sub-session-MGNX52P3.js} +30 -37
  130. package/chunks/{create-sub-session-AZ77LBL3.js → create-sub-session-P26FE5GG.js} +3 -3
  131. package/chunks/{cron-create-KTWJM7QT.js → cron-create-JWFHBDRQ.js} +5 -5
  132. package/chunks/{cron-delete-2P3I5ULL.js → cron-delete-GDX4E26G.js} +5 -5
  133. package/chunks/{cron-list-PXDPGEDQ.js → cron-list-USMAIWPT.js} +5 -5
  134. package/chunks/{daemon-KLPTQIE4.js → daemon-RG2MAI6T.js} +81 -138
  135. package/chunks/daemon-status-provider-NL4IAG7B.js +74 -0
  136. package/chunks/{de-4IBXM7CN.js → de-I7ZIYXZC.js} +1 -5
  137. package/chunks/{dist-HMU6CYS4.js → dist-2BHAYBKP.js} +2 -2
  138. package/chunks/{dist-PJLG2XYX.js → dist-2MIU4UUH.js} +1 -1
  139. package/chunks/{dist-UIFWIFRO.js → dist-53PZYC5B.js} +2 -2
  140. package/chunks/{dist-OAV7LJGJ.js → dist-AU7NQQRP.js} +1 -1
  141. package/chunks/{dist-OMW6WDEO.js → dist-FUTEXY6A.js} +1 -1
  142. package/chunks/{dist-XRYV6TJP.js → dist-WGTQO7F2.js} +25 -65
  143. package/chunks/{earlyInputCapture-N3J42S2G.js → earlyInputCapture-L6I2A22T.js} +31 -38
  144. package/chunks/{edit-T6GO7VPW.js → edit-3QV3JZJL.js} +37 -42
  145. package/chunks/{en-USMCCJAJ.js → en-XE34GKAA.js} +1 -5
  146. package/chunks/{enter-worktree-OL3FMR3A.js → enter-worktree-4GMMF7EG.js} +35 -42
  147. package/chunks/{enterPlanMode-LEP7BSBX.js → enterPlanMode-L5UWBAUC.js} +36 -48
  148. package/chunks/{environment-6LNBH2LJ.js → environment-3OV7UQOT.js} +32 -39
  149. package/chunks/{errors-IM3H4DNG.js → errors-LEOF5QG4.js} +32 -39
  150. package/chunks/{exit-worktree-6MOANJMY.js → exit-worktree-DDP57JLV.js} +35 -42
  151. package/chunks/{exitPlanMode-VLBSWDJK.js → exitPlanMode-CJBLGPIP.js} +35 -42
  152. package/chunks/{fast-path-3Z3JY4BL.js → fast-path-M6RP2ING.js} +3 -4
  153. package/chunks/{fast-path-settings-XB3CPUJT.js → fast-path-settings-DAOVFADC.js} +2 -2
  154. package/chunks/{fr-WVHEBDDB.js → fr-X7KDVZIY.js} +1 -5
  155. package/chunks/{gemini-VDE6O6CX.js → gemini-H4PHBJTL.js} +89 -97
  156. package/chunks/{geminiContentGenerator-NN4ZWALY.js → geminiContentGenerator-VURJYPWP.js} +5 -5
  157. package/chunks/{getMachineId-bsd-QFVLPUPT.js → getMachineId-bsd-EXV7SWPA.js} +1 -1
  158. package/chunks/{getMachineId-darwin-DGMQQE2E.js → getMachineId-darwin-IUOMFXU3.js} +1 -1
  159. package/chunks/{getMachineId-linux-R4Z6CSWC.js → getMachineId-linux-K7XJYFHL.js} +1 -1
  160. package/chunks/{getMachineId-unsupported-Z3SBVBUV.js → getMachineId-unsupported-EA5FDRJ6.js} +1 -1
  161. package/chunks/{getMachineId-win-SCK5UFDT.js → getMachineId-win-KBA6RAI5.js} +1 -1
  162. package/chunks/{glob-7AZHIY3Z.js → glob-2KUSRAVQ.js} +35 -42
  163. package/chunks/{grep-E2KEORSD.js → grep-B5RXVESV.js} +35 -42
  164. package/chunks/handleAutoUpdate-QQVIWXKT.js +67 -0
  165. package/chunks/{i18n-VP4NCTZN.js → i18n-N6OBDORT.js} +31 -38
  166. package/chunks/initializer-6WCFNDLL.js +72 -0
  167. package/chunks/installationInfo-6J3WPXNS.js +64 -0
  168. package/chunks/{ja-KY4ROZTE.js → ja-2ICT3KXF.js} +1 -5
  169. package/chunks/{keychain-token-storage-6ACJDYIB.js → keychain-token-storage-DWRJMNH3.js} +3 -3
  170. package/chunks/list-HOWQSWP6.js +75 -0
  171. package/chunks/loadedSettingsAdapter-AO4YBRXZ.js +69 -0
  172. package/chunks/{loop-wakeup-RNMRVA66.js → loop-wakeup-5GLTUBHA.js} +6 -6
  173. package/chunks/{ls-J2ZI5XYK.js → ls-FHBY3Y7I.js} +5 -5
  174. package/chunks/{lsp-UMS3NUB5.js → lsp-B6VMEW6Y.js} +3 -3
  175. package/chunks/mcp-QH7QNXOH.js +69 -0
  176. package/chunks/{monitor-NDYKU5VS.js → monitor-GLJZDNPS.js} +35 -42
  177. package/chunks/nonInteractiveCli-TI7EMPXD.js +126 -0
  178. package/chunks/{notebook-edit-GF3HSMXN.js → notebook-edit-AVCIWS4F.js} +38 -43
  179. package/chunks/{openaiContentGenerator-GE2I3C2T.js → openaiContentGenerator-B7W24G3D.js} +17 -22
  180. package/chunks/{pidfile-KS4IGGNX.js → pidfile-UEHAT6DH.js} +31 -38
  181. package/chunks/{processUtils-TEQQ47A2.js → processUtils-XZPY2PBB.js} +2 -2
  182. package/chunks/{pt-OK455PLH.js → pt-JJ4XPIBP.js} +1 -5
  183. package/chunks/{qwenContentGenerator-NDYOEIUY.js → qwenContentGenerator-6GUTWJIC.js} +35 -44
  184. package/chunks/{qwenOAuth2-CXDOBPSK.js → qwenOAuth2-GASEEWGU.js} +15 -18
  185. package/chunks/{read-file-QDVJX75S.js → read-file-SQJONF6A.js} +11 -13
  186. package/chunks/{read-mcp-resource-F6HYMDUY.js → read-mcp-resource-AKCL7I43.js} +3 -3
  187. package/chunks/{record-artifact-7GCFLDD7.js → record-artifact-PEUB7727.js} +3 -3
  188. package/chunks/{resumeHistoryUtils-5EAQ76W4.js → resumeHistoryUtils-PFQ2A23X.js} +36 -43
  189. package/chunks/ripGrep-QCK22GDU.js +59 -0
  190. package/chunks/{ru-7SPDGMGD.js → ru-STR4KTW7.js} +1 -5
  191. package/chunks/{run-qwen-serve-TC6M3WTJ.js → run-qwen-serve-OZGR3FQA.js} +82 -104
  192. package/chunks/{runtime-BB73E3Z3.js → runtime-SNVAP6EH.js} +40 -49
  193. package/chunks/{scheduler-NDU5OFSJ.js → scheduler-Z7QLMUWA.js} +30 -37
  194. package/chunks/{send-message-PYIJ2PZL.js → send-message-3RHE7HSM.js} +4 -6
  195. package/chunks/{serve-BTIRWZJ4.js → serve-BT7KS6SC.js} +36 -43
  196. package/chunks/{server-JKAQBE2E.js → server-SO64U3X5.js} +284 -988
  197. package/chunks/{session-66QFVVDS.js → session-2KL2WQAH.js} +173 -92
  198. package/chunks/{settings-NBN6GY7E.js → settings-KITVOUSV.js} +39 -46
  199. package/chunks/{shell-JDSLAQVH.js → shell-BITUVH2R.js} +30 -37
  200. package/chunks/{skill-TNMHTO3C.js → skill-SOQHY455.js} +20 -24
  201. package/chunks/{spawnChannel-TFLHHXOC.js → spawnChannel-2BU3AULL.js} +32 -39
  202. package/chunks/{src-YFXMPRBL.js → src-43LM7JLB.js} +209 -279
  203. package/chunks/{standalone-update-2CQVQRSC.js → standalone-update-YG5JUYCM.js} +32 -39
  204. package/chunks/{startInteractiveUI-6C6PENRW.js → startInteractiveUI-3RGTGEX5.js} +895 -1092
  205. package/chunks/{syntheticOutput-H7RTI5KL.js → syntheticOutput-FG5PQKIR.js} +4 -4
  206. package/chunks/{task-create-7474AJJD.js → task-create-HX32YXO7.js} +8 -10
  207. package/chunks/{task-list-633HGOIB.js → task-list-QWSY4ZIU.js} +6 -6
  208. package/chunks/{task-stop-MNUGHPIA.js → task-stop-GWC6UWAL.js} +3 -3
  209. package/chunks/{task-update-66GQB5LI.js → task-update-NCTAB73Q.js} +8 -10
  210. package/chunks/{team-create-IPBHD26Z.js → team-create-FXN3PEBP.js} +35 -42
  211. package/chunks/{team-delete-BB3CG3QF.js → team-delete-KK37HTOG.js} +6 -6
  212. package/chunks/{team-plan-approval-WIGEJXXM.js → team-plan-approval-GEIZ356Q.js} +35 -42
  213. package/chunks/theme-manager-IAETOI25.js +63 -0
  214. package/chunks/{todoWrite-KRAUN54W.js → todoWrite-ERCAMLFS.js} +5 -5
  215. package/chunks/{tool-search-J3CBYJRB.js → tool-search-XKK7DNOK.js} +17 -21
  216. package/chunks/total-session-admission-BJLDHKJN.js +69 -0
  217. package/chunks/{trustedFolders-5FJRCHGN.js → trustedFolders-5XCVNEUU.js} +31 -38
  218. package/chunks/{update-relaunch-S5APSFJS.js → update-relaunch-FMVZK6XF.js} +17 -17
  219. package/chunks/updateCheck-YZZB7YBU.js +70 -0
  220. package/chunks/{useAutoAcceptIndicator-WZVJ52U3.js → useAutoAcceptIndicator-ZSQX4I2H.js} +40 -47
  221. package/chunks/{validateNonInterActiveAuth-64SVMELJ.js → validateNonInterActiveAuth-PRVEB6GG.js} +72 -79
  222. package/chunks/{version-SQL27GUA.js → version-AZMG6KWL.js} +1 -1
  223. package/chunks/{web-fetch-K7QCHIOJ.js → web-fetch-EPGJ5OQQ.js} +41 -100
  224. package/chunks/{workflow-BFTW72A5.js → workflow-UTNVPW22.js} +39 -47
  225. package/chunks/workspace-providers-status-EADV364W.js +72 -0
  226. package/chunks/{workspace-registration-store-VAVPVIF3.js → workspace-registration-store-F3ZX3YHT.js} +2 -8
  227. package/chunks/workspace-registry-W6VMFYZU.js +73 -0
  228. package/chunks/workspace-service-F3KIN2UN.js +84 -0
  229. package/chunks/workspace-skills-status-YVICUR5Y.js +71 -0
  230. package/chunks/write-file-CVGF2OKV.js +596 -0
  231. package/chunks/{zh-WY5DWYZD.js → zh-6ANG2HTL.js} +1 -5
  232. package/chunks/{zh-TW-BM47YBFH.js → zh-TW-4RR3YHNN.js} +1 -5
  233. package/cli-entry.js +12 -164
  234. package/cli.js +11 -18
  235. package/locales/ca.js +203 -772
  236. package/locales/de.js +2 -8
  237. package/locales/en.js +2 -8
  238. package/locales/fr.js +2 -8
  239. package/locales/ja.js +2 -8
  240. package/locales/pt.js +2 -8
  241. package/locales/ru.js +2 -8
  242. package/locales/zh-TW.js +2 -8
  243. package/locales/zh.js +2 -8
  244. package/package.json +3 -3
  245. package/web-shell/assets/{arc-ByltRugA.js → arc-Buk1besA.js} +1 -1
  246. package/web-shell/assets/{architectureDiagram-3BPJPVTR-CCRTto5d.js → architectureDiagram-3BPJPVTR-B1aUKYDC.js} +1 -1
  247. package/web-shell/assets/{blockDiagram-GPEHLZMM-Jfy36u1L.js → blockDiagram-GPEHLZMM-CRTdg3Zx.js} +1 -1
  248. package/web-shell/assets/{c4Diagram-AAUBKEIU-4d5FfEZ0.js → c4Diagram-AAUBKEIU-DFdRMp5g.js} +1 -1
  249. package/web-shell/assets/channel-04R0vLbG.js +1 -0
  250. package/web-shell/assets/{chunk-2J33WTMH-BPwxCEro.js → chunk-2J33WTMH-4rYQdkEI.js} +1 -1
  251. package/web-shell/assets/{chunk-4BX2VUAB-jY7ZmJWY.js → chunk-4BX2VUAB-Coi-pQJy.js} +1 -1
  252. package/web-shell/assets/{chunk-55IACEB6-C98HgCsS.js → chunk-55IACEB6-BtBjz02t.js} +1 -1
  253. package/web-shell/assets/{chunk-727SXJPM-cDu-ge-q.js → chunk-727SXJPM-CGYOWorl.js} +1 -1
  254. package/web-shell/assets/{chunk-AQP2D5EJ-BKdJwxXK.js → chunk-AQP2D5EJ-CH5AKhqx.js} +1 -1
  255. package/web-shell/assets/{chunk-FMBD7UC4-DnuxqwMu.js → chunk-FMBD7UC4-Cd50-w85.js} +1 -1
  256. package/web-shell/assets/{chunk-ND2GUHAM-C4fZNPv0.js → chunk-ND2GUHAM-C2wF3KCK.js} +1 -1
  257. package/web-shell/assets/{chunk-QZHKN3VN-Cf4XWOmz.js → chunk-QZHKN3VN-pCeRTaWi.js} +1 -1
  258. package/web-shell/assets/classDiagram-4FO5ZUOK-Bw9SOwAV.js +1 -0
  259. package/web-shell/assets/classDiagram-v2-Q7XG4LA2-Bw9SOwAV.js +1 -0
  260. package/web-shell/assets/{cose-bilkent-S5V4N54A-C82mFiqj.js → cose-bilkent-S5V4N54A-B-_fAB6D.js} +1 -1
  261. package/web-shell/assets/{dagre-BM42HDAG-Df8KACER.js → dagre-BM42HDAG-ChSPNHpL.js} +1 -1
  262. package/web-shell/assets/{diagram-2AECGRRQ-EzNs7s_2.js → diagram-2AECGRRQ-BX7cFOF3.js} +1 -1
  263. package/web-shell/assets/{diagram-5GNKFQAL-BRLNvreg.js → diagram-5GNKFQAL-BQUTW92n.js} +1 -1
  264. package/web-shell/assets/{diagram-KO2AKTUF-2HLYHRjC.js → diagram-KO2AKTUF-BkYPh3e4.js} +1 -1
  265. package/web-shell/assets/{diagram-LMA3HP47-DeH0NzSp.js → diagram-LMA3HP47-Cl6jsNyx.js} +1 -1
  266. package/web-shell/assets/{diagram-OG6HWLK6-k5Gn47-G.js → diagram-OG6HWLK6-DRWoHz8n.js} +1 -1
  267. package/web-shell/assets/{erDiagram-TEJ5UH35-gPHFo79f.js → erDiagram-TEJ5UH35-CGvFcZco.js} +1 -1
  268. package/web-shell/assets/{flowDiagram-I6XJVG4X-DYBOiTRW.js → flowDiagram-I6XJVG4X-vms6oVdv.js} +1 -1
  269. package/web-shell/assets/{ganttDiagram-6RSMTGT7-cxjAuic9.js → ganttDiagram-6RSMTGT7-ukT_sfmi.js} +1 -1
  270. package/web-shell/assets/{gitGraphDiagram-PVQCEYII-3nPqpmCP.js → gitGraphDiagram-PVQCEYII-Bn2ZE2Ut.js} +1 -1
  271. package/web-shell/assets/index-DgkKrjw3.js +1187 -0
  272. package/web-shell/assets/index-Rv6mOAN9.css +5 -0
  273. package/web-shell/assets/{index-Cl8d-1bK.js → index-wFXp7W68.js} +1 -1
  274. package/web-shell/assets/{infoDiagram-5YYISTIA-Dph21pR5.js → infoDiagram-5YYISTIA-DHJdSi7x.js} +1 -1
  275. package/web-shell/assets/{ishikawaDiagram-YF4QCWOH-Cjg1hSaG.js → ishikawaDiagram-YF4QCWOH-DOvd2Wph.js} +1 -1
  276. package/web-shell/assets/{journeyDiagram-JHISSGLW-CR-IzvnU.js → journeyDiagram-JHISSGLW-CH_urMCT.js} +1 -1
  277. package/web-shell/assets/{kanban-definition-UN3LZRKU-BYmuybuC.js → kanban-definition-UN3LZRKU-FKiBdgbH.js} +1 -1
  278. package/web-shell/assets/{linear-CngEEoy8.js → linear-0ZVQFVKf.js} +1 -1
  279. package/web-shell/assets/{mermaid.core-G6fbZRPf.js → mermaid.core-DJ05ZZIK.js} +5 -5
  280. package/web-shell/assets/{mindmap-definition-RKZ34NQL-BtnqnUwJ.js → mindmap-definition-RKZ34NQL-BPuUhkUm.js} +1 -1
  281. package/web-shell/assets/{pieDiagram-4H26LBE5-XTq6UHIA.js → pieDiagram-4H26LBE5-yLFKcXyG.js} +1 -1
  282. package/web-shell/assets/{quadrantDiagram-W4KKPZXB-D1J5PrsS.js → quadrantDiagram-W4KKPZXB-irWqc1pE.js} +1 -1
  283. package/web-shell/assets/{requirementDiagram-4Y6WPE33-CLcBUy3t.js → requirementDiagram-4Y6WPE33-B_4uMoIV.js} +1 -1
  284. package/web-shell/assets/{sankeyDiagram-5OEKKPKP-iwKV02_6.js → sankeyDiagram-5OEKKPKP-ciA4GPwk.js} +1 -1
  285. package/web-shell/assets/{sequenceDiagram-3UESZ5HK-7NFYQcEX.js → sequenceDiagram-3UESZ5HK-CRdZvy0U.js} +1 -1
  286. package/web-shell/assets/{stateDiagram-AJRCARHV-Bvm4Wih6.js → stateDiagram-AJRCARHV-DaYIkCCn.js} +1 -1
  287. package/web-shell/assets/stateDiagram-v2-BHNVJYJU-DWBoO4UY.js +1 -0
  288. package/web-shell/assets/{timeline-definition-PNZ67QCA-B4FZFE9O.js → timeline-definition-PNZ67QCA-oBUKv6iH.js} +1 -1
  289. package/web-shell/assets/{vennDiagram-CIIHVFJN-CvMBpmtL.js → vennDiagram-CIIHVFJN-CGW9Sdmb.js} +1 -1
  290. package/web-shell/assets/{wardley-L42UT6IY-E3ag2327.js → wardley-L42UT6IY-CvwKJOCm.js} +1 -1
  291. package/web-shell/assets/{wardleyDiagram-YWT4CUSO-BEXWlgxC.js → wardleyDiagram-YWT4CUSO-Ipc260sN.js} +1 -1
  292. package/web-shell/assets/{xychartDiagram-2RQKCTM6-CICK05gI.js → xychartDiagram-2RQKCTM6-D6-CM7pK.js} +1 -1
  293. package/web-shell/index.html +2 -2
  294. package/chunks/agent-headless-CDBMKM44.js +0 -68
  295. package/chunks/chunk-2RFKHEXL.js +0 -74
  296. package/chunks/chunk-43T5WDQ7.js +0 -127
  297. package/chunks/chunk-6PVPNMXU.js +0 -29
  298. package/chunks/chunk-7362QS5B.js +0 -2256
  299. package/chunks/chunk-FMXMKPI5.js +0 -1780
  300. package/chunks/chunk-GLNBDYUX.js +0 -38
  301. package/chunks/chunk-HTR4WV6U.js +0 -327
  302. package/chunks/chunk-KWK7UE6L.js +0 -6194
  303. package/chunks/chunk-M7WBGLYP.js +0 -151
  304. package/chunks/chunk-NABLFI57.js +0 -82
  305. package/chunks/chunk-OQ5SYCPE.js +0 -10017
  306. package/chunks/chunk-OZYV6F53.js +0 -391
  307. package/chunks/chunk-TJQXJJX7.js +0 -121
  308. package/chunks/chunk-U7ZFW55U.js +0 -2098
  309. package/chunks/chunk-WHGVTP7Q.js +0 -1049
  310. package/chunks/chunk-XHATNRQA.js +0 -1500
  311. package/chunks/chunk-ZJVVETCV.js +0 -20600
  312. package/chunks/contextCommand-5YK3QNNJ.js +0 -73
  313. package/chunks/daemon-status-provider-FXMOD242.js +0 -81
  314. package/chunks/handleAutoUpdate-BCNVTQWW.js +0 -74
  315. package/chunks/initializer-5UB4SRPK.js +0 -79
  316. package/chunks/installationInfo-LNYJCXN3.js +0 -73
  317. package/chunks/list-NIZ77KPE.js +0 -82
  318. package/chunks/loadedSettingsAdapter-IQPRO2SO.js +0 -76
  319. package/chunks/managed-npm-update-GFRDCD77.js +0 -333
  320. package/chunks/mcp-TCUL7LT2.js +0 -76
  321. package/chunks/nonInteractiveCli-UHSHJDFD.js +0 -133
  322. package/chunks/ripGrep-WANMXNVT.js +0 -66
  323. package/chunks/sdk-exporters-grpc-ETLH47EP.js +0 -23214
  324. package/chunks/sdk-exporters-http-T3POX73F.js +0 -563
  325. package/chunks/sdk-impl-NSLPDH6I.js +0 -9193
  326. package/chunks/theme-manager-OZYKJG3W.js +0 -70
  327. package/chunks/total-session-admission-CNBQRM44.js +0 -76
  328. package/chunks/updateCheck-BPSMOZXS.js +0 -89
  329. package/chunks/web-search-KQPQFM7A.js +0 -731
  330. package/chunks/workspace-providers-status-4PLI2VFC.js +0 -79
  331. package/chunks/workspace-registry-I4ZRHGBS.js +0 -80
  332. package/chunks/workspace-service-RXYBWBDJ.js +0 -91
  333. package/chunks/workspace-skills-status-35Z2FU4I.js +0 -78
  334. package/chunks/write-file-KCL5RI2I.js +0 -66
  335. package/web-shell/assets/channel-4N2UIFcG.js +0 -1
  336. package/web-shell/assets/classDiagram-4FO5ZUOK-Q4dYOtsh.js +0 -1
  337. package/web-shell/assets/classDiagram-v2-Q7XG4LA2-Q4dYOtsh.js +0 -1
  338. package/web-shell/assets/index-B7jzUZ_s.css +0 -5
  339. package/web-shell/assets/index-gE8OWwj_.js +0 -1197
  340. package/web-shell/assets/stateDiagram-v2-BHNVJYJU-xXU_zO2Z.js +0 -1
  341. package/chunks/{chunk-QZJY47IE.js → chunk-PEJWA3QQ.js} +5 -5
@@ -0,0 +1,71 @@
1
+ // Force strict mode and setup for ESM
2
+ "use strict";
3
+ import {
4
+ createWorkspaceSkillsStatusProvider
5
+ } from "./chunk-4ILMYHEI.js";
6
+ import "./chunk-2W3OOD4W.js";
7
+ import "./chunk-VDWBQ5AW.js";
8
+ import "./chunk-33XUAINQ.js";
9
+ import "./chunk-RKUWKYED.js";
10
+ import "./chunk-GOXKNSDZ.js";
11
+ import "./chunk-IDS7MSUP.js";
12
+ import "./chunk-TKLLK6XQ.js";
13
+ import "./chunk-TIH2ZTOC.js";
14
+ import "./chunk-QRUIS3DN.js";
15
+ import "./chunk-I2PYAYFM.js";
16
+ import "./chunk-ALGGS7UH.js";
17
+ import "./chunk-MR3PXB6E.js";
18
+ import "./chunk-OWAK7LMW.js";
19
+ import "./chunk-KX6UK4VJ.js";
20
+ import "./chunk-5M6IDOMF.js";
21
+ import "./chunk-T4TZQJ7W.js";
22
+ import "./chunk-H6XPXXMH.js";
23
+ import "./chunk-EAUYY7SS.js";
24
+ import "./chunk-FSL5W5TI.js";
25
+ import "./chunk-OONJNQ42.js";
26
+ import "./chunk-D2VIDMVM.js";
27
+ import "./chunk-E2UVIFI2.js";
28
+ import "./chunk-XU457J4V.js";
29
+ import "./chunk-VDDGDZMA.js";
30
+ import "./chunk-EIAK6Q2B.js";
31
+ import "./chunk-SZRN75WQ.js";
32
+ import "./chunk-HTO4JFDZ.js";
33
+ import "./chunk-CPBF7KYF.js";
34
+ import "./chunk-CPCVCKKF.js";
35
+ import "./chunk-6AM5D4ME.js";
36
+ import "./chunk-G45X5TRN.js";
37
+ import "./chunk-PBATSWUQ.js";
38
+ import "./chunk-ZEOZL37W.js";
39
+ import "./chunk-OOCI5VVU.js";
40
+ import "./chunk-BRRF37CO.js";
41
+ import "./chunk-BMWMT5Y2.js";
42
+ import "./chunk-JESCGQM3.js";
43
+ import "./chunk-ZFKNWQGQ.js";
44
+ import "./chunk-4WKAA4KS.js";
45
+ import "./chunk-CR3C7WXL.js";
46
+ import "./chunk-VGC4I5JJ.js";
47
+ import "./chunk-JD3MKVKL.js";
48
+ import "./chunk-UEY4AYUL.js";
49
+ import "./chunk-BDBMYST4.js";
50
+ import "./chunk-EZVDJFZ7.js";
51
+ import "./chunk-OP4MOGXF.js";
52
+ import "./chunk-XVNQMZ2I.js";
53
+ import "./chunk-FEOZBUMT.js";
54
+ import "./chunk-DJ2GSRLV.js";
55
+ import "./chunk-6EFTQYW7.js";
56
+ import "./chunk-MAQQGNQ5.js";
57
+ import "./chunk-A4UCTEB5.js";
58
+ import "./chunk-XWRJCPHC.js";
59
+ import "./chunk-TYQMGACW.js";
60
+ import "./chunk-TYAMGABM.js";
61
+ import "./chunk-FCMNKVXT.js";
62
+ import "./chunk-C27BYUX6.js";
63
+ import "./chunk-75DOP5OR.js";
64
+ import "./chunk-DMTGGOSA.js";
65
+ import "./chunk-YQ3U5MUC.js";
66
+ import "./chunk-TB6UDU4T.js";
67
+ import "./chunk-5O2XNYP6.js";
68
+ import "./chunk-J2S4EL5Y.js";
69
+ export {
70
+ createWorkspaceSkillsStatusProvider
71
+ };
@@ -0,0 +1,596 @@
1
+ // Force strict mode and setup for ESM
2
+ "use strict";
3
+ import {
4
+ checkTeamMemorySecrets
5
+ } from "./chunk-SEKHYHMS.js";
6
+ import {
7
+ CommitAttributionService,
8
+ FileEncoding,
9
+ StructuredToolError,
10
+ checkPriorRead,
11
+ createPatchSmart,
12
+ detectLineEnding,
13
+ getDiffStat,
14
+ needsUtf8Bom
15
+ } from "./chunk-KX6UK4VJ.js";
16
+ import "./chunk-5M6IDOMF.js";
17
+ import "./chunk-T4TZQJ7W.js";
18
+ import "./chunk-H6XPXXMH.js";
19
+ import "./chunk-EAUYY7SS.js";
20
+ import "./chunk-FSL5W5TI.js";
21
+ import "./chunk-OONJNQ42.js";
22
+ import "./chunk-D2VIDMVM.js";
23
+ import "./chunk-E2UVIFI2.js";
24
+ import "./chunk-XU457J4V.js";
25
+ import "./chunk-VDDGDZMA.js";
26
+ import "./chunk-EIAK6Q2B.js";
27
+ import "./chunk-SZRN75WQ.js";
28
+ import "./chunk-HTO4JFDZ.js";
29
+ import "./chunk-CPBF7KYF.js";
30
+ import "./chunk-CPCVCKKF.js";
31
+ import "./chunk-6AM5D4ME.js";
32
+ import "./chunk-G45X5TRN.js";
33
+ import "./chunk-PBATSWUQ.js";
34
+ import "./chunk-ZEOZL37W.js";
35
+ import "./chunk-OOCI5VVU.js";
36
+ import "./chunk-BRRF37CO.js";
37
+ import "./chunk-BMWMT5Y2.js";
38
+ import "./chunk-JESCGQM3.js";
39
+ import {
40
+ FileOperationEvent,
41
+ fileExists,
42
+ getLanguageFromFilePath,
43
+ getSpecificMimeType,
44
+ logFileOperation
45
+ } from "./chunk-ZFKNWQGQ.js";
46
+ import "./chunk-4WKAA4KS.js";
47
+ import "./chunk-CR3C7WXL.js";
48
+ import "./chunk-VGC4I5JJ.js";
49
+ import {
50
+ isAnyAutoMemPath,
51
+ isTeamAutoMemPath
52
+ } from "./chunk-JD3MKVKL.js";
53
+ import "./chunk-UEY4AYUL.js";
54
+ import "./chunk-BDBMYST4.js";
55
+ import "./chunk-EZVDJFZ7.js";
56
+ import {
57
+ BaseDeclarativeTool,
58
+ BaseToolInvocation,
59
+ ToolDisplayNames,
60
+ ToolNames
61
+ } from "./chunk-OP4MOGXF.js";
62
+ import "./chunk-XVNQMZ2I.js";
63
+ import "./chunk-FEOZBUMT.js";
64
+ import "./chunk-DJ2GSRLV.js";
65
+ import "./chunk-6EFTQYW7.js";
66
+ import "./chunk-MAQQGNQ5.js";
67
+ import "./chunk-A4UCTEB5.js";
68
+ import "./chunk-XWRJCPHC.js";
69
+ import "./chunk-TYQMGACW.js";
70
+ import "./chunk-TYAMGABM.js";
71
+ import "./chunk-FCMNKVXT.js";
72
+ import {
73
+ createDebugLogger,
74
+ getErrorMessage,
75
+ isNodeError,
76
+ makeRelative,
77
+ shortenPath,
78
+ unescapePath
79
+ } from "./chunk-C27BYUX6.js";
80
+ import "./chunk-75DOP5OR.js";
81
+ import "./chunk-DMTGGOSA.js";
82
+ import "./chunk-YQ3U5MUC.js";
83
+ import "./chunk-TB6UDU4T.js";
84
+ import {
85
+ init_esbuild_shims
86
+ } from "./chunk-5O2XNYP6.js";
87
+ import {
88
+ __name
89
+ } from "./chunk-J2S4EL5Y.js";
90
+
91
+ // packages/core/src/tools/write-file.ts
92
+ init_esbuild_shims();
93
+ import fs from "node:fs";
94
+ import path from "node:path";
95
+ var debugLogger = createDebugLogger("WRITE_FILE");
96
+ var ARTIFACT_LIKE_EXTENSIONS = /* @__PURE__ */ new Set([
97
+ ".htm",
98
+ ".html",
99
+ ".ipynb",
100
+ ".jpeg",
101
+ ".jpg",
102
+ ".pdf",
103
+ ".png",
104
+ ".svg",
105
+ ".webp"
106
+ ]);
107
+ var WriteFileToolInvocation = class extends BaseToolInvocation {
108
+ constructor(config, params) {
109
+ super(params);
110
+ this.config = config;
111
+ }
112
+ static {
113
+ __name(this, "WriteFileToolInvocation");
114
+ }
115
+ toolLocations() {
116
+ return [{ path: this.params.file_path }];
117
+ }
118
+ getDescription() {
119
+ const relativePath = makeRelative(
120
+ this.params.file_path,
121
+ this.config.getTargetDir()
122
+ );
123
+ return `Writing to ${shortenPath(relativePath)}`;
124
+ }
125
+ /**
126
+ * Write operations always need user confirmation, except for the private
127
+ * managed auto-memory files (user/project) which are written autonomously.
128
+ * Team memory is shared and committed to the repo, so it is NOT auto-allowed
129
+ * like the private tiers — writes default to 'ask'. (In AUTO_EDIT/YOLO the
130
+ * user has globally opted into auto-approval; team writes still surface in the
131
+ * git diff for review before commit.)
132
+ */
133
+ async getDefaultPermission() {
134
+ const projectRoot = this.config.getProjectRoot();
135
+ const filePath = path.resolve(this.params.file_path);
136
+ if (isTeamAutoMemPath(filePath, projectRoot)) {
137
+ return "ask";
138
+ }
139
+ if (isAnyAutoMemPath(filePath, projectRoot)) {
140
+ return "allow";
141
+ }
142
+ return "ask";
143
+ }
144
+ /**
145
+ * Constructs the write-file diff confirmation details.
146
+ */
147
+ async getConfirmationDetails(_abortSignal) {
148
+ let originalContent = "";
149
+ let fileExists2 = await fileExists(this.params.file_path);
150
+ if (!this.config.getFileReadCacheDisabled()) {
151
+ const decision = await checkPriorRead(
152
+ this.config.getFileReadCache(),
153
+ this.params.file_path,
154
+ "overwriting"
155
+ );
156
+ if (!decision.ok) {
157
+ throw new StructuredToolError(decision.rawMessage, decision.type);
158
+ }
159
+ }
160
+ if (fileExists2) {
161
+ try {
162
+ const { content } = await this.config.getFileSystemService().readTextFile({ path: this.params.file_path });
163
+ originalContent = content;
164
+ } catch (err) {
165
+ if (isNodeError(err) && err.code === "ENOENT") {
166
+ fileExists2 = false;
167
+ } else {
168
+ throw new Error(
169
+ `Error reading existing file for confirmation: ${getErrorMessage(err)}`
170
+ );
171
+ }
172
+ }
173
+ }
174
+ if (fileExists2 && !this.config.getFileReadCacheDisabled()) {
175
+ const postDecision = await checkPriorRead(
176
+ this.config.getFileReadCache(),
177
+ this.params.file_path,
178
+ "overwriting",
179
+ { expectExisting: true }
180
+ );
181
+ if (!postDecision.ok) {
182
+ debugLogger.warn("post-read TOCTOU rejection (confirmation)", {
183
+ path: this.params.file_path,
184
+ reason: postDecision.type
185
+ });
186
+ throw new StructuredToolError(
187
+ postDecision.rawMessage,
188
+ postDecision.type
189
+ );
190
+ }
191
+ }
192
+ const relativePath = makeRelative(
193
+ this.params.file_path,
194
+ this.config.getTargetDir()
195
+ );
196
+ const fileName = path.basename(this.params.file_path);
197
+ const fileDiff = createPatchSmart(
198
+ fileName,
199
+ originalContent,
200
+ this.params.content,
201
+ "Current",
202
+ "Proposed"
203
+ );
204
+ const confirmationDetails = {
205
+ type: "edit",
206
+ title: `Confirm Write: ${shortenPath(relativePath)}`,
207
+ fileName,
208
+ filePath: this.params.file_path,
209
+ fileDiff,
210
+ originalContent,
211
+ newContent: this.params.content,
212
+ onConfirm: /* @__PURE__ */ __name(async (outcome) => {
213
+ if (outcome === "proceed_always" /* ProceedAlways */) {
214
+ this.config.setApprovalMode("auto-edit" /* AUTO_EDIT */);
215
+ }
216
+ }, "onConfirm")
217
+ };
218
+ return confirmationDetails;
219
+ }
220
+ async execute(_abortSignal) {
221
+ const { file_path, content, ai_proposed_content, modified_by_user } = this.params;
222
+ let fileExists2 = await fileExists(file_path);
223
+ let originalContent = "";
224
+ let useBOM = false;
225
+ let detectedEncoding;
226
+ let detectedLineEnding;
227
+ const dirName = path.dirname(file_path);
228
+ const teamMemoryError = checkTeamMemorySecrets(
229
+ file_path,
230
+ content,
231
+ this.config.getProjectRoot()
232
+ );
233
+ if (teamMemoryError) {
234
+ return {
235
+ llmContent: `[ERROR: ${teamMemoryError}]`,
236
+ returnDisplay: teamMemoryError,
237
+ error: {
238
+ message: teamMemoryError,
239
+ type: "invalid_tool_params" /* INVALID_TOOL_PARAMS */
240
+ }
241
+ };
242
+ }
243
+ if (!this.config.getFileReadCacheDisabled()) {
244
+ const decision = await checkPriorRead(
245
+ this.config.getFileReadCache(),
246
+ file_path,
247
+ "overwriting"
248
+ );
249
+ if (!decision.ok) {
250
+ return {
251
+ llmContent: decision.rawMessage,
252
+ returnDisplay: `Error: ${decision.displayMessage}`,
253
+ error: {
254
+ message: decision.rawMessage,
255
+ type: decision.type
256
+ }
257
+ };
258
+ }
259
+ }
260
+ if (fileExists2) {
261
+ try {
262
+ const fileInfo = await this.config.getFileSystemService().readTextFile({ path: file_path });
263
+ if (fileInfo._meta?.bom !== void 0) {
264
+ useBOM = fileInfo._meta.bom;
265
+ } else {
266
+ useBOM = fileInfo.content.length > 0 && fileInfo.content.codePointAt(0) === 65279;
267
+ }
268
+ detectedEncoding = fileInfo._meta?.encoding || "utf-8";
269
+ detectedLineEnding = detectLineEnding(fileInfo.content);
270
+ originalContent = fileInfo.content;
271
+ fileExists2 = true;
272
+ } catch (err) {
273
+ if (isNodeError(err) && err.code === "ENOENT") {
274
+ fileExists2 = false;
275
+ } else {
276
+ const error = {
277
+ message: getErrorMessage(err),
278
+ code: isNodeError(err) ? err.code : void 0
279
+ };
280
+ const errorMsg = error.code ? `Error checking existing file '${file_path}': ${error.message} (${error.code})` : `Error checking existing file: ${error.message}`;
281
+ return {
282
+ llmContent: errorMsg,
283
+ returnDisplay: errorMsg,
284
+ error: {
285
+ message: errorMsg,
286
+ type: "file_write_failure" /* FILE_WRITE_FAILURE */
287
+ }
288
+ };
289
+ }
290
+ }
291
+ }
292
+ if (fileExists2 && !this.config.getFileReadCacheDisabled()) {
293
+ const postDecision = await checkPriorRead(
294
+ this.config.getFileReadCache(),
295
+ file_path,
296
+ "overwriting",
297
+ { expectExisting: true }
298
+ );
299
+ if (!postDecision.ok) {
300
+ debugLogger.warn("post-read TOCTOU rejection (execute)", {
301
+ path: file_path,
302
+ reason: postDecision.type
303
+ });
304
+ return {
305
+ llmContent: postDecision.rawMessage,
306
+ returnDisplay: `Error: ${postDecision.displayMessage}`,
307
+ error: {
308
+ message: postDecision.rawMessage,
309
+ type: postDecision.type
310
+ }
311
+ };
312
+ }
313
+ }
314
+ if (!fileExists2) {
315
+ const userEncoding = this.config.getDefaultFileEncoding();
316
+ if (userEncoding === FileEncoding.UTF8_BOM) {
317
+ useBOM = true;
318
+ } else if (userEncoding === void 0) {
319
+ useBOM = needsUtf8Bom(file_path);
320
+ }
321
+ detectedEncoding = void 0;
322
+ }
323
+ try {
324
+ await this.config.getFileHistoryService().trackEdit(file_path);
325
+ } catch {
326
+ }
327
+ if (!this.config.getFileReadCacheDisabled()) {
328
+ const writeDecision = await checkPriorRead(
329
+ this.config.getFileReadCache(),
330
+ file_path,
331
+ "overwriting",
332
+ // If the file existed when we read it (`fileExists` is still
333
+ // true after readTextFile), ENOENT here means the original
334
+ // target disappeared between the post-read check and now —
335
+ // reject rather than fall through and silently re-create the
336
+ // file from stale bytes. For new-file creation
337
+ // (`fileExists === false`), ENOENT is the expected pre-write
338
+ // state (ok:true → writeTextFile creates).
339
+ { expectExisting: fileExists2 }
340
+ );
341
+ if (!writeDecision.ok) {
342
+ debugLogger.warn("pre-write TOCTOU rejection", {
343
+ path: file_path,
344
+ reason: writeDecision.type
345
+ });
346
+ return {
347
+ llmContent: writeDecision.rawMessage,
348
+ returnDisplay: `Error: ${writeDecision.displayMessage}`,
349
+ error: {
350
+ message: writeDecision.rawMessage,
351
+ type: writeDecision.type
352
+ }
353
+ };
354
+ }
355
+ }
356
+ if (!fileExists2) {
357
+ fs.mkdirSync(dirName, { recursive: true });
358
+ }
359
+ try {
360
+ await this.config.getFileSystemService().writeTextFile({
361
+ path: file_path,
362
+ content,
363
+ _meta: {
364
+ bom: useBOM,
365
+ encoding: detectedEncoding,
366
+ lineEnding: detectedLineEnding
367
+ }
368
+ });
369
+ if (!modified_by_user) {
370
+ CommitAttributionService.getInstance().recordEdit(
371
+ file_path,
372
+ fileExists2 ? originalContent : null,
373
+ content
374
+ );
375
+ }
376
+ try {
377
+ const postWriteStats = fs.statSync(file_path);
378
+ this.config.getFileReadCache().recordWrite(file_path, postWriteStats);
379
+ } catch {
380
+ }
381
+ const fileName = path.basename(file_path);
382
+ const currentContentForDiff = originalContent;
383
+ const fileDiff = createPatchSmart(
384
+ fileName,
385
+ currentContentForDiff,
386
+ content,
387
+ "Original",
388
+ "Written"
389
+ );
390
+ const originallyProposedContent = ai_proposed_content || content;
391
+ const diffStat = getDiffStat(
392
+ fileName,
393
+ currentContentForDiff,
394
+ originallyProposedContent,
395
+ content
396
+ );
397
+ const llmSuccessMessageParts = [
398
+ !fileExists2 ? `Successfully created and wrote to new file: ${file_path}.` : `Successfully overwrote file: ${file_path}.`
399
+ ];
400
+ if (modified_by_user) {
401
+ llmSuccessMessageParts.push(
402
+ `User modified the \`content\` to be: ${content}`
403
+ );
404
+ }
405
+ const artifactReminder = buildRecordArtifactReminder(
406
+ this.config,
407
+ file_path
408
+ );
409
+ if (artifactReminder) {
410
+ llmSuccessMessageParts.push(artifactReminder);
411
+ }
412
+ const mimetype = getSpecificMimeType(file_path);
413
+ const programmingLanguage = getLanguageFromFilePath(file_path);
414
+ const extension = path.extname(file_path);
415
+ const operation = !fileExists2 ? "create" /* CREATE */ : "update" /* UPDATE */;
416
+ const lineCount = content.split("\n").length;
417
+ logFileOperation(
418
+ this.config,
419
+ new FileOperationEvent(
420
+ WriteFileTool.Name,
421
+ operation,
422
+ lineCount,
423
+ mimetype,
424
+ extension,
425
+ programmingLanguage
426
+ )
427
+ );
428
+ const displayResult = {
429
+ fileDiff,
430
+ fileName,
431
+ originalContent,
432
+ newContent: content,
433
+ diffStat
434
+ };
435
+ return {
436
+ llmContent: llmSuccessMessageParts.join(" "),
437
+ returnDisplay: displayResult
438
+ };
439
+ } catch (error) {
440
+ let errorMsg;
441
+ let errorType = "file_write_failure" /* FILE_WRITE_FAILURE */;
442
+ if (isNodeError(error)) {
443
+ errorMsg = `Error writing to file '${file_path}': ${error.message} (${error.code})`;
444
+ if (error.code === "EACCES") {
445
+ errorMsg = `Permission denied writing to file: ${file_path} (${error.code})`;
446
+ errorType = "permission_denied" /* PERMISSION_DENIED */;
447
+ } else if (error.code === "ENOSPC") {
448
+ errorMsg = `No space left on device: ${file_path} (${error.code})`;
449
+ errorType = "no_space_left" /* NO_SPACE_LEFT */;
450
+ } else if (error.code === "EISDIR") {
451
+ errorMsg = `Target is a directory, not a file: ${file_path} (${error.code})`;
452
+ errorType = "target_is_directory" /* TARGET_IS_DIRECTORY */;
453
+ }
454
+ if (this.config.getDebugMode() && error.stack) {
455
+ debugLogger.debug("Write file error stack:", error.stack);
456
+ }
457
+ } else {
458
+ errorMsg = `Error writing to file: ${getErrorMessage(error)}`;
459
+ }
460
+ return {
461
+ llmContent: errorMsg,
462
+ returnDisplay: errorMsg,
463
+ error: {
464
+ message: errorMsg,
465
+ type: errorType
466
+ }
467
+ };
468
+ }
469
+ }
470
+ };
471
+ function buildRecordArtifactReminder(config, filePath) {
472
+ if (!config.isRecordArtifactEnabled()) {
473
+ return null;
474
+ }
475
+ if (!ARTIFACT_LIKE_EXTENSIONS.has(path.extname(filePath).toLowerCase())) {
476
+ return null;
477
+ }
478
+ const relativePath = path.relative(config.getTargetDir(), filePath);
479
+ if (!relativePath || relativePath === ".." || relativePath.startsWith(`..${path.sep}`) || path.isAbsolute(relativePath)) {
480
+ return null;
481
+ }
482
+ const workspacePath = relativePath.split(path.sep).join("/");
483
+ return `If this file is a reusable user-facing artifact, call record_artifact with workspacePath "${workspacePath}" before telling the user it is available in the artifacts panel.`;
484
+ }
485
+ __name(buildRecordArtifactReminder, "buildRecordArtifactReminder");
486
+ var WriteFileTool = class _WriteFileTool extends BaseDeclarativeTool {
487
+ constructor(config) {
488
+ super(
489
+ _WriteFileTool.Name,
490
+ ToolDisplayNames.WRITE_FILE,
491
+ `Writes content to a specified file in the local filesystem. The file_path argument MUST be an absolute path. Always construct it by combining the project root with the file's relative path (e.g. project root '/path/to/project/' + relative 'foo/bar.txt' = '/path/to/project/foo/bar.txt'). If the user provides a relative path, resolve it against the project root first.
492
+
493
+ The user has the ability to modify \`content\`. If modified, this will be stated in the response.`,
494
+ "edit" /* Edit */,
495
+ {
496
+ properties: {
497
+ file_path: {
498
+ description: "The absolute path to the file to write to (e.g., '/home/user/project/file.txt'). Relative paths are not supported.",
499
+ type: "string"
500
+ },
501
+ content: {
502
+ description: "The content to write to the file.",
503
+ type: "string"
504
+ }
505
+ },
506
+ required: ["file_path", "content"],
507
+ type: "object"
508
+ }
509
+ );
510
+ this.config = config;
511
+ }
512
+ static {
513
+ __name(this, "WriteFileTool");
514
+ }
515
+ static Name = ToolNames.WRITE_FILE;
516
+ validateToolParamValues(params) {
517
+ const filePath = unescapePath(params.file_path.trim());
518
+ params.file_path = filePath;
519
+ if (!filePath) {
520
+ return `Missing or empty "file_path"`;
521
+ }
522
+ if (!path.isAbsolute(filePath)) {
523
+ return `File path must be absolute: ${filePath}`;
524
+ }
525
+ try {
526
+ if (fs.existsSync(filePath)) {
527
+ const stats = fs.lstatSync(filePath);
528
+ if (stats.isDirectory()) {
529
+ return `Path is a directory, not a file: ${filePath}`;
530
+ }
531
+ }
532
+ } catch (statError) {
533
+ return `Error accessing path properties for validation: ${filePath}. Reason: ${getErrorMessage(
534
+ statError
535
+ )}`;
536
+ }
537
+ const teamMemoryError = checkTeamMemorySecrets(
538
+ filePath,
539
+ params.content ?? "",
540
+ this.config.getProjectRoot()
541
+ );
542
+ if (teamMemoryError) {
543
+ return teamMemoryError;
544
+ }
545
+ return null;
546
+ }
547
+ createInvocation(params) {
548
+ return new WriteFileToolInvocation(this.config, params);
549
+ }
550
+ toAutoClassifierInput(params) {
551
+ const content = params.content ?? "";
552
+ return {
553
+ file_path: params.file_path,
554
+ byte_count: Buffer.byteLength(content, "utf8"),
555
+ content_preview: content.slice(0, 300),
556
+ content_truncated: content.length > 300
557
+ };
558
+ }
559
+ getModifyContext(_abortSignal) {
560
+ return {
561
+ getFilePath: /* @__PURE__ */ __name((params) => params.file_path, "getFilePath"),
562
+ getCurrentContent: /* @__PURE__ */ __name(async (params) => {
563
+ const fileExists2 = await fileExists(params.file_path);
564
+ if (fileExists2) {
565
+ try {
566
+ const { content } = await this.config.getFileSystemService().readTextFile({ path: params.file_path });
567
+ return content;
568
+ } catch (err) {
569
+ if (!isNodeError(err) || err.code !== "ENOENT") throw err;
570
+ return "";
571
+ }
572
+ } else {
573
+ return "";
574
+ }
575
+ }, "getCurrentContent"),
576
+ getProposedContent: /* @__PURE__ */ __name(async (params) => params.content, "getProposedContent"),
577
+ createUpdatedParams: /* @__PURE__ */ __name((_oldContent, modifiedProposedContent, originalParams) => {
578
+ const content = originalParams.content;
579
+ return {
580
+ ...originalParams,
581
+ ai_proposed_content: content,
582
+ content: modifiedProposedContent,
583
+ modified_by_user: true
584
+ };
585
+ }, "createUpdatedParams")
586
+ };
587
+ }
588
+ };
589
+ export {
590
+ WriteFileTool
591
+ };
592
+ /**
593
+ * @license
594
+ * Copyright 2025 Google LLC
595
+ * SPDX-License-Identifier: Apache-2.0
596
+ */
@@ -1884,11 +1884,7 @@ var zh_default = {
1884
1884
  "Qwen Code update available! {{current}} \u2192 {{latest}}": "Qwen Code \u6709\u53EF\u7528\u66F4\u65B0\uFF01{{current}} \u2192 {{latest}}",
1885
1885
  "A new version of Qwen Code is available! {{current}} \u2192 {{latest}}": "Qwen Code \u6709\u65B0\u7248\u672C\u53EF\u7528\uFF01{{current}} \u2192 {{latest}}",
1886
1886
  "Qwen Code {{version}} is up to date!": "Qwen Code {{version}} \u5DF2\u662F\u6700\u65B0\uFF01",
1887
- "Failed to check for updates ({{reason}}). Please check your network or registry configuration.": "\u68C0\u67E5\u66F4\u65B0\u5931\u8D25\uFF08{{reason}}\uFF09\u3002\u8BF7\u68C0\u67E5\u7F51\u7EDC\u6216 registry \u914D\u7F6E\u3002",
1888
- "Update check skipped ({{reason}}) \u2014 run /update to retry.": "\u5DF2\u8DF3\u8FC7\u66F4\u65B0\u68C0\u67E5\uFF08{{reason}}\uFF09\u2014 \u53EF\u8FD0\u884C /update \u91CD\u8BD5\u3002",
1889
- "registry did not respond within {{seconds}}s": "registry \u5728 {{seconds}} \u79D2\u5185\u672A\u54CD\u5E94",
1890
- "registry unreachable": "registry \u65E0\u6CD5\u8FDE\u63A5",
1891
- "registry error": "registry \u9519\u8BEF",
1887
+ "Failed to check for updates. Please check your network or registry configuration.": "\u68C0\u67E5\u66F4\u65B0\u5931\u8D25\u3002\u8BF7\u68C0\u67E5\u7F51\u7EDC\u6216 registry \u914D\u7F6E\u3002",
1892
1888
  "Unable to check for updates: {{reason}}": "\u65E0\u6CD5\u68C0\u67E5\u66F4\u65B0\uFF1A{{reason}}",
1893
1889
  "Update successful! The new version will be used on your next run.": "\u66F4\u65B0\u6210\u529F\uFF01\u65B0\u7248\u672C\u5C06\u5728\u4E0B\u6B21\u8FD0\u884C\u65F6\u751F\u6548\u3002",
1894
1890
  "Update downloaded. It will be applied after you exit this session.": "\u66F4\u65B0\u5DF2\u4E0B\u8F7D\u3002\u5C06\u5728\u9000\u51FA\u5F53\u524D\u4F1A\u8BDD\u540E\u5E94\u7528\u3002",
@@ -1717,11 +1717,7 @@ var zh_TW_default = {
1717
1717
  "Qwen Code update available! {{current}} \u2192 {{latest}}": "Qwen Code \u6709\u53EF\u7528\u66F4\u65B0\uFF01{{current}} \u2192 {{latest}}",
1718
1718
  "A new version of Qwen Code is available! {{current}} \u2192 {{latest}}": "Qwen Code \u6709\u65B0\u7248\u672C\u53EF\u7528\uFF01{{current}} \u2192 {{latest}}",
1719
1719
  "Qwen Code {{version}} is up to date!": "Qwen Code {{version}} \u5DF2\u662F\u6700\u65B0\uFF01",
1720
- "Failed to check for updates ({{reason}}). Please check your network or registry configuration.": "\u6AA2\u67E5\u66F4\u65B0\u5931\u6557\uFF08{{reason}}\uFF09\u3002\u8ACB\u6AA2\u67E5\u7DB2\u8DEF\u6216 registry \u8A2D\u5B9A\u3002",
1721
- "Update check skipped ({{reason}}) \u2014 run /update to retry.": "\u5DF2\u7565\u904E\u66F4\u65B0\u6AA2\u67E5\uFF08{{reason}}\uFF09\u2014 \u53EF\u57F7\u884C /update \u91CD\u8A66\u3002",
1722
- "registry did not respond within {{seconds}}s": "registry \u5728 {{seconds}} \u79D2\u5167\u672A\u56DE\u61C9",
1723
- "registry unreachable": "registry \u7121\u6CD5\u9023\u7DDA",
1724
- "registry error": "registry \u932F\u8AA4",
1720
+ "Failed to check for updates. Please check your network or registry configuration.": "\u6AA2\u67E5\u66F4\u65B0\u5931\u6557\u3002\u8ACB\u6AA2\u67E5\u7DB2\u8DEF\u6216 registry \u8A2D\u5B9A\u3002",
1725
1721
  "Unable to check for updates: {{reason}}": "\u7121\u6CD5\u6AA2\u67E5\u66F4\u65B0\uFF1A{{reason}}",
1726
1722
  "Update successful! The new version will be used on your next run.": "\u66F4\u65B0\u6210\u529F\uFF01\u65B0\u7248\u672C\u5C07\u5728\u4E0B\u6B21\u57F7\u884C\u6642\u751F\u6548\u3002",
1727
1723
  "Update downloaded. It will be applied after you exit this session.": "\u66F4\u65B0\u5DF2\u4E0B\u8F09\u3002\u5C07\u5728\u7D50\u675F\u76EE\u524D\u5DE5\u4F5C\u968E\u6BB5\u5F8C\u5957\u7528\u3002",