DEV Community

Cover image for Use Caps Lock to trigger iTerm2 terminal
Dragoș Străinu
Dragoș Străinu

Posted on • Originally published at strdr4605.com

Use Caps Lock to trigger iTerm2 terminal

A long time ago someone showed me that it's possible to add a hotkey to iTerm2 to open the terminal window from anywhere in the system. Till these days I was using ` key as a hotkey. But when having to input ` in markdown or JS I had to use Option + ` which has specific behavior.

I decided to try Caps Lock for a while (as Caps Lock is one of the useless keys on the keyboard).

The issue is that iTerm2 does not recognize the Caps Lock press. So I have to remap in MacOS Caps Lock to Control key.

Go to System Preferences > Keyboard:

  1. Select Modifier Keys:

macos keyboard mod keys

  1. Set Caps Lock as Control key:

macos caps lock ctrl

  1. Go to iTerm, System Preferences > Profiles > Select profile > Keys > Configure Hotkey Window:
    iterm add hotkey

  2. Set Double-tap key as Control

iterm ctrl hotkey

Now when you double press Caps Lock (or Ctrl) the iTerm window will popup.

Top comments (0)