Sublime Forum

User specific Key Binding not working for Goto Line

#1

Hi

I’m trying to setup the user-specific keybinding for the Goto Line command.

In the user-specific file: /Users/indy/Library/Application Support/Sublime Text 2/Packages/User/Default (OSX).sublime-keymap

I’m adding this:

{ “keys”: “super+shift+g”], “command”: “goto_line” }

It does not work. I’ve tried other key combinations as well. None of them work.

If I change just the command to another command that is already registered, the new combination starts working for that command, but not for Goto Line.

For example, if I change the New Window shortcut

{ “keys”: “super+shift+g”], “command”: “new_window” }

It works… But if I change the command to “goto_line”, it is not respected.

Is goto_line the correct command?

Thanks

PS: I’ve even tried to setup Mac keyboard shortcut, which work for most applications on Mac. However, for Sublime Text editor specifying Mac keyboard shortcuts doesn’t seem to work.

0 Likes

#2

The command of interest is prompt_goto_line.

Can you give more details about the mac keyboard shortcut that didn’t work? In general the Cocoa key bindings are well supported.

0 Likes

#3

Thanks Jon for the quick reply. Much appreciated.

When I use “prompt_goto_line” it works! I was obviously using the wrong command: “goto_line”.

Is there a some place where I can see all the possible commands?

Indy

0 Likes

#4

Best option is to just look through the key binding files for the moment, documentation on the commands is still in progress

0 Likes