⚡ Auto-accept Amazon Q agent tool execution in VS Code — no more clicking Run manually.
|
When auto-accept is ON, you CANNOT type in the Amazon Q chat input box. The extension polls commands that steal focus from the chat panel. Always press |
When Amazon Q Developer runs in agent mode, it asks for confirmation before:
- 🔧 Running shell commands → the
Runbutton - 📝 Editing your files → the
Acceptbutton - 📁 Reading files outside workspace → the
Allowbutton
This extension automatically clicks all of them for you. Hands-free agentic coding. 🚀
⚠️ Windows only: TheAllowbutton auto-click uses Windows UI Automation (PowerShell). It does not work on macOS or Linux.
Amazon Q suggests a command
↓
┌─────────┐
│ Run │ ← Extension auto-clicks this ✅
└─────────┘
↓
Command executes automatically
The extension polls aws.amazonq.runCmdExecution and aws.amazonq.inline.acceptEdit at a configurable interval. For the Allow button (read-only tools outside workspace), it uses Windows UI Automation via PowerShell to find and click the button directly in the VS Code webview. A concurrency lock (isRunning) ensures only one approval is in-flight at a time, preventing duplicate triggers.
- Download the
.vsixfile from Releases - Drag and drop into VS Code Extensions panel
- Reload VS Code — done! ✅
git clone https://github.com/CGIFM/amazonq-auto-accept.git
cd amazonq-auto-accept
npm install
npm run packageThen: Extensions → ··· → Install from VSIX… → select the .vsix file.
| Action | Shortcut | Description |
|---|---|---|
| 🔄 Toggle on/off | Ctrl+Shift+Q |
|
Ctrl+Shift+R |
Manual trigger |
Status bar indicator (bottom-right):
| Status | Meaning |
|---|---|
✅ Q-AutoRun v1.0.1 |
Auto-accept is ON |
❌ Q-AutoRun v1.0.1 |
Auto-accept is OFF |
💡 Tip: Click the status bar item to toggle on/off.
| Setting | Default | Description |
|---|---|---|
amazonqAutoAccept.enabled |
true |
Enable/disable auto-run |
amazonqAutoAccept.delayMs |
800 |
Polling interval in ms (200–5000) |
amazonqAutoAccept.showStatusBar |
true |
Show status bar indicator |
- VS Code ≥ 1.82.0
- Amazon Q Developer Extension installed and signed in
⚠️ This extension automatically approves Amazon Q agent tool executions. Shell commands and file edits suggested by Amazon Q will run without manual confirmation.
Recommendations:
- 🔍 Review the Amazon Q chat context before enabling
- 🔒 Press
Ctrl+Shift+Qto disable when working with sensitive environments - ⏱️ Set a longer polling interval for critical workloads
MIT — free and open source.
Made with ❤️ for the Amazon Q community
