Skip to content

Instantly share code, notes, and snippets.

@chrisurf
Created December 10, 2021 14:25
Show Gist options
  • Save chrisurf/5b7b22e81d975d0ba8d7ffd0ad3d86a9 to your computer and use it in GitHub Desktop.
Save chrisurf/5b7b22e81d975d0ba8d7ffd0ad3d86a9 to your computer and use it in GitHub Desktop.
IntelliJ IDEA Keyboard shortcuts Mac

IntelliJ IDEA Keyboard shortcuts

Selection

Key Description
twice and hold it down the second time. Then use the arrow keys (UP or DOWN)
⌃ + G Select next occurrence of the current word or selection
⌃ + ⌘ + G Select all occurrences

Move

Key Description
⇧ + ⌘ + UP or DOWN moves lines or selection a line up or down.

Basic Editing I

Key Description
⌘ + Y + DEL ete line at caret
⌥ + BACKSPACE Delete to word start
⌘ + D Duplicate line or block
⌘ + ] Mov to code block END
⌘ + [ Move to code start
⇧ + ⌃ + J Join lines
TAB + Indent selection
⌥ + ⌘ + IAuto-indent lines

Basic Editing II

Key Description
⇧ + ⌘ + V Paste from history
⌘ + DOWN Scroll text one line DOWN
⌘ + UP Scroll text one line UP
⇧ + ⌥ + RIGHT Select to next word
⇧ + ⌥ + LEFT Select to previous word
⇧ + ⌘ + U
⇧ + ↵ Start new line
⌃ + ↵ Splie line
⇧ + TAB Unindent selection

Search

Key Description
⌘ + F Find
⌘ + R Replace
⌃ + L Search for next occurrence
⇧ + ⌃ + L Search for previous occurance
⌘ + F Incremental search
⇧ + ⌃ + F Find in path
⇧ + ⌃ + R Replace in path
⌥ + F7 Find usages
⇧ + ⌘ + F7 Highlight usages in file
⌥ + ⌘ + F7 Show usages

Advanced Editing I

Key Description
⌃ + / Comment/uncomment current line
⇧ + ⌃ + / Comment/uncomment block comment
⌘ + O Override base class methods in current class
⌃ + N Generate ...
⌃ + SPACE Basic code completion
⌥ + ⌃ + SPACE Class name code completion
⌥ + / Expand word
TAB + Next template variable
⇧ + TAB Previous template variable
⌥ + DEL delete to word END
⇧ + ⌘ + PAGEDOWN Select to page bottom
⇧ + ⌘ + PAGEUP Select to page top
⇧ + END Select to END of line
⇧ + HOME Select to beginning of line

Advanced Editing II

Key Description
⌘ + PAGEDOWN Go to page bottom
⌘ + PAGEUP Go to page top
END Move to END of line
HOME Move to beginning of line
⌃ + J Quick documentation
⌃ + J Show TAB + le data
⇧ + ⌥ + ⌘ + H Show the highlighting level pop-UP window
⇧ + ⌃ + Q Show current method or class declaration
⌘ + F1 Show an error or warning description at caret
⇧ + F1 Show external documentation
⌥ + ⌘ + T Surround with...
⇧ + ⌃ + SPACE SmartType code completion
⌥ + ⌘ + J Surround with live template...

Source Navigation I

Key Description
⌘ + G Navigate to line
⌥ + ⌘ + B Navigate to implementation of symbol under caret
⇧ + ⌃ + B Navigate to type declaration of symbol at caret
⌥ + ⌘ + HOME Navigate to related file
⌘ + [ Navigate to opening brace
⌘ + ] Navigate to closing brace
F2 Navigate to next highlighted error
⇧ + F2 Navigate to previous highlighted error

Source Navigation II

Key Description
⌘ + F12 File structure pop-UP
⌥ + F1 Select target
⌘ + E Show list of recently opened files
⌃ + H Browse hierarchy for selected class
⌥ + ⌃ + H Browse call hierarchy for selected method
⇧ + ⌘ + BACKSPACE Move through the most recent change points

Refactoring

Key Description
⇧ + F6 Rename refactoring
F6 Move refactoring
F5 Copy refactoring
⇧ + F5 Clone refactoring
⌘ + DEL Safe + DEL ete
⌥ + ⌘ + M Extract method
⌥ + ⌘ + V Introduce variable
⌥ + ⌘ + F Introduce field
⌥ + ⌘ + C Introduce constant
⌥ + ⌘ + P Introduce parameter

Running and Debugging I

Key Description
⌘ + F9 Make project
⇧ + ⌘ + F9 Compile
⇧ + ⌥ + F10 Choose configuration and run
⇧ + F10 Retrun without losing focus in editor
⇧ + F9 Debug
⇧ + ⌥ + F9 Choose configuration and debug
⇧ + ⌥ + F8 Force step over
⇧ + ⌥ + F7 Force step into
F9 Resume program
⌥ + F8 Evaluate expression
⌥ + ⌘ + F8 Quick evaluate expression

Running and Debugging II

Key Description
⇧ + F10 Run
⌘ + F10 Update
F8 Step over
F7 Step into
⇧ + F7 Smart step into
⇧ + F8 Step out
⌥ + ⌘ + F9 Run to cursor
⇧ + F2 Stop program
⌘ + F8 Toggle breakpoint
⇧ + ⌘ + F8 View breakpoints
⌥ + ⌘ + F6 Switch to another coverage suite\
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment