<C-w>s " Split window horizontal - new window is current buffer
<C-w>b " Split window vertical - new window is current buffer
:sp {file} " Split window horizontal - new window is {file}
:vsp {file} " Split window vertical - new window is {file}
Registers are used to store bits of text for reuse by inserting or playing as macros
There are 26 named registers (each letter of alphabet) in addition to special case registers
Commands that store text in registers
x " Delete char to default register
d " Delete to default register
s " Substitute to default register
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
url=https://www.gnu.org/licenses/gpl-3.0.txt | |
curl -s $url | vim - |
:shell " Start a shell - return to vim with exit
:!{cmd} " Execute command in shell
:read !{cmd} " Execute command in shell and read STDOUT into buffer
:[range]write !{cmd} " Execute command in shell with specific lines as STDIN
:[range]!{filter} " Run range of lines through external program
OlderNewer