Keyboard shortcuts

My list of useful shortcuts

Terminal shortcuts

  • Ctrl + Alt + _ – Undo
  • Ctrl + U – Delete to start of line
  • Ctrl + K – Delete to end of line
  • Alt + B – Move word back
  • Alt + F – Move word forward
  • Ctrl + A – Move to start of line
  • Ctrl + E – Move to end of line
  • Ctrl + L – Clear screen

Sublime shortcuts

  • Ctrl + Shift + L – Multiple selection
  • Ctrl + Alt + J – Format JSON (Pretty JSON plugin)
  • Ctrl + K, F – Format XML (Indent XML plugin)

PyCharm shortcuts

  • Alt + LMB, Alt + Shift + Insert – Multiple selection
  • Alt + Insert – Insert file, Folder etc
  • Ctrl + Shift + N – Open file by autocomplete
  • Ctrl + Alt + S – Settings
  • Shift + F6 – Rename

Vim shortcuts

  • G – Move to last line
  • 0 – Move to start of line
  • A – move to end of line and insert mode
  • gg – Go to file start (ctrl + home)
  • dG – Delete all to the end of file
  • yy – Copy line
  • p – Paste after current line
  • yy, p – Duplicate line
  • h,j,k,l – Move Left, Down, Up, Right
  • v – Select text. While selecting text, you can perform searches and other advanced movement.
  • V – Select text by lines
  • Ctrl + v – Select block
  • d – Cut / Delete
  • y – Copy (Yank)
  • p – Paste after cursor
  • P – Paste before the cursor
  • :%s/find_what/replace_to/g – find and replace all
  • :set paste – paste without autoindent, :set nopaste turn on autoindent
  • u – undo, Ctrl+r – redo
  • d$, D – delete to the end of line
  • :set number / :set nonumber – add / remove lines numbers
  • :tabedit somefile.txt – open new tab
  • gt / gT – move next / previous tab
  • 1gt, 2gt etc – move to tab 1, 2 etc
  • :tabfirst, :tablast, :tabn, :tabp – Move to tab first, last, next, previous
  • :tabs – list of tabs
  • $ vim -p file1 file2 – open multiple files in tabs
  • :tabclose – close current tab
  • :tabonly – close all tabs except of current
  • :mksession myproject.vim- save open tabs workspace in a session
  • :mks! – save workspace to file Session.vim
  • $ vim -S Session.vim – open workspace from session
  • :qa – quit all tabs
  • :wqa – save and quit all tabs
  • ~/.vimrc – vim defaults. e.g. add line ‘set number’ to have line numbers by default

Ubuntu shortcuts

  • Ctrl + Alt + T – Terminal
  • Win + 1,2,3.. – Toolbar program

Byobu

  • Alt + F6 – fix screen size. detach all other clients
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s