Skip to content

Copilot CLI 在 Windows 上暴露 powershell 而非 bash,copilot-tools.md 的 bash 假设不成立 #93

Description

@qicesun

问题

skills/using-superpowers/references/copilot-tools.md 把 Copilot CLI 的异步 shell 记为 bash + async: true + read_bash / stop_bash / write_bash / list_bash,并把 Claude Code 的 Bash 映射到 bash

但在 Windows 上,实测的 Copilot CLI build 实际暴露的是 powershell(带 detach 布尔参数)+ read_powershell / stop_powershell / list_powershell没有 bash / async 家族。

影响

  1. 依赖 .sh 脚本的 skill(如 brainstorm 的 start-server.sh)在 powershell 下直接执行会报 The term 'scripts/start-server.sh' is not recognized...,必须显式 & "C:\Program Files\Git\bin\bash.exe" scripts/xxx.sh
  2. stop_powershell 无法停止 detach:true 启动的进程(本 build 指引:detached 需 Stop-Process -Id <PID>),因此以 stop_* 工具作为 detached server 的清理路径不可靠。
  3. 照搬 copilot-tools.md 的 bash 工具名会导致 agent 找不到工具而即兴,可能重现阻塞式启动等问题。

实测证据

  • 工具注册表中无 bash / read_bash / stop_bash;存在 powershell(带 detach) / read_powershell / stop_powershell / list_powershell
  • powershell 下裸跑 scripts/start-server.sh → "not recognized";经 & "C:\Program Files\Git\bin\bash.exe" ... 才能运行。

建议

  • 更新 copilot-tools.md 的"异步 Shell 会话"表,补充 powershell 变体(powershell + detachread_powershell / stop_powershell / list_powershell),或注明 Copilot CLI 工具面随平台/版本而异(Windows 常见 powershell)。
  • 在涉及运行 .sh / 长驻进程的 skill 指引里,采用 harness 无关的表述,并对 powershell 情形给出 Stop-Process / stop-server.sh 的可靠清理路径。

环境

GitHub Copilot CLI 1.0.69-1 / Windows / Node v24.17.0。

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions