go - How to make Sublime text build execute on numpad enter? -


i use gosublime inside sublime text golang development. pressing ctrl + b gives me build pane, need type command e.g., go run main.go , press enter. when want execute command using numpad enter doesn't work. how make work numpad enter too?

i checked default keymap in sublime text provides following key bindings build tool

    { "keys": ["f7"], "command": "build" },     { "keys": ["ctrl+b"], "command": "build" },     { "keys": ["ctrl+shift+b"], "command": "build", "args": {"select": true} },     { "keys": ["ctrl+break"], "command": "exec", "args": {"kill": true} }, 

thank you!

the suggestion can give try using numpad_enter both numlock on , off, , see if makes difference. i'm running os x , using standard wired apple keyboard numpad, , i'm running linux in virtual machine. when open console (ctrl`) , run command

sublime.log_input(true) 

then refocus file i'm working on, pressing return (the enter equivalent on main keyboard) yields

key evt: enter 

in console, whereas hitting enter on keypad yields

key evt: keypad_enter 

this behavior not change in os x or linux (i haven't tried in windows vm yet) regardless of how numlock set. if you're on windows or linux windows keyboard, may change, doubt it.


the reason sublime because numpad_enter , enter/return send different keycodes program. sublime looking keycode (the 1 sent enter) submit contents of popup menus , whatnot, , ignores code sent numpad_enter. unfortunately, because built-in behavior, there no setting or key binding can set override it.

the other possibility can think of use utility os reprogram numpad_enter send same keycode enter. i'm not terribly familiar it, windows i've heard autohotkey pretty useful utility, , far can tell free. can remap keys rather easily. you'll have google other utilities if you're on os x or linux.

good luck!


Comments

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

android - CoordinatorLayout, FAB and container layout conflict -