DEV Community

Cover image for πŸš€ My Neovim Configuration
Manpreet Singh
Manpreet Singh

Posted on

πŸš€ My Neovim Configuration

⭐ If you find this config helpful, please star the repository! It motivates me to keep improving and adding new features.

A modern, feature-rich Neovim configuration built with Lua and managed by lazy.nvim. Organized, fast, and beautiful - just the way it should be.


πŸ“Έ Screenshots

Dashboard

image

Coding Interface

image

File Explorer

image

Command Palette

image

✨ Features

  • 🎨 Beautiful UI - Catppuccin theme with optional transparency
  • 🎯 Centered Command Palette - Noice.nvim for beautiful cmdline with icons
  • πŸ“¦ Smart Plugin Management - lazy.nvim with organized structure
  • πŸ” Fuzzy Finding - Snacks picker for files, grep, buffers
  • 🌳 File Explorer - Snacks explorer (nvim-tree and oil.nvim also available)
  • πŸ’‘ Full LSP Support - Auto-completion, diagnostics, and formatting
  • 🎯 GitHub Copilot - AI-powered code completion
  • πŸ”„ Git Integration - LazyGit integration with diff support
  • πŸ“Š Smart Statusline - Shows git status, diagnostics, and "I use Arch btw"
  • πŸ§ͺ Testing - vim-test integration
  • πŸ“ Markdown & API Preview - Live preview for markdown and Swagger/OpenAPI
  • 🐳 Docker Management - LazyDocker integration
  • 🎭 Discord Presence - Show what you're coding with cord.nvim
  • 🎡 Now Playing - Dashboard shows current song via playerctl
  • 🎨 Code Folding - nvim-ufo for smart folding
  • ⚑ Fast Startup - Optimized lazy loading (~80ms with 26+ plugins)

πŸ“‹ Requirements

  • Neovim >= 0.9.0
  • Git
  • A Nerd Font (recommended: JetBrainsMono Nerd Font)
  • Node.js (for LSP servers and Copilot)
  • Ripgrep (for grep functionality)
  • LazyGit (optional, for git integration)
  • LazyDocker (optional, for docker management)
  • tmux (for splitting tabs)

πŸš€ Installation

Linux/macOS

# Backup your existing config (if any)
mv ~/.config/nvim ~/.config/nvim.backup

# Clone this repository
git clone https://github.com/MannuVilasara/nvim.git ~/.config/nvim

# Start Neovim
nvim
Enter fullscreen mode Exit fullscreen mode

Lazy.nvim will automatically install all plugins on first launch.

πŸ“¦ Plugins

Plugins are organized into categories for better maintainability. See STRUCTURE.md for the complete organization guide.

Core

  • lazy.nvim - Modern plugin manager
  • plenary.nvim - Lua utility functions

UI & Appearance (lua/plugins/ui/)

  • catppuccin - Beautiful color scheme with transparency support
  • lualine.nvim - Customizable statusline with git, diagnostics, and OS info
  • bufferline.nvim - Buffer/tab line with navigation shortcuts
  • noice.nvim - Enhanced cmdline with centered popup and icons
  • nvim-web-devicons - File icons everywhere
  • nvim-colorizer.lua - Live color preview
  • dressing.nvim - Better UI for input/select
  • fidget.nvim - LSP progress notifications
  • snacks.nvim - Dashboard with now playing and utilities

Editor (lua/plugins/editor/)

  • nvim-treesitter - Better syntax highlighting and code understanding
  • nvim-autopairs - Auto-close brackets and quotes
  • comment.nvim - Smart commenting (gcc, gbc)
  • which-key.nvim - Keybinding hints popup
  • nvim-ufo - Smart code folding with treesitter
  • nvim-tree.lua - File explorer sidebar
  • oil.nvim - Edit filesystem like a buffer

LSP & Completion (lua/plugins/lsp/)

  • nvim-lspconfig - Easy LSP server configurations
  • nvim-cmp - Powerful completion engine
  • cmp-nvim-lsp - LSP completion source
  • cmp-buffer - Buffer word completion
  • cmp-path - File path completion
  • LuaSnip - Snippet engine
  • cmp_luasnip - Snippet completion source
  • none-ls.nvim - Formatting and linting
  • conform.nvim - Fast code formatter

Tools (lua/plugins/tools/)

  • copilot.lua - GitHub Copilot integration
  • toggleterm.nvim - Terminal management
  • lazydocker.nvim - Docker TUI integration
  • vim-test - Test runner
  • cord.nvim - Discord Rich Presence
  • nvim-tmux-navigation - Seamless tmux/vim navigation
  • rails.nvim - Ruby on Rails utilities
  • markdown-preview.nvim - Live markdown preview
  • swagger-preview.nvim - Swagger/OpenAPI preview

⌨️ Key Bindings

General

  • <leader> is set to Space

Dashboard (Snacks)

  • f - Find File
  • n - New File
  • g - Find Text (Grep)
  • r - Recent Files
  • c - Open Config
  • L - Lazy Plugin Manager
  • q - Quit

Fuzzy Finding

  • <C-p> - Find Files
  • <leader><leader> - Recent Files
  • <leader>fb - Buffers
  • <leader>fg - Grep Files
  • <leader>p - Command Palette
  • <leader>fh - Help Pages
  • <leader>fc - Colorschemes
  • <leader>fk - Keymaps

File Explorer

  • <leader>ee - Toggle Explorer

Buffer Navigation

  • Tab - Next Buffer
  • Shift+Tab - Previous Buffer
  • <leader>bd - Delete Buffer
  • <leader>bb - Pick Buffer
  • <leader>b1-9 - Go to Buffer 1-9

Git

  • <leader>lg - LazyGit
  • <leader>gl - LazyGit Log (current file)

Scratch Buffer

  • <leader>sf - Toggle Scratch Buffer
  • <leader>S - Select Scratch Buffer

Code Folding (UFO)

  • zR - Open all folds
  • zM - Close all folds
  • za - Toggle fold under cursor
  • zj - Go to next fold
  • zk - Go to previous fold

Fidget Notifications (Demo)

  • <leader>na - Info notification
  • <leader>nb - Warning notification
  • <leader>nc - Notification with annotation
  • <leader>np - Progress spinner demo

🎨 Customization

Transparency Toggle

Edit lua/plugins/ui/catppuccin.lua and change:

local transparent = true -- Set to false to disable transparency
Enter fullscreen mode Exit fullscreen mode

Changing Theme Variant

In lua/plugins/ui/catppuccin.lua, change the colorscheme command:

vim.cmd.colorscheme("catppuccin-mocha")  -- mocha, macchiato, frappe, or latte
Enter fullscreen mode Exit fullscreen mode

Adding Plugins

Add new plugin files in the appropriate category:

  • UI plugins β†’ lua/plugins/ui/
  • Editor plugins β†’ lua/plugins/editor/
  • LSP plugins β†’ lua/plugins/lsp/
  • Tools β†’ lua/plugins/tools/

They will be automatically loaded by lazy.nvim.

Modifying Keybindings

  • Core options: lua/core/options.lua (or lua/vim-options.lua if not migrated)
  • Plugin-specific: Edit the individual plugin file

πŸ“ Project Structure

~/.config/nvim/
β”œβ”€β”€ init.lua                    # Entry point with lazy.nvim setup
β”œβ”€β”€ lazy-lock.json              # Plugin version lock file
β”œβ”€β”€ STRUCTURE.md                # Organization guide
β”œβ”€β”€ reorganize.sh               # Migration script
β”œβ”€β”€ README.md                   # This file
β”‚
β”œβ”€β”€ lua/
β”‚   β”œβ”€β”€ core/                   # Core configuration (optional, organized structure)
β”‚   β”‚   └── options.lua         # Vim options and settings
β”‚   β”‚
β”‚   β”œβ”€β”€ vim-options.lua         # Vim options (legacy, can be migrated to core/)
β”‚   β”œβ”€β”€ plugins.lua             # Lazy.nvim bootstrap
β”‚   β”‚
β”‚   └── plugins/                # Plugin configurations (organized by category)
β”‚       β”œβ”€β”€ ui/                 # UI & Appearance
β”‚       β”‚   β”œβ”€β”€ catppuccin.lua
β”‚       β”‚   β”œβ”€β”€ lualine.lua
β”‚       β”‚   β”œβ”€β”€ bufferline.lua
β”‚       β”‚   β”œβ”€β”€ noice.lua
β”‚       β”‚   β”œβ”€β”€ snacks.lua
β”‚       β”‚   β”œβ”€β”€ dressing.lua
β”‚       β”‚   β”œβ”€β”€ fidget.lua
β”‚       β”‚   └── nvim-colorizer.lua
β”‚       β”‚
β”‚       β”œβ”€β”€ editor/             # Editor enhancements
β”‚       β”‚   β”œβ”€β”€ treesitter.lua
β”‚       β”‚   β”œβ”€β”€ autopairs.lua
β”‚       β”‚   β”œβ”€β”€ comment.lua
β”‚       β”‚   β”œβ”€β”€ which-key.lua
β”‚       β”‚   β”œβ”€β”€ ufo.lua
β”‚       β”‚   β”œβ”€β”€ nvim-tree.lua
β”‚       β”‚   └── oil.lua
β”‚       β”‚
β”‚       β”œβ”€β”€ lsp/                # LSP & Completion
β”‚       β”‚   β”œβ”€β”€ lsp-config.lua
β”‚       β”‚   β”œβ”€β”€ completions.lua
β”‚       β”‚   β”œβ”€β”€ none-ls.lua
β”‚       β”‚   └── formatting.lua
β”‚       β”‚
β”‚       β”œβ”€β”€ git/                # Git tools (future)
β”‚       β”‚
β”‚       └── tools/              # Development tools
β”‚           β”œβ”€β”€ copilot.lua
β”‚           β”œβ”€β”€ toggleterm.lua
β”‚           β”œβ”€β”€ lazydocker.lua
β”‚           β”œβ”€β”€ vim-test.lua
β”‚           β”œβ”€β”€ cord.lua
β”‚           └── ...
Enter fullscreen mode Exit fullscreen mode

πŸ”§ Troubleshooting

Plugins not installing

# Inside Neovim
:Lazy sync
Enter fullscreen mode Exit fullscreen mode

LSP not working

# Inside Neovim
:LspInfo
:Mason
Enter fullscreen mode Exit fullscreen mode

Treesitter errors

# Inside Neovim
:TSUpdate
Enter fullscreen mode Exit fullscreen mode

πŸ’‘ Tips

  1. Health Check - Use :checkhealth to diagnose issues
  2. Plugin Manager - Run :Lazy to manage plugins
  3. LSP Servers - Use :Mason to install LSP servers, formatters, and linters
  4. Keybinding Help - Press <leader> and wait to see available keybindings (which-key)
  5. Transparency - Toggle in lua/plugins/ui/catppuccin.lua with one line
  6. Now Playing - Dashboard shows your current song via playerctl (Spotify, VLC, etc.)
  7. Command Palette - Press : for centered command palette with icons
  8. Code Folding - Use za to toggle folds, zR/zM to open/close all

πŸ™ Acknowledgments

Thanks to the Neovim community and all plugin authors for their amazing work!

Special thanks to:

  • folke - For lazy.nvim, noice.nvim, and snacks.nvim
  • catppuccin - For the beautiful theme
  • The entire Neovim community for making this possible

⭐ Support

If this configuration helped you or inspired your setup, please consider:

  • ⭐ Starring the repository - It really motivates me!
  • 🍴 Forking and customizing - Make it your own
  • πŸ› Reporting issues - Help improve it for everyone
  • πŸ’¬ Sharing feedback - Let me know what you think

Star the repo if you found it helpful! It means a lot to me! ⭐


Note: I use Arch btw 🐧

Top comments (0)