WDTUTORIALS

Cheatsheet - Sublime Text (Win, OS X, Linux)

Common Keyboard Shortcuts For Sublime Text (tested in Windows, OS X and Linux).

Emphasized shortcut is a custom shortcut (check implementation at the bottom).

System And Files

Windows OS X Linux
Windows OS X Linux
Open File Ctrl + O Command + O Ctrl + O
Save File Ctrl + S Command + S Ctrl + S
Close File File Ctrl + W Command + W Ctrl + W
Open Recently Closed File Ctrl + Shift + T Command + Shift + T Ctrl + Shift + T
Toggle Sidebar Ctrl + K B Command + K B Ctrl + K B
Switch Project Ctrl + Alt + P Command + Ctrl + P Ctrl + Alt + P
Font Size Ctrl + +/- Command + +/- Ctrl + +/-
Command Pallette Ctrl + Shift + P Command + Shift + P Ctrl + Shift + P
Toggle Console (custom) Ctrl + Alt + C Ctrl + ` Ctrl + Alt + C
Fullscreen F11 Command + Ctrl + F F11
Distraction Free Fullscreen Shift + F11 Command + Ctrl + Shift + F Shift + F11
Change Tab Alt + Number Command + Number Alt + Number
Navigate Through Tabs Ctrl + PageUp/Down Command + Alt + Left/Right Ctrl + PageUp/Down
Show Autocomplete Suggestions (custom) Ctrl + Space Ctrl + Space Ctrl + Space

Selections / Moving Around

Windows OS X Linux
Windows OS X Linux
Jump words / characters Ctrl + Left/Right Ctrl + Left/Right Ctrl + Left/Right
Moving around and selecting Ctrl + Shift + Left/Right Ctrl + Shift + Left/Right Ctrl + Shift + Left/Right
Add next occurence to selection Ctrl + D Command + D Ctrl + D
Add scope to selection Ctrl + Shift + Space Command +Shift + Space Ctrl + Shift + Space
Add all occurences to selection Alt + F3 Ctrl + Command + G Alt + F3
Select contents inside parenthesis Ctrl + Shift + M Ctrl + Shift + M Ctrl + Shift + M
Expand selection to indentation Ctrl + Shift + J Command + Shift + J Ctrl + Shift + J
Expand selection to Tag Ctrl + Shift + A Command + Shift + A Ctrl + Shift + A
Go to closing / opening parenthesis Ctrl + M Ctrl + M Ctrl + M
Back to single selection Escape Escape Escape
Scroll to selection Ctrl + K, Ctrl + C Command + K, Command + C Ctrl + K, Ctrl + C
Draw selection with mouse Middle Mouse Button Middle Mouse Button Right Mouse Button + Shift
Add to mouse selection Ctrl Command Ctrl
Subtract from mouse selection Alt Command + Shift Alt

Comments

Windows OS X Linux
Windows OS X Linux
Comment Line (custom) Ctrl + 7 Command + \ Ctrl + 7
Block Comment (custom) Ctrl + Shift + 7 Command + Shift + \ Ctrl + Shift + 7

Finding Things

Windows OS X Linux
Windows OS X Linux
Find Ctrl + F Command + F Ctrl + F
Find in files Ctrl + Shift + F Command + Shift + F Ctrl + Shift + F
Find and replace Ctrl + H Command + Alt + F Ctrl + H
Incremental search Ctrl + I Command + I Ctrl + I
Navigate through the search panel Tab Tab Tab
Close search Escape Escape Escape
Goto anything Ctrl + P Command + P Ctrl + P
Goto line number Ctrl + G Ctrl + G Ctrl + G
Goto symbol Ctrl + R Command + R Ctrl + R
Go to word Ctrl + P + write # Command + P + write # Ctrl + P + write #
Find next Enter (Or F3) Enter Enter (Or F3)
Find previous Shift + Enter (Or F3) Shift + Enter Shift + Enter (Or F3)
Find all Alt + F3 Ctrl + Command + G Alt + F3

Editing

Windows OS X Linux
Windows OS X Linux
Copy line / selection Ctrl + C Command + C Ctrl + C
Cut line / selection Ctrl + X Command + X Ctrl + X
Paste Ctrl + V Command + V Ctrl + V
Paste with indentation Ctrl + Shift + V Command + Shift + V Ctrl + Shift + V
Delete line Ctrl + Shift + K Ctrl + Shift + K Ctrl + Shift + K
Delete from cursor to end of line Ctrl + K K Command + K K Ctrl + K K
Delete from cursor to beginning of line Ctrl + K Backspace Command + K Backspace Ctrl + K Backspace
Duplicate line / selection Ctrl + Shift + D Command + Shift + D Ctrl + Shift + D
Select line Ctrl + L Command + L Ctrl + L
Move line up/down Ctrl + Shift + Up/Down Command + Ctrl + Up/Down Ctrl + Shift + Up/Down
Insert line after Ctrl + Enter Command + Enter Ctrl + Enter
Insert line before Ctrl + Shift + Enter Command + Shift + Return Ctrl + Shift + Enter
Join next line end of the current line Ctrl + J Command + J Ctrl + J
Transpose (swap place of characters/words) Ctrl + T Ctrl + T Ctrl + T
Uppercase Ctrl + K, Ctrl + U Command + K, Command + U Ctrl + K, Ctrl + U
Lowercase Ctrl + K, Ctrl + L Command + K, Command + L Ctrl + K, Ctrl + L
Indent line(s) (custom) Ctrl + 9 Command + ] Ctrl + 9
Unindent line(s) (custom) Ctrl + 8 Command + [ Ctrl + 8
Delete word forward Ctrl + Del Ctrl + Del Ctrl + Del
Delete word backwards Ctrl + Backspace Ctrl + Backspace Ctrl + Backspace
Close tag Alt + . Command + Alt + . Alt + .

Layout

Windows OS X Linux
Windows OS X Linux
Select Column Layouts Alt + Shift + (1-4) Command + Alt + (1-4) Alt + Shift + (1-4)
Select 4 Grid Layout Alt + Shift + 5 Command + Alt + 5 Alt + Shift + 5
Select Two Or Three Row Layouts Alt + Shift + (8,9) Command + Alt + Shift + (2,3) Alt + Shift + (8,9)
Move To Panel Ctrl + Number Ctrl + Number Ctrl + Number
Move File To Panel Ctrl + Shift + Number Ctrl + Shift + Number Ctrl + Shift + Number

Multiple Cursors

Windows OS X Linux
Windows OS X Linux
Split selection into lines Ctrl + Shift + L Command + Shift + L Ctrl + Shift + L
Add new cursor Ctrl + Alt + Up/Down Ctrl + Shift + Up/Down Alt + Shift + Up/Down
Single cursor Escape Escape Escape

Bookmarks

Windows OS X Linux
Windows OS X Linux
Add/remove bookmark Ctrl + F2 Command + F2 Ctrl + F2
Goto next bookmark F2 F2 F2
Goto previous bookmark Shift + F2 Shift + F2 Shift + F2
Select all bookmarks (custom code see below) Alt + F2 Alt + F5 Alt + F5
Clear bookmarks Ctrl + Shift + F2 Command + Shift + F2 Ctrl + Shift + F2

Marks

Windows OS X Linux
Windows OS X Linux
Set mark Ctrl + K Space Command + K Space (Conflicts with spotlight in OSX) Ctrl + K Space
Set new location Ctrl + K X Command + K X Ctrl + K X
Select to mark Ctrl + K A Command + K A Ctrl + K A
Delete to mark Ctrl + K W Command + K W Ctrl + K W
Delete mark Ctrl + K G Command + K G Ctrl + K G

Misc

Windows OS X Linux
Windows OS X Linux
Toggle Spellchecking F6 F6 F6
Sort lines F9 F5 F9

Custom shortcuts

Toggle console

{ "keys": ["ctrl+alt+c"], "command": "show_panel", "args": {"panel": "console", "toggle": true} }

Autocomplete suggestions (for linux)

     { "keys": ["ctrl+space"], "command": "auto_complete" },
     { "keys": ["ctrl+space"], "command": "replace_completion_with_auto_complete", "context":
          [
               { "key": "last_command", "operator": "equal", "operand": "insert_best_completion" },
               { "key": "auto_complete_visible", "operator": "equal", "operand": false },
               { "key": "setting.tab_completion", "operator": "equal", "operand": true }
          ]
     }

Indent line(s)

{ "keys": ["ctrl+8"], "command": "indent" }

Undent line(s)

{ "keys": ["ctrl+9"], "command": "unindent" }

Comment line

{ "keys": ["ctrl+7"], "command": "toggle_comment", "args": { "block": false } }

Comment block

{ "keys": ["ctrl+shift+7"], "command": "toggle_comment", "args": { "block": true } }

Select all bookmarks in (in OS X and Linux)

{ "keys": ["alt+f5"], "command": "select_all_bookmarks" }

Example user keymap file for Windows:

[    
    { "keys": ["ctrl+alt+c"], "command": "show_panel", "args": {"panel": "console", "toggle": true} },
    { "keys": ["ctrl+8"], "command": "indent" },
    { "keys": ["ctrl+9"], "command": "unindent" },
    { "keys": ["ctrl+7"], "command": "toggle_comment", "args": { "block": false } },
    { "keys": ["ctrl+shift+7"], "command": "toggle_comment", "args": { "block": true } }
]

Samuli Natri (Entrepreneur, WDTutorials.com founder) has been building websites since the late 90's. He attended Helsinki University Of Technology (Computer Science) and Helsinki University (Social Sciences).

Latest Tutorial CKEditor Tutorial With CodeSnippet Syntax Highlighting

Copyright @ 2018 WDTutorials.com. All rights reserved. Privacy policy.Terms Of Service.