Skip to content
TheChatArchiveThe Chat Archive
Mistralmistral-medium-2505· Mistral AIHugging Face LMArena Human Preference 140K

Is it possible to swith the iterm key binding to switch tabs with super and the vim…

From a Chatbot Arena battleThe same person sent this prompt to two anonymous models at once. Compare it with Claudeclaude-sonnet-4-20250514’s answer.
  1. User

    Is it possible to swith the iterm key binding to switch tabs with super and the vim motion keys?

  2. Mistral Assistant

    Yes! You can configure iTerm2 to switch tabs using the Super (⌘) key combined with Vim motion keys (like h, j, k, l) by defining custom key bindings in iTerm2's preferences.

    Steps to Set Up Super + Vim Motion Keys for Tab Switching:

    1. Open iTerm2 Preferences:

      • Press ⌘ + , or go to iTerm2 → Preferences.
    2. Navigate to Keys:

      • Go to the Keys tab under Profiles (or directly under Preferences if using an older version).
    3. Add New Key Bindings:

      • Click the + button to add a new key binding.
      • Configure the following bindings (adjust based on your preferred Vim motions):
      ActionKeyboard ShortcutKey Binding
      Go to Previous Tab⌘ + hSend Hex Codes: 0x1b 0x5b 0x44 (or use Select Previous Tab)
      Go to Next Tab⌘ + lSend Hex Codes: 0x1b 0x5b 0x43 (or use Select Next Tab)
      Go to Tab 1⌘ + 1Select Tab at Index: 0
      Go to Tab 2⌘ + 2Select Tab at Index: 1
      .........
      • For Vim-like motion keys (h, j, k, l), you can map them as follows:
        • ⌘ + h → Previous Tab (Select Previous Tab)
        • ⌘ + l → Next Tab (Select Next Tab)
        • ⌘ + j → Next Tab (if you prefer vertical motion)
        • ⌘ + k → Previous Tab (if you prefer vertical motion)
    4. Alternative: Use Hex Codes for Vim Motions:

      • If you want to send actual Vim key sequences (e.g., for terminal apps), you can use Hex Codes:
        • ⌘ + h → 0x1b 0x68 (Esc + h)
        • ⌘ + j → 0x1b 0x6a (Esc + j)
        • ⌘ + k → 0x1b 0x6b (Esc + k)
        • ⌘ + l → 0x1b 0x6c (Esc + l)
      • However, this may not directly switch tabs unless your shell or app supports it.
    5. Save & Test:

      • Save the changes and test the new key bindings in iTerm2.

    Notes:

    • If you're using tmux or another terminal multiplexer, you might need to configure key bindings there instead.
    • Some key combinations (like ⌘ + h) might conflict with macOS system shortcuts. You may need to disable them in System Preferences → Keyboard → Shortcuts.

    Would you like help with a specific setup (e.g., tmux integration or alternative key mappings)?

Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.