Last Updated: February 25, 2016
·
2.925K
· benorudolf

Sublime 2 efficiency tips

Some useful keyboard commands that will make your life easier:

  1. Besides the OS shortcuts of ALT + arrow and CMD + arrow for moving between words and the beg. and end of the line respectively, Sublime offers to move between camelCase and underscore segments with CTRL + arrow
    Using CTRL + right arrow on fooBar or *foo
    bar* will select only foo in both cases.

  2. CTRL + CMD + arrow moves the current line up/down

  3. CMD + SHIFT + D duplicate current line

4a. CMD + D Select the current word. Pressing this command again will also select the next instance of the word and so forth. (this will create a separate cursors for each word)

4b. CMD + CTRL + G Select all the instances of the current word

4c. CMD + K + D Skip the current instance of the word and select the next

  1. Similar to Chrome, Sublime offers the reopening of a file you just closed (undo close tab) CMD+SHIFT+T (like Chrome).

  2. CMD + F Search the current file

  3. CTRL + G Go to line

  4. CMD + SHIFT + F Search the entire project

  5. CMD + P Search / Find a file in the project. Selecting the file will already give a full preview of it. Pressing ENTER or clicking will actually open it.

  6. Multiple cursors: Sublime offers multiple cursors. You may add a new cursor by CMD + click . Exit the multiple cursor state by pressing ESC.