Skip to content
This repository has been archived by the owner on Oct 15, 2022. It is now read-only.

Commit

Permalink
Merge pull request #3242 from NaveenKarippai/cheatsheet/vim
Browse files Browse the repository at this point in the history
vim_cheat_sheet: Add ex-commands and registers section
  • Loading branch information
GuiltyDolphin authored Jun 14, 2016
2 parents e4cda65 + 883befe commit 477876d
Showing 1 changed file with 67 additions and 2 deletions.
69 changes: 67 additions & 2 deletions share/goodie/cheat_sheets/json/vim.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@
"Visual Commands",
"Working with Multiple Files",
"Tabs",
"Miscellaneous",
"Registers",
"Additional Ex Commands",
"Basic Configuration"
],
"sections": {
Expand Down Expand Up @@ -56,6 +57,43 @@
"val": "move to the previous tab",
"key": "[gT] / [:tabprev] / [:tabp]"
}],
"Registers": [{
"val": "view all current registers",
"key": "[:reg] / [:registers]"
}, {
"val": "access register `r` as a variable",
"key": "echo @r"
}, {
"val": "last search pattern register",
"key": "\"/"
}, {
"val": "the black hole register",
"key": "\"_"
}, {
"val": "last yank register",
"key": "\"0"
}, {
"val": "last big delete register",
"key": "\"1"
}, {
"val": "big delete register stack",
"key": "\"2-\"9"
}, {
"val": "system clipboard",
"key": "\"+"
}, {
"val": "small delete register",
"key": "\"-"
}, {
"val": "named registers",
"key": "\"a-\"z"
}, {
"val": "append registers",
"key": "\"A-\"Z"
}, {
"val": "record into register `r`",
"key": "qr"
}],
"Editing": [{
"val": "replace a single character",
"key": "r"
Expand Down Expand Up @@ -429,7 +467,34 @@
"val": "replace all old with new throughout file with confirmations",
"key": ":%s/old/new/gc"
}],
"Miscellaneous": [{
"Additional Ex Commands": [{
"val": "run a compiler and enter quickfix mode",
"key": "[:mak] / [:make]"
}, {
"val": "execute external shell command",
"key": ":!"
}, {
"val": "read external program output into current file",
"key": "[:r] / [:read]"
}, {
"val": "move lines x through y to z (delete + put)",
"key": ":x,ymz"
}, {
"val": "yank lines x through y and put to z (yank + put)",
"key": ":x,ytz"
}, {
"val": "current line (cursor location)",
"key": ":."
}, {
"val": "last line (bottom of file)",
"key": ":$"
}, {
"val": "first line (top of file)",
"key": ":0"
}, {
"val": "list all open files",
"key": ":ls"
},{
"val": "create html representation of current working buffer",
"key": ":%TOhtml"
}],
Expand Down

0 comments on commit 477876d

Please sign in to comment.