Skip to content

Instantly share code, notes, and snippets.

@nelsonr
Last active December 19, 2016 16:05
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nelsonr/11004110 to your computer and use it in GitHub Desktop.
Save nelsonr/11004110 to your computer and use it in GitHub Desktop.
My Sublime Text keymap
[
// {"keys": ["ctrl+m"], "args": {"action": "matching_pair"}, "command": "run_emmet_action", "context": [{"key": "emmet_action_enabled.matching_pair"} ] },
// Show/Hde Elm Type panel
// { "keys": ["alt+i"], "command": "elm_show_type_panel", "context": [ { "key": "selector", "operator": "equal", "operand": "source.elm" } ] },
// { "keys": ["alt+i"], "command": "hide_panel", "context": [ { "key": "selector", "operator": "equal", "operand": "source.elm" } ] },
// Expand abbreviation
{
"keys": [
"super+e"
],
"args": {
"action": "expand_abbreviation"
},
"command": "run_emmet_action",
"context": [
{
"key": "emmet_action_enabled.expand_abbreviation"
}
]
},
// Expand selection to brackets
{ "keys": ["super+shift+m"], "command": "expand_selection", "args": {"to": "brackets"} },
// Bookmarks
{ "keys": ["alt+s"], "command": "next_bookmark" },
{ "keys": ["alt+shift+s"], "command": "toggle_bookmark" },
{ "keys": ["alt+shift+d"], "command": "clear_bookmarks" },
// Font size
{ "keys": ["ctrl+plus"], "command": "increase_font_size" },
{ "keys": ["ctrl+minus"], "command": "decrease_font_size" },
// Code folding/unfolding
{ "keys": ["super+-"], "command": "fold" },
{ "keys": ["super++"], "command": "unfold" },
// Delete to beginning of line
{ "keys": ["ctrl+u"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Delete to Hard BOL.sublime-macro"} },
// Show debug console
{ "keys": ["ctrl+'"], "command": "show_panel", "args": {"panel": "console", "toggle": true} },
// Indent and unindent
{ "keys": ["alt+."], "command": "indent" },
{ "keys": ["alt+,"], "command": "unindent" },
// Wrap selection with function call
{"keys": ["ctrl+8"], "command": "insert_snippet", "args": { "name": "Packages/User/Wrap function.sublime-snippet" } },
// Open Terminal window in the project root folder
{ "keys": ["alt+super+o"], "command": "open_terminal_project_folder" },
{ "keys": ["super+shift+o"], "command": "reveal_in_side_bar"},
// Reopen last file
{ "keys": ["super+shift+t"], "command": "reopen_last_file" },
// Insert line above
{ "keys": ["shift+enter"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Add Line Before.sublime-macro"} },
// Paste and indent
{ "keys": ["super+v"], "command": "paste_and_indent" },
// Paste without indent
{ "keys": ["super+shift+v"], "command": "paste" },
// Override close separator shortcut and replace it with expand region
{ "keys": ["alt+w"], "command": "expand_region" }, // depends on ExpandRegion package
// Move between views
{ "keys": ["ctrl+right"], "command": "next_view" },
{ "keys": ["ctrl+left"], "command": "prev_view" },
{ "keys": ["alt+shift+n"], "command": "move", "args": {"by": "words", "forward": false} },
{ "keys": ["alt+left"], "command": "move", "args": {"by": "subwords", "forward": false} },
{ "keys": ["alt+n"], "command": "move", "args": {"by": "word_ends", "forward": true} },
{ "keys": ["alt+right"], "command": "move", "args": {"by": "subword_ends", "forward": true} },
{ "keys": ["alt+shift+up"], "command": "select_lines", "args": {"forward": false} },
{ "keys": ["alt+shift+down"], "command": "select_lines", "args": {"forward": true} },
// End to end movement and selection
{ "keys": ["ctrl+a"], "command": "move_to", "args": {"to": "bol", "extend": false} },
{ "keys": ["ctrl+e"], "command": "move_to", "args": {"to": "eol", "extend": false} },
// Go to definition
{ "keys": ["super+t"], "command": "goto_definition" },
// Decrement value by 0.1
{"keys": ["alt+down"], "args": {"action": "decrement_number_by_01"}, "command": "run_emmet_action", "context": [{"key": "emmet_action_enabled.decrement_number_by_01"} ] },
// Jump back and forth
{ "keys": ["alt+minus"], "command": "jump_back" },
{ "keys": ["alt+shift+minus"], "command": "jump_forward" },
// Move lines
{ "keys": ["super+alt+up"], "command": "swap_line_up" },
{ "keys": ["super+alt+down"], "command": "swap_line_down" },
// Align Tab
{ "keys": ["alt+l"], "command": "align_tab" },
// Delete line
{ "keys": ["shift+delete"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Delete Line.sublime-macro"} },
// Select line
{ "keys": ["super+l"], "command": "run_macro_file", "args": {"file": "res://Packages/User/select_line.sublime-macro"} },
// Toggle sidebar
{ "keys": ["§"], "command": "toggle_side_bar" },
// Comment lines and block
{ "keys": ["super+\\"], "command": "toggle_comment", "args": { "block": false } },
{ "keys": ["super+shift+\\"], "command": "toggle_comment", "args": { "block": true } },
{ "keys": ["super+shift+r"], "command": "goto_symbol_in_project" },
// Find previous
{ "keys": ["shift+enter"], "command": "find_prev", "context":
[{"key": "panel", "operand": "find"}, {"key": "panel_has_focus"}]
},
// Groups
{ "keys": ["super+alt+2"], "command": "new_pane" },
{ "keys": ["super+shift+1"], "command": "focus_group", "args": { "group": 0 } },
{ "keys": ["super+shift+2"], "command": "focus_group", "args": { "group": 1 } },
{ "keys": ["super+shift+3"], "command": "focus_group", "args": { "group": 2 } },
{ "keys": ["super+shift+4"], "command": "focus_group", "args": { "group": 3 } },
{ "keys": ["super+shift+5"], "command": "focus_group", "args": { "group": 4 } },
{ "keys": ["super+shift+6"], "command": "focus_group", "args": { "group": 5 } },
{ "keys": ["super+shift+7"], "command": "focus_group", "args": { "group": 6 } },
{ "keys": ["super+shift+8"], "command": "focus_group", "args": { "group": 7 } },
{ "keys": ["super+shift+9"], "command": "focus_group", "args": { "group": 8 } },
// Find next result
{ "keys": ["alt+f"], "command": "find_next" },
// Find previous result
{ "keys": ["alt+shift+f"], "command": "find_prev" },
{
"keys": [
"super+g"
],
"command": "wrap_as_you_type",
"context": [
{
"operand": false,
"operator": "equal",
"match_all": true,
"key": "setting.is_widget"
},
{
"match_all": true,
"key": "emmet_action_enabled.wrap_as_you_type"
}
]
},
// Emmet, expand abbreviation
{
"keys": [
"alt+space"
],
"args": {
"action": "expand_abbreviation"
},
"command": "run_emmet_action",
"context": [
{
"key": "emmet_action_enabled.expand_abbreviation"
}
]
},
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment