keyboard shortcut

Keyboard shortcuts for Sublime and VSCode

Knowing and applying the keyboard shortcuts is very useful and time-saving while coding/programming.

I have added some keyboard shortcuts that will help you while writing code in any editor.

Most of the shortcuts are common across most editors.

But you can modify them in most modern editors like sublime, VScode, atom, etc.

If you are using VScode you can install this extension that will change the default VScode shortcuts to sublime friendly shortcut.

I personally use the sublime shortcuts in VScode because it is familiar with sublime and easy to remember and also logical.

Keyboard Shortcuts to use:

Editing

Task / CommandShortcut
Cut lineCtrl + X
Insert line afterCtrl + ↩
Insert line beforeCtrl + ⇧ + ↩
Move line/selection upCtrl + ⇧ + ↑
Move line/selection downCtrl + ⇧ + ↓
Select line – Repeat to select next linesCtrl + L
Select word – Repeat select others occurrencesCtrl + D
Jump to opening parenthesesCtrl + M
Select all contents of the current parenthesesCtrl + ⇧ + M
Delete LineCtrl + ⇧ + K
Delete from cursor to end of lineCtrl + KK
Delete from cursor to start of lineCtrl + K + ⌫
Indent current line(s)Ctrl + ]
Un-indent current line(s)Ctrl + [
Duplicate line(s)Ctrl + ⇧ + D
Join line below to the end of the current lineCtrl + J
Comment/un-comment current lineCtrl + /
Block comment current selectionCtrl + ⇧ + /
Redo, or repeat last keyboard shortcut commandCtrl + Y
Paste and indent correctlyCtrl + ⇧ + V
Select next auto-complete suggestionCtrl + Space
s before undoing change when repeatedCtrl + U
Wrap Selection in html tagAlt + ⇧ + W
Close current html tagAlt + .
Hard wrap line to ruler column settingAlt + q
Column selection upCtrl + Alt + Up
Column selection downCtrl + Alt + Down

Navigation/Goto Anywhere

Task / CommandWin
Quick-open files by nameCtrl + P
Goto symbolCtrl + R
Goto word in current fileCtrl + ;
Goto line in current fileCtrl + G

General

Task / CommandWin
Command promptCtrl + ⇧ + P
Toggle side barCtrl + KB
Show scope in status barCtrl + ⇧ + Alt + P

Find and replace

Task / CommandWin
FindCtrl + F
ReplaceCtrl + H
Find in filesCtrl + ⇧ + F

Tabs

Task / CommandWin
Revert view to single columnAlt + ⇧ + 1
Split view into two columnsAlt + ⇧ + 2
Split view into three columnsAlt + ⇧ + 3
Split view into four columnsAlt + ⇧ + 4
Set view to grid (4 groups)Alt + ⇧ + 5
Split view into two rowsAlt + ⇧ + 8
Jump to group where num is 1-4Ctrl + [NUM]
Move file to specified group where num is 1-4Ctrl + ⇧ + [NUM]

Tabs

Task / CommandWin
Toggle bookmarkCtrl + F2
Next bookmarkF2
Previous bookmark⇧ + F2
Clear bookmarksCtrl + ⇧ + F2

Text Manipulation

Task / CommandWin
Transform to UppercaseCtrl + KU
Transform to LowercaseCtrl + KL

You can change the shortcuts as per your need.

Pressing CTRL+KS will open the keyboard shortcuts tab in VScode. Where you can manipulate those.

If you have any question, suggestion please comment below.

Leave a Reply

Your email address will not be published. Required fields are marked *