neovim and plugins installation guide

NeoVim is a fantastic text editor very similar to Vim, the previous version. 
As the statements say, Neovim is much more performing and has much more speed than Vim, it is also more maintained, so if errors are obtained, they could be solved by sending feedback.

Let's see its installation, open your terminal window and proceed with:

$ sudo apt-get install neovim

You have also to install some plugins which are:

$ sudo apt-get install python-neovim 
$ sudo apt-get install python3-neovim

Here we are, after this installation you can open your neovim editor and try things.
Keep in mind that neovim works by adding commands which are recognized only when these are added after colon sign (:), for example:


The :checkhealth command runs a series of diagnostic tests to check the health of your Neovim installation. 
If it uncovers any problems, it usually offers suggestions on how to fix them, or where to go to learn more.

Now the real fun stuff starts! Let's go inside the ~/.config folder and create a new file called "nvim" where you will place all the plugins and initialize the files.

$ mkdir nvim

Keep in mind that if you want, instead of doing all by your own, you can clone my repository fromgithub inside ~/.config folder without creating the nvim folder and then follow the instructions i entered.

That being said, assuming you want to continue doing it all by yourself, enter inside /nvim folder and create a new file called "init.vim", here you can add the sources of the plugins you want to install.
You should know that when starting neovim it always gets a reference to what is inside init.vim, briefly all the code inside init.vim will run first.
Now it's time to download/install the vim-plug package, the only one responsible for allowing the installation of the plugins.
Inside you terminal, you have to paste this repository:

$ curl -fLo ~/.config/nvim/autoload/plug.vim --create-dirs

So at this point only missing these famous plugins! 
Let's try out the steps by creating a new folder "vim-plug" where inside will be stored a file called "plugins.vim".
Follow these commands:

$ mkdir vim-plug
$ cd vim-plug/
$ touch plugins.vim

Now you have to open this file with NeoVim editor:

$ nvim plugins.vim

" This is the skeleton of plugins.vim

" auto-install vim-plug
if empty(glob('~/.config/nvim/autoload/plug.vim'))
	silent !curl -fLo ~/.config/nvim/autoload/plug.vim --create-dirs
	"autocmd VimEnter * PlugInstall
	"autocmd VimEnter * PlugInstall | source $MYVIMRC

call plug#begin('~/.config/nvim/autoload/plugged')

    " Here you can plug all the plugins you want
    " Let's try to plug these packages
    " Better Syntax Support
    Plug 'sheerun/vim-polyglot'
    " File Explorer
	Plug 'scrooloose/NERDTree'
	" Auto pairs for '(' '[' '{'
	Plug 'jiangmiao/auto-pairs'
call plug#end()

Paste this file by typing p in NORMAL mode and then :wq to save and exit from this file.
If you want to get more documentation on how to manage files and some other things visit his official website.

Now it seems to be all right, but there is another thing to do before installing packages and this must be done within the init.vim file.
Follow this step:

$ nvim ~/.config/nvim/init.vim

Once you have opened this file, paste in this code and then type :wq.

source $HOME/.config/nvim/vim-plug/plugins.vim

Now you are finally able to install these plugins.
All you have to do is to type these commands:


After you have installed this plugins you won't see any graphical change except a better syntax highlighted, a menu where you can have an overview of folders and files (:NE + tab you can see all the options, select :NERDTreeToggle for open tree and select it again to close it) and the autopairs of all types of brackets.

editor nvim neovim vim installation commands