Vi commands: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
Line 6: | Line 6: | ||
<pre>:s/OLD/NEW/g</pre> | <pre>:s/OLD/NEW/g</pre> | ||
====Replace All (Globally)==== | ====Replace All (Globally)==== | ||
<pre>: | <pre>:s/OLD/NEW/g</pre> | ||
== Display Command == | == Display Command == |
Latest revision as of 20:09, 11 December 2016
Manipulation
Search and Replace
First One on the line
:s/OLD/NEW
All occurences of the line
:s/OLD/NEW/g
Replace All (Globally)
:s/OLD/NEW/g
Display Command
Display line Number
Press :
set number or set nonumber