Skip to main content

Overview

This Neovim configuration is built on LazyVim, a pre-configured Neovim setup that provides a solid foundation with sensible defaults and a plugin ecosystem.

LazyVim Base

LazyVim provides:
  • Modern plugin management via lazy.nvim
  • Pre-configured LSP, linting, and formatting
  • File explorer, fuzzy finder, and git integration
  • Catppuccin theme integration
  • Extensive keybindings
Refer to the LazyVim documentation for the full feature set and default keybindings.

Configuration Structure

~/.config/nvim/
├── init.lua                    # Entry point
├── lua/
│   ├── config/
│   │   ├── autocmds.lua       # Auto commands
│   │   ├── keymaps.lua        # Custom keymaps
│   │   ├── lazy.lua           # Lazy.nvim bootstrap
│   │   └── options.lua        # Vim options
│   └── plugins/
│       ├── catppuccin.lua     # Theme configuration
│       ├── core.lua           # Core plugin overrides
│       └── neo-tree.lua       # File explorer config
├── lazy-lock.json             # Plugin version lock
└── stylua.toml                # Lua formatter config

Entry Point

The configuration starts simple:
-- init.lua
require("config.lazy")
This bootstraps lazy.nvim and loads all configuration modules.

Custom Options

Minimal options override LazyVim defaults:
-- lua/config/options.lua
vim.g.root_spec = { "cwd" }
This sets the root directory detection to use the current working directory.

Custom Keymaps

File Explorer

vim.keymap.set("n", "<leader>e", "<cmd>Neotree<cr>", { desc = "Toggle Neo-tree" })
  • <leader>e - Toggle Neo-tree file explorer

File Finding

vim.keymap.set("n", "<leader> ", "<cmd>Telescope find_files<cr>", { desc = "Find Files" })
vim.keymap.set("n", "<leader>ff", "<cmd>Telescope find_files<cr>", { desc = "Find Files" })
  • <leader><space> - Find files with Telescope
  • <leader>ff - Find files (alternative)

Default Leader Key

LazyVim uses <space> as the leader key by default.

Plugin Configuration

Catppuccin Theme

The Catppuccin theme is configured with extensive integrations:
return {
  "catppuccin/nvim",
  lazy = true,
  name = "catppuccin",
  opts = {
    lsp_styles = {
      underlines = {
        errors = { "undercurl" },
        hints = { "undercurl" },
        warnings = { "undercurl" },
        information = { "undercurl" },
      },
    },
    integrations = {
      aerial = true,
      cmp = true,
      dashboard = true,
      flash = true,
      gitsigns = true,
      illuminate = true,
      indent_blankline = { enabled = true },
      lsp_trouble = true,
      mason = true,
      neotree = true,
      noice = true,
      telescope = true,
      treesitter_context = true,
      which_key = true,
      -- ... and more
    },
  },
}

Core Plugins

Colorscheme is set to Catppuccin:
return {
  {
    "LazyVim/LazyVim",
    opts = {
      colorscheme = "catppuccin",
    },
  },
}

Telescope Configuration

Telescope is configured to find hidden files:
{
  "nvim-telescope/telescope.nvim",
  opts = {
    defaults = {
      find_command = { "fd", "--type", "f", "--hidden", "--no-ignore" },
    },
    pickers = {
      find_files = {
        hidden = true,
      },
    },
  },
}

Essential LazyVim Keybindings

KeyDescription
<leader>eToggle file explorer
<leader><space>Find files
<leader>ffFind files (alt)
<leader>frRecent files
<leader>fgGrep in files
<leader>fbFind buffers

Installing Plugins

Add new plugins by creating files in lua/plugins/:
-- lua/plugins/example.lua
return {
  "github/user/plugin-name",
  opts = {
    -- plugin configuration
  },
}
Lazy.nvim will automatically load all files in the plugins directory.

Managing Plugins

  • :Lazy - Open plugin manager UI
  • :Lazy update - Update all plugins
  • :Lazy sync - Install/update/clean plugins
  • :Lazy clean - Remove unused plugins

LSP Management

LazyVim uses Mason for LSP server management:
  • :Mason - Open Mason UI
  • :MasonInstall <server> - Install LSP server
  • :LspInfo - Show LSP status

Code Formatting

Formatting is handled by conform.nvim (included in LazyVim):
  • <leader>cf - Format current buffer
  • Auto-formatting on save (configurable)

FAQ

Edit lua/plugins/core.lua:
opts = {
  colorscheme = "tokyonight",  -- or any installed theme
},
Create a plugin spec with enabled = false:
-- lua/plugins/disable.lua
return {
  { "plugin/name", enabled = false },
}
LazyVim defaults are documented at:
Use Mason to install:
:Mason
Search for your language server and press i to install. LazyVim will auto-configure most servers.
Add your keymaps to lua/config/keymaps.lua. They will override defaults:
vim.keymap.set("n", "<leader>e", "<cmd>YourCommand<cr>")

Stylua Configuration

Lua code formatting is configured via stylua.toml:
column_width = 120
indent_type = "Spaces"
indent_width = 2

Build docs developers (and LLMs) love