This is a complete modern Neovim configuration built for maximum productivity with Python development in mind. The old configuration files have been backed up with .bak
extensions.
This configuration leverages all the latest Neovim v0.11.1 features and the modern plugin ecosystem:
- Uses the new
vim.lsp.config()
API where appropriate - Comprehensive LSP setup with Mason for automatic tool management
- Enhanced diagnostic configuration with virtual text enabled
- Pyright for comprehensive type checking
- Ruff LSP for fast linting and formatting
- conform.nvim for reliable code formatting
- nvim-lint with mypy integration
- Virtual environment selection with venv-selector
- REPL integration with Iron.nvim
- Debugging with nvim-dap and dap-python
- noice.nvim - Complete UI overhaul for messages and popups
- tiny-inline-diagnostic.nvim - Modern inline diagnostic display
- codecompanion.nvim - Multi-model AI chat integration
- oil.nvim - Modern file explorer
- trouble.nvim v3 - Enhanced diagnostic management
- Lazy.nvim plugin manager with fast startup
- Lualine with modern statusline
- Bufferline with LSP diagnostics integration
- Dashboard with custom ASCII art
- Multiple colorschemes with easy switching
- Which-key for keybinding discovery
~/.config/nvim/
βββ init.lua # Main entry point with lazy.nvim bootstrap
βββ lua/
β βββ config/ # Core configuration
β β βββ autocmds.lua # Autocommands for enhanced functionality
β β βββ keymaps.lua # Comprehensive keybinding setup
β β βββ options.lua # Modern Neovim options
β βββ plugins/ # Plugin configurations
β βββ colorscheme.lua # Multiple colorscheme options
β βββ completion.lua # nvim-cmp + Copilot integration
β βββ debug.lua # DAP debugging configuration
β βββ editor.lua # Core editor functionality
β βββ lsp.lua # LSP configuration
β βββ python.lua # Python-specific tooling
β βββ ui.lua # UI enhancements
β βββ utils.lua # Utility and productivity plugins
βββ *.bak # Backup of original configuration
- Real-time linting with Ruff and mypy
- Automatic formatting on save with Ruff
- Type checking with Pyright
- Virtual environment management
- Debugging with full DAP integration
- Testing with neotest framework
- REPL integration for interactive development
- Fuzzy finding with Telescope
- File management with Oil.nvim
- Git integration with Gitsigns and Fugitive
- Project management with project.nvim
- Session persistence across restarts
- Terminal integration with ToggleTerm
- GitHub Copilot with nvim-cmp integration
- CopilotChat for AI-powered code assistance
- CodeCompanion for multi-model AI interactions
- Trouble.nvim for diagnostic management
- Tiny-inline-diagnostic for modern error display
- Native LSP diagnostics with enhanced configuration
- Jump between errors with
]d
and[d
- Quickfix integration for batch error handling
<leader>f
- Open Oil file explorer<C-p>
- Find files (Telescope)<C-g>
- Live grep (Telescope)<leader>fr
- Recent files
gd
- Go to definitiongr
- Go to referencesK
- Hover documentation<leader>ca
- Code actions<leader>r
- Rename symbol
]d
/[d
- Next/previous diagnostic<leader>xx
- Toggle Trouble diagnostics<leader>e
- Show line diagnostic<leader>q
- Open diagnostic loclist
<leader>f
- Format code (Ruff)<leader>ll
- Trigger linting<leader>vs
- Select virtual environment<leader>rs
- Toggle Python REPL
<leader>gs
- Git status<leader>gc
- Git commit<leader>hs
- Stage hunk<leader>hp
- Preview hunk
<Tab>
- Accept completion/next item<M-l>
- Accept Copilot suggestion<leader>cc
- Toggle CopilotChat<leader>a
- CodeCompanion actions
<leader>z
- Zen mode<leader>tw
- Twilight (focus mode)J
/K
- Previous/next buffer<C-\>
- Toggle floating terminal
Multiple modern colorschemes are included with easy switching:
<leader>uct
- Tokyo Night<leader>ucc
- Catppuccin<leader>ucr
- Rose Pine<leader>uck
- Kanagawa<leader>ucg
- GitHub Dark<leader>uco
- OneDark<leader>ucf
- FadedWolf (your original)
The configuration provides comprehensive Python error detection and navigation:
- Ruff LSP - Fast Python linting with auto-fixes
- Pyright - Advanced type checking and analysis
- mypy - Static type checking via nvim-lint
- Built-in LSP diagnostics - Real-time error reporting
- Real-time feedback - Errors appear as you type
- Visual indicators - Signs in the gutter, virtual text inline
- Quick navigation -
]d
/[d
to jump between issues - Batch viewing -
<leader>xx
to see all diagnostics in Trouble - Auto-fixing - Many issues auto-fix on save
]d
- Next diagnostic (any severity)[d
- Previous diagnostic]e
- Next error (high severity only)[e
- Previous error<leader>xx
- Open Trouble diagnostics window<leader>e
- Show diagnostic details in floating window
- Backup existing config (already done - files moved to
.bak
) - Start Neovim - Lazy.nvim will auto-install
- Install LSP servers:
:Mason
then install:- pyright
- ruff
- mypy
- lua_ls
- Install Python tools:
pip install ruff mypy black
- Install debugpy:
pip install debugpy
(for debugging)
The configuration is modular and easy to customize:
- Add/remove plugins in
lua/plugins/*.lua
- Modify keybindings in
lua/config/keymaps.lua
- Adjust options in
lua/config/options.lua
- Configure LSP servers in
lua/plugins/lsp.lua
- LSP not starting - Run
:Mason
and ensure servers are installed - Formatting not working - Check that Ruff is installed:
pip install ruff
- Copilot not working - Run
:Copilot auth
to authenticate - Treesitter errors - Run
:TSUpdate
to update parsers
- Lazy loading - Most plugins load only when needed
- Native LSP - Uses Neovim's built-in LSP for best performance
- Optimized startup - Disabled unnecessary default plugins
Your old configuration has been preserved:
mappings.lua.bak
- Your original keybindingsoptions.lua.bak
- Your original optionsplugins.lua.bak
- Your original plugin configstatusline.lua.bak
- Your original statusline
Key differences:
- Plugin manager: Packer β Lazy.nvim
- File explorer: Netrw β Oil.nvim
- Completion: nvim-cmp (enhanced with better sources)
- Linting: Your nvim-lint setup β Modern Ruff + Pyright + mypy
- Formatting: Neoformat β conform.nvim
- Statusline: Galaxyline β Lualine
This configuration maintains the productivity focus of your original setup while leveraging the latest Neovim developments for a more powerful and modern development experience.