Vim Read/Write files

Rating: 
+1
+223
-1
You voted '-1'.
Clone this Snippet

Read/Write files

:1,10 w outfile 	Saves lines 1 to 10 in outfile
:1,10 w >> outfile 	Appends lines 1 to 10 to outfile
:r infile 	Insert the content of infile
:23r infile 	Insert the content of infile under line 23
Category: 
Vim