掘金 AI· 德尔塔A·· 2026-10-29AI 评分59
run_command 在 Windows 上的三类报错与 pwsh、cmd 三级降级方案
同一条命令,在 Windows 上炸了三种方式
AI 导读
作者为自己的 Agent 工具 run_command 做跨平台适配,在 Windows 上遇到三类原因各异的报错:PowerShell 5.1 不认 &&、cp936 编码造成的双层乱码,以及 powershell.exe 不在 PATH 中的 ENOENT。
来源:掘金 AI · juejin.cn