Skip to content

Instantly share code, notes, and snippets.

@audreyfeldroy
Last active August 23, 2024 07:07
Show Gist options
  • Save audreyfeldroy/6f5b79f386d2423007c8a3f4ca0a933d to your computer and use it in GitHub Desktop.
Save audreyfeldroy/6f5b79f386d2423007c8a3f4ca0a933d to your computer and use it in GitHub Desktop.

Revisions

  1. audreyfeldroy revised this gist Aug 23, 2024. No changes.
  2. audreyfeldroy revised this gist Aug 22, 2024. 1 changed file with 70 additions and 2 deletions.
    72 changes: 70 additions & 2 deletions jupyter_nbclassic_shortcuts.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    #### Command Mode (press `Esc` to enable)Edit Shortcuts
    ## Command Mode (press `Esc` to enable)

    `F` : find and replace

    @@ -112,4 +112,72 @@

    `⇧␣` : scroll notebook up

    `` : scroll notebook down
    `` : scroll notebook down

    ## Edit Mode (press `Enter` to enable)

    `` : code completion or indent

    `⇧⇥` : tooltip

    `⌘]` : indent

    `⌘[` : dedent

    `⌘A` : select all

    `⌘Z` : undo

    `⌘/` : comment

    `⌘D` : delete whole line

    `⌘U` : undo selection

    `Insert` : toggle overwrite flag

    `⌘↑` : go to cell start

    `⌘↓` : go to cell end

    `⌥←` : go one word left

    `⌥→` : go one word right

    `⌥⌫` : delete word before

    `⌥⌦` : delete word after

    `⌘⇧Z` : redo

    `⌘⇧U` : redo selection

    `⌃K` : emacs-style line kill

    `⌘⌫` : delete line left of cursor

    `⌘⌦` : delete line right of cursor

    `⌃M` : enter command mode

    `Esc` : enter command mode

    `⌘⇧F` : open the command palette

    `⌘⇧P` : open the command palette

    `⇧↩` : run cell, select below

    `⌃↩` : run selected cells

    `⌘↩` : run selected cells

    `⌥↩` : run cell and insert below

    `⌃⇧Minus` : split cell at cursor(s)

    `⌘S` : Save and Checkpoint

    `` : move cursor down

    `` : move cursor up
  3. audreyfeldroy created this gist Aug 19, 2024.
    115 changes: 115 additions & 0 deletions jupyter_nbclassic_shortcuts.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,115 @@
    #### Command Mode (press `Esc` to enable)Edit Shortcuts

    `F` : find and replace

    `` : enter edit mode

    `⌘⇧F` : open the command palette

    `⌘⇧P` : open the command palette

    `P` : open the command palette

    `⇧↩` : run cell, select below

    `⌃↩` : run selected cells

    `⌘↩` : run selected cells

    `⌥↩` : run cell and insert below

    `` : Collapse the selected heading cell's section

    `⌃⇧←` : Collapse all heading cells' sections

    `` : Un-collapse (expand) the selected heading cell's section

    `⇧→` : Select all cells in the selected heading cell's section

    `⌃⇧→` : Un-collapse (expand) all heading cells' sections

    `⇧A` : Insert a heading cell above the selected cell

    `⇧B` : Insert a heading cell below the selected cell's section

    `Y` : change cell to code

    `M` : change cell to markdown

    `R` : change cell to raw

    `1` : change cell to heading 1

    `2` : change cell to heading 2

    `3` : change cell to heading 3

    `4` : change cell to heading 4

    `5` : change cell to heading 5

    `6` : change cell to heading 6

    `K` : select cell above

    `` : select cell above

    `` : select cell below

    `J` : select cell below

    `⇧K` : extend selected cells above

    `⇧↑` : extend selected cells above

    `⇧↓` : extend selected cells below

    `⇧J` : extend selected cells below

    `⌘A` : select all cells

    `A` : insert cell above

    `B` : insert cell below

    `X` : cut selected cells

    `C` : copy selected cells

    `⇧V` : paste cells above

    `V` : paste cells below

    `Z` : undo cell deletion

    `D`,`D` : delete selected cells

    `⇧M` : merge selected cells, or current cell with cell below if only one cell is selected

    `⌘S` : Save and Checkpoint

    `S` : Save and Checkpoint

    `L` : toggle line numbers

    `O` : toggle output of selected cells

    `⇧O` : toggle output scrolling of selected cells

    `H` : show keyboard shortcuts

    `I`,`I` : interrupt the kernel

    `0`,`0` : restart the kernel (with dialog)

    `⌘V` : Dialog for paste from system clipboard

    `Esc` : close the pager

    `Q` : close the pager

    `⇧L` : toggles line numbers in all cells, and persist the setting

    `⇧␣` : scroll notebook up

    `` : scroll notebook down