## Do You like to _YOLO_? **You can auto-approve tool calls and terminal commands in Copilot’s Agent mode**. --- > With ❤️ from **[Eleanor](https://intellectronica.net/)** `< @intellectronica >` ( [OKIGU Consulting](https://okigu.com/) | [Elite AI-assisted Coding](https://elite-ai-assisted-coding.dev/) ) --- ### Auto-approve specific terminal commands Add an allow/deny list in your VS Code `settings.json`: ```json { // Auto-approve only these terminal commands in Agent mode "chat.tools.terminal.autoApprove": { "/^git\\s+(status|diff|log|show)\\b/": true, "/^npm\\s+(test|run\\s+lint)\\b/": true, "/^pnpm\\s+(test|lint)\\b/": true, "/^mvn\\s+test\\b/": true, // Keep risky commands explicitly gated "rm": false, "rmdir": false, "del": false, "kill": false, "chmod": false, "chown": false, "/^git\\s+(push|reset|revert|clean)\\b/": false } } ``` This uses regex keys for patterns (wrap them in `/…/`). Anything not matched falls back to the normal confirmation dialog. ([code.visualstudio.com][1]) ### Auto-approve all tool calls Flip this experimental switch: ```json { "chat.tools.autoApprove": true } ``` That removes confirmations for every tool invocation, which is handy for sandboxes but risky on real projects. ([code.visualstudio.com][2]) ### Where to switch it on in the UI * **Settings → “Agent mode”**: look for **Auto-approve tools** and **Auto-approve terminal commands** toggles, or search for `chat.tools.autoApprove` and `chat.tools.terminal.autoApprove`. ([code.visualstudio.com][2]) ### Notes * These features are marked **Experimental** in current VS Code docs; make sure you’re on a recent VS Code + Copilot extension. ([code.visualstudio.com][2]) [1]: https://code.visualstudio.com/docs/copilot/reference/copilot-settings "GitHub Copilot in VS Code settings reference" [2]: https://code.visualstudio.com/docs/copilot/reference/copilot-vscode-features "GitHub Copilot in VS Code cheat sheet"