This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| snippets:vim:shortcuts [2015/02/14 14:41] – created allspark | snippets:vim:shortcuts [2018/05/29 14:55] (current) – allspark | ||
|---|---|---|---|
| Line 14: | Line 14: | ||
| * :tabp | * :tabp | ||
| + | # split | ||
| + | |||
| + | ``` | ||
| + | :e filename | ||
| + | : | ||
| + | | ||
| + | | ||
| + | | ||
| + | | ||
| + | 10 ctrl-w+ | ||
| + | : | ||
| + | : | ||
| + | : | ||
| + | : | ||
| + | : | ||
| + | :b 2 - open buffer #2 in this window | ||
| + | ``` | ||
| + | |||
| + | ## resize | ||
| + | |||
| + | ``` | ||
| + | :resize 60 | ||
| + | :res +5 | ||
| + | :res -5 | ||
| + | :vertical resize 80 | ||
| + | :vertical resize +5 | ||
| + | :vertical resize -5 | ||
| + | ``` | ||
| + | |||
| + | # editing | ||
| + | |||
| + | * dgg delete to beginning of file | ||
| + | * dG delete to end of file | ||
| + | |||
| + | ## insert | ||
| + | |||
| + | ``` | ||
| + | To do this, move to the a in the first line, then press Ctrl-V (or Ctrl-Q if you use Ctrl-V for paste), then jj to select a visual block over three lines. | ||
| + | |||
| + | Now type I to start a special form of insert mode, then type the wanted text (s:). When you press Esc to exit from insert mode, the text will be inserted in the same position on each of the lines affected by the visual block selection. | ||
| + | ``` | ||