LazyVim ๐ค โ
โกPrerequisite โ
- Neovim >=ย 0.9.0ย (needs to be built withย LuaJIT), I use 0.10.0
- Git >=ย 2.19.0ย (for partial clones support)
- aย Nerd Font(v3.0 or greater)ย (optional, but needed to display some icons)
- LazyGitย (optional)
๐ Installation โ
- Make a back up of your current Neovim files:
# required
mv ~/.config/nvim{,.bak}
# optional but recommended
mv ~/.local/share/nvim{,.bak}
mv ~/.local/state/nvim{,.bak}
mv ~/.cache/nvim{,.bak}- Clone the starter or my customised lazyvim repository
git clone https://https://github.com/jaypancholi94/nvim-config ~/.config/nvimgit clone https://github.com/LazyVim/starter ~/.config/nvim::: 3. Remove theย .gitย folder, so you can add it to your own repo later
rm -rf ~/.config/nvim/.git- Start Neovim ๐
nvimTIP
It is recommended to runย :LazyHealthย after installation. This will load all plugins and check if everything is working correctly.
โ Configuration โ
The files under config will be automatically loaded at the appropriate time, so you don't need to require those files manually. For more information, seeย general settings. Configuration for LazyVim is endless. Here, is the structure for my LazyVim setup
~/.config/nvim
โโโ lua
โย ย โโโ config
โย ย โย ย โโโ autocmds.lua
โย ย โย ย โโโ keymaps.lua
โย ย โย ย โโโ lazy.lua
โย ย โย ย โโโ options.lua
โย ย โโโ plugins
โย ย โโโ colorscheme.lua
โย ย โโโ copilot.lua
โย ย โโโ example.txt # file in the LazyVim starter repo is kept as a reference and has been converted to `.txt` to prevent it from being loaded
โย ย โโโ lsp-config
โย ย โโโ lualine.lua
โย ย โโโ neo-tree.lua
โย ย โโโ neo-treesitter.lua
โย ย โโโ nvim-notify.lua
โย ย โโโ tailwind.lua
โโโ init.tomlDANGER
Do notย requireย autocmds,ย keymaps,ย lazyย orย optionsย underย lua/config/ย orย lazyvim.configย manually.ย LazyVimย will load those files automatically.
โ Plugins โ
To add plugins in LazyVim, create a file under nvim/lua/plugins/ named new-plugin.lua. Specify the repository name in this file. Further plugin customization should be available in the respective plugin's README file. Once the Lua file is added, it will be loaded automatically. More details for plugin here.
return {
`github/new-plugin`,
enable = false, -- Manually overwrite plugin
}