Skip to content

Instantly share code, notes, and snippets.

@rastasheep
Forked from lucasfais/gist:1207002
Created September 14, 2012 19:51
Show Gist options
  • Save rastasheep/3724290 to your computer and use it in GitHub Desktop.
Save rastasheep/3724290 to your computer and use it in GitHub Desktop.
Sublime Text 2 - Useful Shortcuts (Linux/Windows)

General

  • Ctrl + P | go to anything
  • Ctrl + R | go to methods
  • Ctrl + G | go to line
  • Ctrl + UP / DOWN | scroll up and down
  • Ctrl + KB | toggle side bar
  • Ctrl + ⇧P | command prompt
  • Ctrl + ⇧N | new window (useful for new project)

Editing

  • Ctrl + ⇧D | duplicate current line
  • Ctrl + L | select line (repeat select next lines)
  • Ctrl + D | select word (repeat select others occurrences in context, multiple editing)
  • Ctrl + KD | skips the current selection and finds the next one (multiple editing)
  • Ctrl + ⇧M | select content into brackets
  • Ctrl + ⇧↩ | insert line before
  • Ctrl + ↩ | insert line after
  • Ctrl + X | delete line
  • Ctrl + KK | delete from cursor to end of line
  • Ctrl + K + ⌫ | delete from cursor to start of line
  • Ctrl + ⇧D | duplicate line(s)
  • Ctrl + J | join lines
  • Ctrl + ⇧UP / ⇧DOWN | move the current line up and down
  • Ctrl + KU | upper case
  • Ctrl + KL | lower case
  • Ctrl + / | comment
  • Ctrl + ⇧/ | block comment
  • Ctrl + Y | redo or repeat
  • Ctrl + ⇧V | past and indent
  • Ctrl + M | jump to matching brackets

XML/HTML

  • Ctrl + Alt + ↩ | zen coding* shell

Find / Replace

  • Ctrl + F | find
  • Ctrl + H | replace
  • Ctrl + ⇧F | find in files

Splits / Tabs

  • Alt + ⇧1 | single column
  • Alt + ⇧2 | two columns
  • Alt + [NUM] | select tab [NUM]
  • Ctrl + ⇧T | last closed tab
  • Ctrl + PgUp / PgDn | cycle through tabs

Bookmarks

  • Ctrl + F2 | toggle bookmark
  • F2 | next bookmark
  • ⇧F2 | previous bookmark
  • Ctrl + ⇧F2 | clear bookmarks

*must install zen coding via package manager

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment