This tutorial follows Neovim 0.9.5, and most of the plugins won't work for versions lesser than 0.8. It is recomended to download the latest version.
Full official instalation instructions here.
You can download Neovim from your package manager, but make sure the version is the latest one, or at least
If it's not, it is recomended to build from source.
Note: At the time of writing APT's Neovim version is 0.7.2, so it's not recomended to download it this way.
sudo apt install neovim
sudo dnf install neovim
sudo pacman -S neovim
Full official instructions here
First install the requirements (platform-specific requirements here).
The main requirements are:
- Git
- Clang / GCC 4.9+
- CMake 3.13+
- Ninja-build
Then download Neovim from source and move to the stable
tag:
git clone https://github.com/neovim/neovim
cd neovim && git checkout stable
Finally install (installs to /usr/local/
):
make CMAKE_BUILD_TYPE=RelWithDebInfo
sudo make install
If you're in Debian/Ubuntu, it's preferable to run cd build && cpack -G DEB && sudo dpkg -i nvim-linux64.deb
instead of the make install
.
If it doesn't come with Neovim (you can check with the lua -v
comand), install Lua (oficial instrucions here).
According to Neovim's official webpage, Lua 5.1 is the minimum required version.
You can also install it through your package manager.
For APT, you have to specify the version, e.g.: sudo apt install lua5.4
.
Let's start by creating the basic configuration folder structure in ~/.config/nvim/
:
mkdir -p ~/.config/nvim/lua
cd ~/.config/nvim
touch init.lua
You can launch it as such:
nvim