Skip to content

Instantly share code, notes, and snippets.

@gregilo
Last active May 4, 2026 13:58
Show Gist options
  • Select an option

  • Save gregilo/a90433876570bc8f50fcd18b14b73b27 to your computer and use it in GitHub Desktop.

Select an option

Save gregilo/a90433876570bc8f50fcd18b14b73b27 to your computer and use it in GitHub Desktop.

Revisions

  1. gregilo revised this gist Apr 1, 2019. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,4 +1,4 @@
    These keybindings make working with iTerm2 on a Mac much easier! Credit to https://stackoverflow.com/a/22312856 (@sqren)
    These keybindings make working with iTerm2 on a Mac much easier! Credit to https://stackoverflow.com/a/22312856 ([@sqren](https://github.com/sqren))

    ### Move cursor one word left

  2. gregilo revised this gist Apr 1, 2019. 1 changed file with 2 additions and 0 deletions.
    2 changes: 2 additions & 0 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,3 +1,5 @@
    These keybindings make working with iTerm2 on a Mac much easier! Credit to https://stackoverflow.com/a/22312856 (@sqren)

    ### Move cursor one word left

    Keyboard Combination: `` + ``
  3. gregilo revised this gist Apr 1, 2019. 1 changed file with 14 additions and 14 deletions.
    28 changes: 14 additions & 14 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -18,32 +18,32 @@ Code: `0x01`

    ### Move cursor to end of line

    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x05`
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x05`

    ### Delete word

    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: `0x1b 0x08`
    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: `0x1b 0x08`

    ### Delete line

    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: `0x15`
    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: `0x15`

    ### Undo

    Keyboard Combination: `` + `z`
    Action: Send Hex Code
    Code: `0x1f`
    Keyboard Combination: `` + `z`
    Action: Send Hex Code
    Code: `0x1f`

    ---

    ### Don't forget to remove the previous bindings:

    Open the “Profiles” tab
    Click the sub-tab ”Keys”
    Open the “Profiles” tab
    Click the sub-tab ”Keys”
    Remove the mappings for key combinations `` + `` and `` + ``
  4. gregilo revised this gist Apr 1, 2019. 1 changed file with 8 additions and 8 deletions.
    16 changes: 8 additions & 8 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,20 +1,20 @@
    ### Move cursor one word left

    Keyboard Combination: `` + ``
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x1b 0x62` .
    Code: `0x1b 0x62`

    ### Move cursor one word right

    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x1b 0x66`
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x1b 0x66`

    ### Move cursor to beginning of line

    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x01`
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x01`

    ### Move cursor to end of line

  5. gregilo revised this gist Apr 1, 2019. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,7 @@
    ### Move cursor one word left

    Keyboard Combination: `` + `` .
    Action: Send Hex Code .
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x1b 0x62` .

    ### Move cursor one word right
  6. gregilo revised this gist Apr 1, 2019. 1 changed file with 3 additions and 3 deletions.
    6 changes: 3 additions & 3 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,8 +1,8 @@
    ### Move cursor one word left

    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: `0x1b 0x62`
    Keyboard Combination: `` + `` .
    Action: Send Hex Code .
    Code: `0x1b 0x62` .

    ### Move cursor one word right

  7. gregilo revised this gist Apr 1, 2019. 1 changed file with 17 additions and 15 deletions.
    32 changes: 17 additions & 15 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -1,47 +1,49 @@
    ### Move cursor one word left

    Keyboard Combination: +
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: 0x1b 0x62
    Code: `0x1b 0x62`

    ### Move cursor one word right

    Keyboard Combination: +
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: 0x1b 0x66
    Code: `0x1b 0x66`

    ### Move cursor to beginning of line

    Keyboard Combination: +
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: 0x01
    Code: `0x01`

    ### Move cursor to end of line

    Keyboard Combination: +
    Keyboard Combination: `` + ``
    Action: Send Hex Code
    Code: 0x05
    Code: `0x05`

    ### Delete word

    Keyboard Combination: + ←Delete
    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: 0x1b 0x08
    Code: `0x1b 0x08`

    ### Delete line

    Keyboard Combination: + ←Delete
    Keyboard Combination: `` + `←Delete`
    Action: Send Hex Code
    Code: 0x15
    Code: `0x15`

    ### Undo

    Keyboard Combination: + z
    Keyboard Combination: `` + `z`
    Action: Send Hex Code
    Code: 0x1f
    Code: `0x1f`

    ---

    ### Don't forget to remove the previous bindings:

    Open the “Profiles” tab
    Click the sub-tab ”Keys”
    Remove the mappings for key combinations + and +
    Remove the mappings for key combinations `` + `` and `` + ``
  8. gregilo created this gist Apr 1, 2019.
    47 changes: 47 additions & 0 deletions iterm2_mac_keybinds.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,47 @@
    ### Move cursor one word left

    Keyboard Combination: ⌥ + ←
    Action: Send Hex Code
    Code: 0x1b 0x62

    ### Move cursor one word right

    Keyboard Combination: ⌥ + →
    Action: Send Hex Code
    Code: 0x1b 0x66

    ### Move cursor to beginning of line

    Keyboard Combination: ⌘ + ←
    Action: Send Hex Code
    Code: 0x01

    ### Move cursor to end of line

    Keyboard Combination: ⌘ + →
    Action: Send Hex Code
    Code: 0x05

    ### Delete word

    Keyboard Combination: ⌥ + ←Delete
    Action: Send Hex Code
    Code: 0x1b 0x08

    ### Delete line

    Keyboard Combination: ⌘ + ←Delete
    Action: Send Hex Code
    Code: 0x15

    ### Undo

    Keyboard Combination: ⌘ + z
    Action: Send Hex Code
    Code: 0x1f
    ---
    ### Don't forget to remove the previous bindings:

    Open the “Profiles” tab
    Click the sub-tab ”Keys”
    Remove the mappings for key combinations ⌥ + ← and ⌥ + →