Skip to content

Instantly share code, notes, and snippets.

@davidkuster
Last active August 29, 2015 13:56
Show Gist options
  • Save davidkuster/8852887 to your computer and use it in GitHub Desktop.
Save davidkuster/8852887 to your computer and use it in GitHub Desktop.
Sublime Text 2 - Key Bindings (Preferences -> Key Bindings - User)
[
{ "keys": ["ctrl+b"], "command": "toggle_side_bar" },
// shortcuts for home and end keys because of the 6 row lenovo keyboard layout
{ "keys": ["ctrl+,"], "command": "move_to", "args": {"to": "bol", "extend": false} },
{ "keys": ["ctrl+."], "command": "move_to", "args": {"to": "eol", "extend": false} },
// shift shortcuts to select text with home & end shortcuts
{ "keys": ["shift+ctrl+,"], "command": "move_to", "args": {"to": "bol", "extend": true} },
{ "keys": ["shift+ctrl+."], "command": "move_to", "args": {"to": "eol", "extend": true} },
// shortcuts for page up & page down keys because of the 6 row lenovo keyboard
{ "keys": ["ctrl+u"], "command": "move", "args": {"by": "pages", "forward": false} },
{ "keys": ["ctrl+m"], "command": "move", "args": {"by": "pages", "forward": true} },
// shortcuts for arrow keys
{ "keys": ["ctrl+i"], "command": "move", "args": {"by": "lines", "forward": false} },
{ "keys": ["ctrl+k"], "command": "move", "args": {"by": "lines", "forward": true} },
{ "keys": ["ctrl+j"], "command": "move", "args": {"by": "characters", "forward": false} },
{ "keys": ["ctrl+l"], "command": "move", "args": {"by": "characters", "forward": true} },
// shift shortcuts for arrow keys to select text while moving
{ "keys": ["shift+ctrl+i"], "command": "move", "args": {"by": "lines", "forward": false, "extend": true} },
{ "keys": ["shift+ctrl+k"], "command": "move", "args": {"by": "lines", "forward": true, "extend": true} },
{ "keys": ["shift+ctrl+j"], "command": "move", "args": {"by": "characters", "forward": false, "extend": true} },
{ "keys": ["shift+ctrl+l"], "command": "move", "args": {"by": "characters", "forward": true, "extend": true} },
// multi-line/cursor select
{ "keys": ["super+shift+i"], "command": "select_lines", "args": {"forward": false} },
{ "keys": ["super+shift+k"], "command": "select_lines", "args": {"forward": true} },
// update paste to auto-indent
{ "keys": ["ctrl+v"], "command": "paste_and_indent" },
// patch OSX - goto anything with ctrl+p
{ "keys": ["ctrl+p"], "command": "show_overlay", "args": {"overlay": "goto", "show_files": true} },
// patch OSX - redo
{ "keys": ["ctrl+y"], "command": "redo_or_repeat" },
// patch OSX - file open
{ "keys": ["ctrl+o"], "command": "prompt_open" },
// ctrl+h for find/replace
{ "keys": ["ctrl+h"], "command": "show_panel", "args": {"panel": "replace"} },
// fold/unfold
{ "keys": ["ctrl+["], "command": "fold" },
{ "keys": ["ctrl+]"], "command": "unfold" },
{ "keys": ["ctrl+-"], "command": "fold_by_level", "args": {"level": 2} },
{ "keys": ["ctrl+="], "command": "unfold_all" }
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment