VS Code (Copilot agent)
Ready VS Code family probe / automationProfile Windows Difficulty Easy
The family anchor: the GitHub Copilot agent runs commands through the editor's automation terminal and hits the family-shared probe by default — no configuration needed.
settings.json · explicit automationProfile (the probe hits by default; this is for precise control)
{
"terminal.integrated.automationProfile.windows": {
"path": "C:\\Users\\<你>\\AppData\\Local\\Programs\\Niubash\\niu.exe",
"args": []
}
} Steps
- Default: the installer-placed C:\Program Files\Git\bin\bash.exe hits the family-shared probe — no configuration needed
- For precise control: point automationProfile at niu.exe; every command the Copilot agent runs through the automation terminal inherits it
Verify
echo "SHELL=$SHELL"; uname -s — expect uname -s to start with MSYS_NT-
Rollback
Delete the terminal.integrated.automationProfile.windows setting Notes & pitfalls
- All nine family entries (this one plus Windsurf, Trae, Kiro, ZCode, Cline, Roo Code, Kilo Code, Continue) share one hard-coded probe sequence (the two Program Files Git paths → bin/bash.exe next to git on PATH); fix it once and the whole family follows
- The probe sequence was read from a ZCode app.asar (verified locally); the two Program Files candidates stay deliberately unclaimed (niubash#398 ruling) — the which(git) arm is what lands on niu
- On a PowerShell/cmd fallback, set automationProfile and done
Sources
agents.md#vs-code(家族名单 + ZCode app.asar 本地核实)- agents.md (the complete probe-mechanism document) ↗
Chinese edition of this page: /agents/vs-code/