Usefull Tips For Vi

Sometime, when you want to see a file with vi, by instance some log file, it occurs that lines are longer than your screen. So, if you don't do something, it's not really easy to read properly a line.
This happens to me often, so to not forget it always, I decide it to put it here. This is how, you can unwrap a line with vi.
When you are in vi, simply type this in command mode :

:set nowrap

Really better, to read whithout a line wrapped, isn't it ??

And of course, if you want the line to be wrapped to the next line again, simply type this :

:set wrap
Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License