Created
July 10, 2012 12:36
-
-
Save narze/3083012 to your computer and use it in GitHub Desktop.
My Sublime Text 2 Key bindings (some macros and packages required)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[ | |
{ "keys": ["alt+;"], "command": "run_macro_file", "args": {"file": "Packages/User/Semicolon EOL.sublime-macro"} }, | |
{ "keys": ["alt+["], "command": "run_macro_file", "args": {"file": "Packages/User/{} EOL.sublime-macro"} }, | |
{ "keys": ["alt+,"], "command": "run_macro_file", "args": {"file": "Packages/User/Colon EOL.sublime-macro"} }, | |
{ "keys": ["alt+end"], "command": "move_to", "args": {"to": "bol", "extend": false} }, | |
{ "keys": ["ctrl+r"], "command": "show_overlay", "args": {"overlay": "goto", "text": "@"} }, | |
{ "keys": ["super+;"], "command": "show_overlay", "args": {"overlay": "goto", "text": "#"} }, | |
{ "keys": ["home"], "command": "move_to", "args": {"to": "bol", "extend": false} }, | |
{ "keys": ["end"], "command": "move_to", "args": {"to": "eol", "extend": false} }, | |
{ "keys": ["ctrl+home"], "command": "move_to", "args": {"to": "bof", "extend": false} }, | |
{ "keys": ["ctrl+end"], "command": "move_to", "args": {"to": "eof", "extend": false} }, | |
{ "keys": ["shift+home"], "command": "move_to", "args": {"to": "bol", "extend": true} }, | |
{ "keys": ["shift+end"], "command": "move_to", "args": {"to": "eol", "extend": true} }, | |
{ "keys": ["shift+ctrl+home"], "command": "move_to", "args": {"to": "bof", "extend": true} }, | |
{ "keys": ["shift+ctrl+end"], "command": "move_to", "args": {"to": "eof", "extend": true} }, | |
{ "keys": ["shift+f1"], "command": "show_panel", "args": {"panel": "console", "toggle": true} }, | |
{ "keys": ["super+;"], "command": "show_overlay", "args": {"overlay": "goto", "text": "#"} }, | |
{ "keys": ["super+shift+v"], "command": "paste" }, | |
{ "keys": ["super+v"], "command": "paste_and_indent" }, | |
{ "keys": ["ctrl+super+t"], "command": "run_existing_window_command", "args": {"id": "repl_shell","file": "config/Shell/Main.sublime-menu"} }, | |
{ "keys": ["j", "j"], "command": "exit_insert_mode", | |
"context": | |
[ | |
{ "key": "setting.command_mode", "operand": false }, | |
{ "key": "setting.is_widget", "operand": false } | |
] | |
}, | |
{ "keys": ["h", "h"], "command": "exit_insert_mode", | |
"context": | |
[ | |
{ "key": "setting.command_mode", "operand": false }, | |
{ "key": "setting.is_widget", "operand": false } | |
] | |
}, | |
{ "keys": ["k", "k"], "command": "exit_insert_mode", | |
"context": | |
[ | |
{ "key": "setting.command_mode", "operand": false }, | |
{ "key": "setting.is_widget", "operand": false } | |
] | |
}, | |
{ "keys": ["j", "k"], "command": "exit_insert_mode", | |
"context": | |
[ | |
{ "key": "setting.command_mode", "operand": false }, | |
{ "key": "setting.is_widget", "operand": false } | |
] | |
}, | |
{ "keys": ["k", "j"], "command": "exit_insert_mode", | |
"context": | |
[ | |
{ "key": "setting.command_mode", "operand": false }, | |
{ "key": "setting.is_widget", "operand": false } | |
] | |
}, | |
{ "keys": ["up"], "command": "noop", "context": | |
[ | |
{ "key": "panel_visible", "operator": "equal", "operand": false }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": false }, | |
{ "key": "overlay_visible", "operator": "equal", "operand": false } | |
] | |
}, | |
{ "keys": ["down"], "command": "noop", "context": | |
[ | |
{ "key": "panel_visible", "operator": "equal", "operand": false }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": false }, | |
{ "key": "overlay_visible", "operator": "equal", "operand": false } | |
] | |
}, | |
{ "keys": ["left"], "command": "noop", "context": | |
[ | |
{ "key": "panel_visible", "operator": "equal", "operand": false }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": false }, | |
{ "key": "overlay_visible", "operator": "equal", "operand": false } | |
] | |
}, | |
{ "keys": ["right"], "command": "noop", "context": | |
[ | |
{ "key": "panel_visible", "operator": "equal", "operand": false }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": false }, | |
{ "key": "overlay_visible", "operator": "equal", "operand": false } | |
] | |
}, | |
{ "keys": ["alt+k"], "command": "set_motion", | |
"args": { | |
"motion": "move", | |
"motion_args": {"by": "lines", "forward": false, "extend": false } | |
} | |
}, | |
{ "keys": ["alt+j"], "command": "set_motion", | |
"args": { | |
"motion": "move", | |
"motion_args": {"by": "lines", "forward": true, "extend": false } | |
} | |
}, | |
{ "keys": ["alt+h"], "command": "set_motion", | |
"args": { | |
"motion": "move", | |
"motion_args": {"by": "characters", "forward": false, "extend": false } | |
} | |
}, | |
{ "keys": ["alt+l"], "command": "set_motion", | |
"args": { | |
"motion": "move", | |
"motion_args": {"by": "characters", "forward": true, "extend": false } | |
} | |
}, | |
{ "keys": ["ctrl+["], "command": "previous_edit" }, | |
{ "keys": ["ctrl+]"], "command": "next_edit" }, | |
{ "keys": ["tab"], "command": "move", "args": {"by": "characters", "forward": true}, "context": | |
[ | |
{ "key": "following_text", "operator": "regex_contains", "operand": "^[)\"\\]]", "match_all": true }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": false } | |
] | |
}, | |
{ "keys": ["tab"], "command": "run_macro_file", "args": {"file": "Packages/AutoFileName/commit-and-trim.sublime-macro"}, | |
"context": | |
[ | |
{ "key": "setting.auto_complete_commit_on_tab" }, | |
{ "operand": true, "operator": "equal", "match_all": true, "key": "afn_commit-n-trim" }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": true } //Overrided AutoFileName | |
] | |
}, | |
{ "keys": ["enter"], "command": "run_macro_file", "args": {"file": "Packages/AutoFileName/commit-and-trim.sublime-macro"}, | |
"context": | |
[ | |
{ "key": "setting.auto_complete_commit_on_tab", "operator": "equal", "operand": false }, | |
{ "operand": true, "operator": "equal", "match_all": true, "key": "afn_commit-n-trim" }, | |
{ "key": "auto_complete_visible", "operator": "equal", "operand": true } //Overrided AutoFileName | |
] | |
}, | |
{ "keys": ["super+shift+r"], "command": "reindent" , "args": {"single_line": false} }, | |
{ "keys": ["ctrl+shift+a"], "command": "add_surround" }, | |
{ "keys": ["ctrl+shift+d"], "command": "delete_surround" }, | |
{ "keys": ["ctrl+shift+r"], "command": "replace_surround" }, | |
{ "keys": ["ctrl+w"], "command": "focus_side_bar" } | |
] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Warning : some commands require external packages or macros