Install and Configure VIM Text Editor on RHEL 8 / CentOS 8

Posted on 9 views

You just installed RHEL 8 and would like to use VIM Text Editor?. Choosing the right text/code editor for your daily tasks is crucial to ensure you deliver in time and keep up with the workload. In this blog post, we will look at how to Install and Configure VIM on RHEL 8 / CentOS 8.

VIM comes with an impressive set of features which can be extended using the plenty of plugins available for various Programming Languages. It is sad that the default RHEL 8 text editor is vi.

If you type vim in your terminal, you’ll get:

$ vim
-bash: /usr/bin/vim: No such file or directory

Install VIM Text Editor on RHEL 8 / CentOS 8  by running the command:

sudo yum -y install vim

The binary package will be installed to:

# which vim

If you now execute the vim command, you should get below output.


Configure vim with basic settings by creating a new file on ~/.vimrc with the contents below.

set nocompatible
set backup
set history=1000
set ignorecase
set smartcase
set hlsearch
set incsearch
set number
set showmatch
syntax on
highlight Comment ctermfg=LightCyan
set wrap

Save the file and then exit. You now have VIM Text Editor installed on your RHEL 8 / CentOS 8 server or Workstation.

If you’re new to VIM, read the Vim Cheat Sheet guide. For complex VIM configurations or VIM IDE, check:


Gravatar Image
A systems engineer with excellent skills in systems administration, cloud computing, systems deployment, virtualization, containers, and a certified ethical hacker.