Skip to content

Neovim / NvChad🔗

Neovim is a fork of Vim with builtin support for Language Server Protocol (LSP) and Lua scripting.

For Neovim different advanced configurations exists: LazyVim, LunarVim, AstroNvim, NvChad, ... In the following NvChad is used as the bases for the custom configuration.

Install/Update🔗

Install (Linux):

$ rm -rf ~/.config/nvim
$ rm -rf ~/.local/share/nvim
$ git clone https://github.com/NvChad/NvChad ~/.config/nvim --depth 1

Install (Windows):

PS> rd -r ~\AppData\Local\nvim
PS> rd -r ~\AppData\Local\nvim-data
PS> git clone https://github.com/NvChad/NvChad $HOME\AppData\Local\nvim --depth 1

Update:

:NvChadUpdate

Key Mappings and Commands🔗

Note

In NvChad the leader key is Space.

  • change theme: <leader> + th
  • cheat sheet: <leader> + ch / :NvCheatsheet
  • dash screen: :Nvdash
  • file tree: :NvimTreeOpen / <leader> + e
  • searchable keymaps: :Telescope keymaps
  • list of LSP packages: :Mason
  • install all configured LSP packages: :MasonInstallAll
  • find files: <leader> + f f
  • recent files: <leader> + f o
  • find words (live grep): <leader> + f w
  • find bookmarks: <leader> + m a
  • floating terminal: Alt + i
  • horizontal terminal: Alt + h / <leader> + h
  • vertical terminal: Alt + v / <leader> + v
  • next buffer: Tab
  • previous buffer: Shift + Tab
  • new buffer: <leader> + b
  • close buffer: <leader> + x

Custom Config🔗

dreknix/tools-nvchad-config

~/.config/nvim/lua/custom/
├── init.lua
├── chadrc.lua
├── mappings.lua
├── plugins.lua
├── configs/
│   ├── lspconfig.lua
│   └── overrides.lua
├── after/
└── snippets/

Config Files🔗

Custom configuration files:

After Directory🔗

Specific settings for each file type can be found in after/ftplugin/<filetype>.lua.

Snippets🔗

NvChad uses the following plugins for snippets:

The predefined snippets are installed in ~/.local/share/nvim/lazy/friendly-snippets/snippets/. Custom snippets are loaded in init.lua.