-
Notifications
You must be signed in to change notification settings - Fork 2.6k
feat: Add keyboard shortcut for toggling auto-approve (Cmd/Ctrl+Alt+A) #8213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewing my own code again. It's like proofreading your own love letters - you always miss the embarrassing parts.
| */ | ||
| export const formatShortcut = (shortcut: string): string => { | ||
| return `(${shortcut})` | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing test coverage: This new utility file needs test coverage. Consider adding tests for all functions: isMac(), getModifierKey(), getAutoApproveShortcut(), and formatShortcut().
| /** | ||
| * Formats a keyboard shortcut for display | ||
| */ | ||
| export const formatShortcut = (shortcut: string): string => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unused function: The formatShortcut() function is defined but never used in the codebase. Either use it for consistent formatting or remove it to avoid dead code.
This PR adds a keyboard shortcut to toggle the global AutoApprove enabled/disabled setting.
Changes
✨ Features
Cmd+Option+A(Mac) /Ctrl+Alt+A(Windows/Linux) to toggle auto-approve🌐 Localization
📝 Implementation Details
roo-cline.toggleAutoApprovein package.json with keybindingsTesting
Screenshots
The keyboard shortcut is displayed in:
Users receive toast notifications when toggling via keyboard shortcut.
Requested via Slack mention.