Nearly all commands are in normal (not INSERT) mode.
This is a super handy feature. Basically you can press q then any key, to start recording a macro to it.
qo starts recording to register ‘o’,
q stops recording.
@o replays the recording
qydt,dt,xj0q start recording; delete to comma;delete to comma; delete one char; down a line; to the beginning; stop recording.
10.3.2.1,0 ms,N/A 10.3.2.2,Dead,N/S 10.3.2.3,Dead,N/S 10.3.2.4,Dead,N/S 10.3.2.5,0 ms,TestServerName 10.3.2.6,0 ms,N/A
Then I want to remove the N/A and N/S
:sort u Sorts by unique lines (super awesome!!!)
s = single line
%s all lines
g = global
Remove Empty Lines
:v/\S/d in’v’erse ‘g!’; match whitespace that is not a space; ’d’elete all matching
:g/^\s*$/d This should work too.
:%!column -t -s ','