Tag Archives: vi

Turn Color off in VI

Browse to your user directory with the following command: cd ~ Create a .vimrc file with the following command: vi .vimrc Click i for insert mode. Type the following command below to disable syntax: syntax off Hold Shift and hit : then type wq to save and quit the file.

How do I make the vi editor display line number

How do I make the vi editor display or hide line numbers? To make vi display line numbers, you need to set the number flag. Press the Esc key if you are currently in insert or append mode. Press : (the colon). The cursor should reappear at the lower left corner of the screen next… Read More »

Removing ^M characters in VI

When porting a text file from Windows to UNIX you will quite often get a ^M on the end of every line. Apart from look bad and make it hard to read, if you text file happens to be a script, then this can also effect the way your script is run. To remove the… Read More »