This setup is for neovim >= v0.5.0
paq-nvim - Neovim package manager written in Lua
nvim-tree.lua - A File Explorer written In Lua
feline.nvim - A minimal, stylish and customizable statusline for Neovim written in Lua
indentLine - Show indent lines
vista.vim - View and search LSP symbols, tags in Vim/NeoVim
nvim-web-devicons - A Lua fork of vim-devicons
nvim-treesitter - Nvim Treesitter configurations and abstraction layer
nvim-cmp - Auto completion plugin
nvim-lspconfig - A collection of common configurations for Neovim's built-in language server client
LuaSnip - Snippet Engine for Neovim written in Lua
nvim-autopairs - A super powerful autopairs for Neovim.
~/.config/nvim
├── after
├── init.lua
└── lua
├── keymaps.lua
├── plugins
│ ├── feline.lua
│ ├── nvim-autopairs.lua
│ ├── nvim-cmp.lua
│ ├── nvim-lspconfig.lua
│ ├── nvim-tree.lua
│ ├── nvim-treesitter.lua
│ ├── paq-nvim.lua
│ └── vista.lua
└── settings.lua
-
init.lua: Main configuration file (call
lua
modules, load plugins etc.) -
lua: Folder of
lua
modules, here reside all the Lua modules that needed. These modules are called frominit.lua
file (See below). For plugins settings I use the convention/lua/plugins/<plugin_name>.lua>
. See: https://github.com/nanotee/nvim-lua-guide#where-to-put-lua-files -
keymaps.lua: Keymaps configuration file, vim/neovim and plugins keymaps.
-
settings.lua: General Neovim settings and configuration
-
plugins/feline.lua: Statusline configuration file
-
plugins/nvim-autopairs: Autoclose brackets
-
plugins/nvim-cmp.lua: Autocompletion settings
-
plugins/nvim-lspconfig.lua: LSP configuration (language servers, keybinding)
-
plugins/nvim-tree.lua: File manager settings
-
plugin/nvim-treesitter: Treesitter interface configuration
-
plugins/paq-nvim.lua: Plugin manager settings
-
plugins/vista.lua: Tag viewer settings
Colorscheme: Neovim Monokai
Fonts: Cozette
Icons: nvim-web-devicons
-
Install neovim >= v0.5.0
-
Install npm (for download the packages of LSP language servers)
-
Download this repository with
git
and copy thenvim
folder
git clone https://github.com/brainfucksec/neovim-lua.git
cd neovim-lua/
cp -Rv nvim ~/.config/nvim/
-
Install Paq
-
Open
neovim
and run the command :PaqInstall to install the plugins
- Install LSP language servers with
npm
sudo npm install -g bash-language-server pyright vscode-langservers-extracted tsserver
-
Open a source file of one of the supported languages with
neovim
, in the Neovim cmd line run command :LspInfo for testing the LSP support
Bash - bashls
Python - pyright
C-C++ - clangd
HTML/CSS/JSON - vscode-html
JavaScript/TypeScript - tsserver
See: nvim-lspconfig #CONFIG.md
- Add Lua to LSP configuration
- Improve font icons
-
Lua in Y minutes - https://learnxinyminutes.com/docs/lua/
-
Lua Quick Guide - https://github.com/medwatt/Notes/blob/main/Lua/Lua_Quick_Guide.ipynb
-
Lua 5.4 Reference Manual - https://www.lua.org/manual/5.4/
-
This configuration is in development version. See:
Version
on init.lua file. -
As all my setups I try to follow the KISS principle, probably some concepts may not be valid for everyone, then feel free to take what you need but don't install anything without checking first!