read a file and insert it into the position below the cursor of the current file
:read /path/to/file
:re /path/to/file
:r /path/to/file
- insert into the beginning of the file
:0r /path/to/file
- insert into the end of the file
:$r /path/to/file
read the output of system command and insert into the position below the cursor of the current file
read a specific lines from a file and insert it into the position below the cursor of the current file
- read the line no.10 to 20 into current file
:r !sed -n 10,20p /path/to/file
No comments :
Post a Comment