Infosec Scribbles

April 11, 2013

Fixing broken Sublime Text hot keys

Once you start using Sublime Text, you will begin putting together a collection of plugins to simplify your life. The amount of keys on your keyboard is rather limited and Sublime is a key mapping heavy editor. Lots of comfy hot keys are used even by default. Every once in a while you will get a plugin that wants to use one of the keys that is already in use. At this point you will end up wondering why some of the default key mappings are broken and this article will hopefully help you to fix conflicting hot keys.

Step 1: find the broken plugin

Luckily Sublime provides some debugging features through the console. The one you need right now is command logging. Open the console by pressing Ctrl + \```` and enter sublime.log_commands(True)```

Debug output in Sublime console

Now go to a place in your document where you are expecting your hot key to work and press it. The key and the command triggered will be displayed in the console.

Step 2: fix the broken hot key

You should know which plugin is to blame from the console output. In the case above it is Code Intel plugin. Open the plugin key mappings by selecting PreferencesPackage SettingsPackage NameKey Bindings (Default). Comment out the line that causes problems as seen on the screenshot below.

Comment out the broken key mapping

You do not need to restart Sublime, the changes are applied the moment you save them. You will have to repeat this process every time the plugin updates. If you need the function that you have just disabled, add a new key mapping for it in Key Bindings (User).

whoami

I'm Georgi (Russian: Георгий). Although I do various software security things for work, I particularly enjoy reverse engineering and breaking native code on Android and embedded systems. Check out more about me.