Menus and keyboard shortcuts
Every Py Editor menu command, its shortcut and what it does.
Standard macOS items — About, Settings… ⌘,, Hide, Quit, Undo, Redo, Cut, Copy, Paste, Select All, Minimize, Zoom and the window list — behave as they do in any Mac app and are not listed here. Commands act on the project window in front; most are dimmed when no project window or no file is selected.
Py Editor
| Item | Shortcut | What it does |
|---|---|---|
| Check for Updates… | — | Checks for a new version |
File
| Item | Shortcut | What it does |
|---|---|---|
| New File… | ⌘N | Asks for a name and creates the file in the project folder |
| New Folder… | — | Asks for a name and creates the folder in the project folder |
| Open Project… | ⌘O | Opens a folder as a project |
| Show Project Launcher | ⇧⌘L | Brings up the Welcome to Py Editor window |
| Recent Projects ▸ | — | Opens a project you used before |
| Close Tab | ⌘W | Closes the selected editor tab |
| Save | ⌘S | Saves the selected file |
| Save As… | ⇧⌘S | Saves a copy to a location you choose |
| Reload From Disk | — | Re-reads the selected file from disk |
| Rename File… | — | Renames the selected file |
| Project Settings… | ⌘; | Opens the Project Settings sheet |
| Prepare Project Environment | — | Creates or updates the project .venv. Needs Helper |
| Refresh Project Environment | — | Re-reads the state of the project environment |
Edit
| Item | Shortcut | What it does |
|---|---|---|
| Join Lines | ⌃⇧J | Joins the next line into the current one |
| Toggle Case | — | Switches the selection between upper and lower case |
| Extend Selection | — | Grows the selection to the enclosing syntax element |
| Shrink Selection | — | Reverses Extend Selection |
| Toggle Column Selection | — | Turns column selection on or off. ACE engine only |
| Find… | ⌘F | Searches the current file |
| Find Next | ⌘G | Moves to the next match |
| Find Previous | ⇧⌘G | Moves to the previous match |
| Replace… | ⌥⌘F | Replaces matches in the current file |
View
| Item | Shortcut | What it does |
|---|---|---|
| Tool Windows ▸ Search Workspace | ⇧⌘F | Opens the Find panel |
| Tool Windows ▸ Project Files | — | Opens the Project panel |
| Tool Windows ▸ Code Structure | — | Opens the Structure panel |
| Tool Windows ▸ Bookmarks | — | Opens the Bookmarks panel |
| Tool Windows ▸ HTML / Markdown Preview | — | Switches the tab to preview. Only for Markdown, HTML, SVG and notebook files |
| Tool Windows ▸ Run Output | — | Opens the Run surface |
| Tool Windows ▸ Tests | — | Opens the Tests surface |
| Tool Windows ▸ Coverage | — | Opens the Coverage surface |
| Tool Windows ▸ Diagnostics | — | Opens the Problems surface |
| Tool Windows ▸ Python Console | — | Opens the Python Console. Needs Helper |
| Tool Windows ▸ Terminal | — | Opens the Terminal. Needs Helper |
| Tool Windows ▸ AI Assistant | ⌥⌘A | Shows the AI Assistant column |
| Tool Windows ▸ Prepare Commit | — | Opens the Commit panel. Needs Helper |
| Tool Windows ▸ Packages | — | Opens the Packages surface. Needs Helper |
| Tool Windows ▸ Services | — | Opens the Services column. Needs Helper |
| Tool Windows ▸ Ollama | — | Opens the Ollama column |
| Tool Windows ▸ Git Log | — | Opens the Git log surface. Needs Helper |
| Tool Windows ▸ Learn | — | Opens the Learn panel |
| Toggle Sidebar | ⌃⌘S | Shows or hides the left panels |
Navigate
| Item | Shortcut | What it does |
|---|---|---|
| Go to File… | ⇧⌘O | Opens a file by name |
| Go to Symbol… | ⌥⌘O | Jumps to a symbol in the current file |
| Recent Files… | ⌘E | Reopens a file you edited recently |
| Back | ⌃⌘← | Returns to the previous location |
| Forward | ⌃⌘→ | Moves forward again |
| Go to Definition | — | Opens where the symbol under the cursor is defined |
| Find References | — | Lists the uses of the symbol under the cursor |
| Next Problem | F2 | Selects the next diagnostic |
| Previous Problem | ⇧F2 | Selects the previous diagnostic |
Code
| Item | Shortcut | What it does |
|---|---|---|
| Reformat Code | ⌥⌘L | Reformats the Python file |
| Optimize Imports | ⌃⌥O | Removes and reorders imports |
| Complete Symbol | ⌃Space | Requests a completion list |
| Add Selection for Next Occurrence | ⌃⌘D | Adds a cursor at the next match of the selection |
| Select All Occurrences | — | Adds a cursor at every match of the selection |
| Quick Documentation | — | Shows the documentation for the symbol under the cursor |
| Toggle Fold | — | Folds or unfolds the block at the cursor |
| Unfold All | — | Unfolds every block in the file |
| Toggle Line Comment | ⌘/ | Comments or uncomments the selected lines |
| Duplicate Line or Selection | ⌘D | Copies the line or selection below itself |
| Move Line Up | — | Moves the line up |
| Move Line Down | — | Moves the line down |
Refactor
| Item | Shortcut | What it does |
|---|---|---|
| Rename Symbol… | — | Renames the symbol under the cursor everywhere it is used |
| Extract Variable… | — | Asks for a name and replaces the selected expression with that variable |
| Extract Method… | — | Asks for a name and moves the selected statements into that method |
Run
Run “‹configuration›” and Debug “‹configuration›” carry the name of the active run configuration.
| Item | Shortcut | What it does |
|---|---|---|
| Run Current File | ⌃R | Runs the selected Python file |
| Debug Current File | ⌃D | Opens Debug and starts the debugger. Needs Helper |
| Run Current File with Coverage | — | Runs the file and reports line coverage |
| Profile Active Configuration | — | Profiles the run configuration. Needs Helper |
| Run File in Python Console | — | Runs the selected file inside the Python Console. Needs Helper |
| Run “‹configuration›” | ⌃⌥R | Runs the active run configuration |
| Debug “‹configuration›” | ⌃⌥D | Debugs the active run configuration. Needs Helper |
| Edit Configurations… | — | Opens the Run tab of Project Settings |
| Stop | ⌘F2 | Stops what is running |
| Show Run Panel | — | Opens the Run surface |
| Debugging Actions ▸ Step Over | F8 | Runs the current line and stops on the next one |
| Debugging Actions ▸ Step Into | F7 | Enters the call on the current line |
| Debugging Actions ▸ Step Out | ⇧F8 | Finishes the current function and stops after it |
| Debugging Actions ▸ Run to Cursor | ⌥F9 | Continues until the line with the cursor |
| Debugging Actions ▸ Resume Program | ⌃⌘R | Continues to the next breakpoint |
| Debugging Actions ▸ Evaluate Expression… | ⌥F8 | Evaluates an expression in the paused frame |
| Debugging Actions ▸ Restart Debugger | — | Starts the debug session again. Needs Helper |
| Toggle Breakpoint ▸ Toggle Line Breakpoint | — | Adds or removes a breakpoint on the cursor line |
| View Breakpoints… | ⇧⌘F8 | Lists the breakpoints in the Bookmarks panel |
| Tests ▸ Run Project Tests | — | Runs the project tests |
| Tests ▸ Open Tests | — | Opens the Tests surface |
| Show Coverage | ⌥⌘F6 | Opens the Coverage surface |
| Clear Run Output | — | Clears the output in the Run surface |
| Project Actions ▸ Compile Project | — | Byte-compiles the project |
| Project Actions ▸ Run Tests | — | Runs the project tests |
| Project Actions ▸ Ruff Check | — | Lints the project with Ruff |
| Project Actions ▸ Mypy Check | — | Type-checks the project with Mypy |
| Project Actions ▸ Analyze Project | — | Analyzes the project and fills the Problems surface |
The stepping commands are available only while the debugger is paused.
Git
Every Git command needs Helper. Branch, fetch, pull and merge need Helper 0.5.0 or later.
| Item | Shortcut | What it does |
|---|---|---|
| Commit… | ⌘K | Opens the Commit panel |
| Pull | ⌘T | Pulls from the remote |
| Pull with Rebase | — | Pulls and rebases your commits on top |
| Fetch | ⇧⌘T | Fetches from the remote without merging |
| Push… | ⇧⌘K | Pushes the current branch |
| Switch Branch ▸ | — | Checks out a local or remote branch |
| Merge Branch ▸ | — | Merges another branch into the current one |
| New Branch… | — | Creates a branch |
| Abort Merge / Abort Rebase | — | Cancels the conflicted merge or rebase |
| Refresh Git Status | — | Re-reads the working-tree state |
| Working Tree | — | Opens the Commit panel |
| Show Git Log | — | Opens the Git log surface |
| Clone… | — | Clones a repository into a folder you choose |
| Initialize Git Repository… | — | Creates a repository in the project folder |
Window
| Item | Shortcut | What it does |
|---|---|---|
| Show Next Tab | ⇧⌘] | Selects the next editor tab |
| Show Previous Tab | ⇧⌘[ | Selects the previous editor tab |
Help
| Item | Shortcut | What it does |
|---|---|---|
| Py Editor Help | ⌘? | Opens the online user manual in your browser |
| Send Product Feedback… | — | Opens the feedback window |
Shortcuts outside the menu bar
| Where | Shortcut | What it does |
|---|---|---|
| Editor tab bar | ⌃⌘1 | Editor only |
| Editor tab bar | ⌃⌘2 | Editor and preview |
| Editor tab bar | ⌃⌘3 | Preview only |
| Project launcher | ⌘K | Focuses the workspace search field |
| Project launcher | ⌘O | Open Project |
| AI Assistant composer | ⌘↩ | Sends the message |
| Any sheet | ↩ / Esc | Confirms / cancels |
Editor keys
| Key | What it does |
|---|---|
| F1 | Quick Documentation |
| F12 | Go to Definition. ACE engine only |
| ⌥F7 | Find References. ACE engine only |
| ⌘F8 | Toggle a breakpoint on the cursor line. ACE engine only |
| ⌥↑ / ⌥↓ | Extend / Shrink Selection |
| ⌃Space | Completion. Native engine only |
| ⇥ / ⇧⇥ | Indent / outdent the selection. Native engine only |
| ⌥-click | Adds a cursor. Esc or an arrow key clears the extra cursors. Native engine only |
⌃⌘D is used for Add Selection for Next Occurrence instead of the macOS Look Up shortcut, and ⌘E opens Recent Files… instead of the system find shortcut.