Vim, which stands for Vi IMproved, is a free, open-source and advanced command line text editor based on vi. Vim 8.0 was released on September 12, 2016. It’s the first major update since 2006.
Vim 8.0 New Features:
- Asynchronous I/O support, channels, JSON
- Partials, Lambdas and Closures
- New style testing
- Viminfo merged by timestamp
- GTK+ 3 support
- MS Windows DirectX support
How to Install Vim 8.0 on Linux
The easiest way to install Vim 8.0 is through its Github repository. First install Git on your Linux system.
sudo apt install git
sudo dnf install git
sudo yum install git
Arch Linux/Manjaro/Apricity OS
sudo pacman -S git
Then clone the Vim repository from Github
git clone https://github.com/vim/vim.git cd vim
Configure the build environment
Install ncurses development library.
sudo apt install ncurses-dev sudo yum install ncurses-devel
Compile the source code
sudo make install
Once it’s installed, you can check Vim version using the following command.
vim --version | head -n 1
vim --version command will output the Vim version number, its features, configuration files and the compilation, linking command used. The
head -n 1 command will only display the first line of the output.
You will also see the version number when you start Vim text editor in the terminal.
How to Use Vim Text Editor – the Basics
vim to start the text editor in the terminal.
To enter text, you need to let Vim enter
edit mode by pressing
i. You will see
-- INSERT --
at the bottom left corner indicating that Vim is in edit mode. To start a new line, press Enter.
When you finished editing and want to exit out of Vim editor, press the
ESC key to return to
command mode. Then enter :wq to save the file and quit.
w stands for write. q stands for quit. You can also give the file a name like below:
Vim will write your content to disk as demo.txt file and quit.
To view the details about Vim 8.0 new features, type
While vim is running.