25

With the default settings, command + arrow_left switches to the tab on the left. How to change it so that it puts the cursor at the beginning of the line instead ?

Benjamin Crouzier
  • 5,818
  • 11
  • 33
  • 44

2 Answers2

40

Source:

  • Go to settings (⌘ Command+,)
  • Go to tab Keys
  • Under "Key Bindings"
  • Change entry ⌘ Command to Send Hex code: 0x01
  • Change entry ⌘ Command to Send Hex code: 0x05

Visual: Visual of iTerm 2 Settings

Roxiun
  • 103
  • 7
Benjamin Crouzier
  • 5,818
  • 11
  • 33
  • 44
10

I would say mapping keys manually, as shown in other answers, is an advanced setup. iterm2 already has preset for that.

  • Open Preferences

  • Click "Profile" tab

  • Select a profile in the list on the left (eg "Default")

  • Click "Keys" tab

  • Click "Key Mappings" tab (if it exists)

  • Click the "Presets" dropdown and select "Natural Text Editing"

After that, you can easily navigate in the console with the Command + Left/Right arrow.

Oleg Abrazhaev
  • 221
  • 2
  • 6