Change Your Default Settings in VIM with a .vimrc File

Introduction

In Linux, VIM is a built in text editor program. Users can customize VIM by creating a ~/.vimrc file in the user’s home directory. VIM will auto load these pre-set variables on startup. You’ll need to set the file permissions of the .vimrc file to rw-rw—-.

Sample .vimrc file

In my opinion, the two most useful commands are to set line numbers on the file and set color scheme to make files easier to read. Here is how you set them up in the .vimrc file.

Get a list of available color schemes

References

https://phoenixnap.com/kb/vim-color-schemes

https://thelinuxcode.com/vimrc_tutorial

Related Posts