Skip to content

Instantly share code, notes, and snippets.

@jepebe
Created January 9, 2024 14:39
Show Gist options
  • Select an option

  • Save jepebe/fb95374bcc897d845afaf6dbdf3f9317 to your computer and use it in GitHub Desktop.

Select an option

Save jepebe/fb95374bcc897d845afaf6dbdf3f9317 to your computer and use it in GitHub Desktop.
Custom PyCharm Shortcuts on MacOS

Overview

  • ⌘ Command
  • ⌥ Alt
  • ⇧ Shift
  • ⌃ Control
  • ↑ Up
  • ↓ Down
  • ← Left
  • → Right
  • ⌫ Backspace
  • ⌦ Delete
  • ⏎ Return
  • ⎋ Escape
  • ␣ Space
  • ⇥ Tab

Navigate

Shortcut Description
⌘ ⇧ [ Go to previous tab
⌘ ⇧ ] Go to next tab
⌃ ⇧ ↑ Go to previous method
⌃ ⇧ ↓ Go to next method
⌥ ⇥ Go to next splitter
⌥ ⇧ ⇥ Go to previous splitter
⌘ E ⭐️ Recent files
⌘ ⇧ E ⭐️ Recent locations
⌘ B Go to declaration
⌘ ⌥ B Go to implementation
⌘ F12 Go to file member

Editor

Shortcut Description
⌘ D Duplicate line
⌘ ⌫ Delete line
⌃ K Kill to end of line
⌃ W Kill to word start
⌥ D Kill to word end
⌘ C Copy selection
⌘ X Cut selection
⌘ V Paste selection
⌘ ⇧ V Paste from history
⌘ Z Undo
⌘ ⇧ Z Redo
⌘ / Comment line
⌃ ⇧ J Join lines
⌘ ⏎ Split line
⌥ ⌘ ⏎ Insert line above
⇧ ⏎ Insert line below
⌘ ⇧ U Toggle case
⌃ ⇧ , Reduce font size in editors
⌃ ⇧ . Increase font size in editors
⌘ ⇧ ↑ Move statement up
⌘ ⇧ ↓ Move statement down
⌥ ⇧ ↑ Move line up
⌥ ⇧ ↓ Move line down
⌃ ␣ Basic code completion
⌃ ⇧ ␣ Type-matching code completion

Refactor

Shortcut Description
⌘ ⌥ M Extract method
⌘ ⌥ V Extract variable
⌘ ⇧ L Reformat code
⌘ ⌥ N Inline variable
⇧ F6 Rename
⌘ F6 Change signature

Multi-Caret

Shortcut Description
⌥ ⇧ G Add carets to end of selected lines
⌃ G Add caret to next occurrence
⌃ ⇧ G Unselect previous occurrence
⌘ G Find next occurrence (unselect current)
⌃ ⌘ G Select all occurrences

Movement

Shortcut Description
⌃ A Move caret to line start
⌃ E Move caret to line end
⌃ P Move caret up one line
⌃ N Move caret down one line
⌃ F Move caret forward one character
⌃ B Move caret backward one character
⌥ F Move caret forward one word
⌥ B Move caret backward one word
⌃ M Go to matching bracket

Run and Debug

Shortcut Description
⌃ R Run
⌃ D Debug
⌘ F2 Stop

Search

Shortcut Description
⇧ ⇧ Search Everywhere
⌘ F Find in file
⌘ R Replace in file
⌘ ⇧ F Find in path
⌘ ⇧ R Replace in path
⌘ O Go to class
⌘ ⇧ O Go to file
⌘ ⌥ O Go to symbol
⌘ ⇧ A Go to action

Version Control

Shortcut Description
⌘ K Commit
⌘ ⇧ K Push
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment