Using shortcut keys
While getting inline suggestions from Amazon Q, you can use keyboard shortcuts for common actions you take, such as initiating Amazon Q or accepting a recommendation.
Choose the integrated development environment (IDE) where you are developing code to see keyboard shortcuts for your IDE.
- Visual Studio Code
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
Right arrow
Previous recommendation
Left arrow
Reject a recommendation
ESC, backspace, or keep typing and the recommendation will disappear as soon as there is a character mismatch.
Accept next word
Option + right arrow
To change keybindings in VS Code, see Key Bindings for Visual Studio Code
on the VS Code website. Note
The inline suggestions toolbar in VS Code is disabled by default. For more information, see Redesigned inline suggestions toolbar
on the VS Code website. - JetBrains
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
Right arrow
Previous recommendation
Left arrow
Reject a recommendation
ESC, backspace, or keep typing and the recommendation will disappear as soon as there is a character mismatch.
To change keybindings in IntelliJ, see IntelliJ IDEA keyboard shortcuts
on the JetBrains website. - Eclipse
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
MacOS: Option + ]
Windows: Alt + ]
Previous recommendation
MacOS: Option + [
Windows: Alt + [
Reject a recommendation
ESC, backspace, or keep typing and the recommendation will disappear as soon as there is a character mismatch.
To change keybindings in Eclipse, see Changing the key bindings
in the Eclipse documentation. - Toolkit for Visual Studio
-
Action Keyboard shortcut Manually initiate Amazon Q
AWSToolkit.CodeWhisperer.GetSuggestion
in the keybindingsWindows: Alt + C
Accept a recommendation
Tab
Next recommendation
Edit.NextSuggestion
in the keybindingsWindows: Alt + .
Previous recommendation
Edit.PreviousSuggestion
in the keybindingsWindows: Alt + ,
Reject a recommendation
ESC, backspace, or keep typing and the recommendation will disappear as soon as there is a character mismatch.
See also Microsoft's Visual Studio default keyboard shortcuts
. To change keybindings in Visual Studio, use Tools -> Options -> Keyboard.
- Amazon SageMaker AI
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
Down arrow
Previous recommendation
Up arrow
Reject a recommendation
ESC
- JupyterLab
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
Down arrow
Previous recommendation
Up arrow
Reject a recommendation
ESC
- AWS Glue Studio Notebook
-
Action Keyboard shortcut Manually initiate Amazon Q
MacOS: Option + C
Windows: Alt + C
Accept a recommendation
Tab
Next recommendation
Down arrow
Previous recommendation
Up arrow
Reject a recommendation
ESC
- AWS Lambda
-
Action Keyboard shortcut Manually fetch a code suggestion
MacOS: Option + C
Windows: Alt + C
Accept a suggestion
Tab
Reject a suggestion
ESC, Backspace, scroll in any direction, or keep typing and the recommendation automatically disappears.
To change the key bindings, use the following procedure.
While viewing a particular function, choose the gear icon to open the Preferences tab.
On the Preferences tab, select Keybindings.
In the keybindings search box, enter Amazon Q.
- AWS Cloud9
-
Action Keyboard shortcut Manually fetch a code suggestion
MacOS: Option + C
Windows: Alt + C
Accept a suggestion
Tab
Reject a suggestion
ESC, Backspace, scroll in any direction, or keep typing and the recommendation automatically disappears.
While viewing a particular environment, choose the gear icon to open the Preferences tab.
On the Preferences tab, select Keybindings.
In the keybindings search box, enter Amazon Q.
In the Keystroke column, double-click the space corresponding to the function you're interested in.
Enter the keys that you want to bind the function to.