This article covers how to install vim, followed by some basics on using vim and then uninstalling it. Vim (Vi IMproved) is a text editor that is upwards compatible to Vi. It can be used to edit all kinds of plain text. It is especially useful for editing config files and programs written in shell, python, perl, c/c++ and more. 

Among the various text editors in the world of Linux, Vim (or Vi IMproved) stands out for its versatility and for the functions it offers. In fact, Vim is able to speed up code writing, providing some shortcuts to perform all the operations of modification, deletion or replacement of the text. 

Vim Text Editor also allows you to install different plugins through which transforming this simple text editor into a real IDE for programming in different languages.

How to Install vim using apt on Linux ?

1. Open terminal application. You can also press CTRL+ALT+T keyboard shortcut.

2. Update package database by typing the sudo apt update command.

3. Search for vim packages run: sudo apt search vim.

4. Install vim on Ubuntu Linux, type: sudo apt install vim.

5. Verify vim installation by typing the vim --version command.

This article covers how to password protect a file using Vim on Linux.  When password protecting a file, make sure you remember it, or else you will not be able to access your file.

You can also use a password management software if you find it difficult to remember passwords. Or visit our guide on how to install Teampass password manager on Ubuntu .

Always remember to appropriately secure text files that could contain secret info such as usernames and passwords, financial account info and so on, using strong encryption and a password.

To install VIM in Linux:

Vim is available in the repositories of most major distributions. 

So, use your distribution package manager to get installed.

For Debian based systems, use apt-get or apt package manager to install vim.

$ sudo apt-get install vim

For RHEL/CentOS based systems, use yum package manager to install vim.

$ sudo yum install vim-enhanced

For Fedora system, use dnf package manager to install vim.

$ sudo dnf install vim-enhanced

For openSUSE system, use zypper package manager to install pass.

$ sudo zypper in vim

For Arch Linux based systems, use pacman package manager to install vim.

$ sudo pacman -S vim

This article will guide you on how to exit #vim text editor using various options. 1. Open a new or existing file with vim filename . 2. Type i to switch into insert mode so that you can start editing the file. 3. Enter or modify the text with your file. 4. Once you're done, press the escape key Esc to get out of insert mode and back to #command mode. 5. Type :wq to save and exit your file.

This tutorial will guide you on how to write a simple shell script and run a script in Linux operating system with help of chmod and other commands.

This article will guide you on how to show or hide line numbers in vim / vi text editors using commands.

More Linux Tutorials

We create Linux HowTos and Tutorials for Sys Admins. Visit us on IbmiMedia.com

Also for Tech related tips, Visit forum.outsourcepath.com or General Technical tips on www.outsourcepath.com