A personal Neovim IDE configuration using native LSP (Neovim 0.10+) and lazy.nvim, with support for 14+ programming languages, advanced debugging, git workflows, and Arduino development.
This configuration uses Neovim's native LSP without wrapper plugins like nvim-lspconfig. Language servers are configured directly via Neovim's LSP API in individual files under /lsp/.
Supported Language Servers:
- lua_ls β Lua (LuaJIT runtime, Vim globals)
- rust_analyzer β Rust (lens, debug, run, test support)
- tsserver β TypeScript/JavaScript/TSX/JSX
- pyright β Python
- clangd β C/C++/Objective-C
- eslint β JavaScript/TypeScript linting
- tailwindcss β CSS framework intelligence
- cssls β CSS
- ocamllsp β OCaml
- texlab β LaTeX
- docker_language_server β Docker
- pest_ls β Pest parser expressions
- flux-lsp β InfluxDB Flux queries
- arduino_language_server β Arduino sketches (.ino)
- Fuzzy Finding: Telescope for files, live grep, buffers, projects, diagnostics
- File Explorer: NvimTree with git integration
- Debugging (DAP): Full breakpoint support with UI; Java debugging via nvim-jdtls
- Git Integration: Gitsigns, Fugitive, Rhubarb (GitHub integration)
- Auto-completion: nvim-cmp with LSP, snippet, buffer, and path sources
- Syntax Highlighting: Treesitter with 30+ parsers (incremental selection, playground)
- Formatting: LSP and none-ls (prettierd) async formatting
- Session Management: auto-session for project persistence
- Arduino Support: arduino-cli integration for compile, upload, serial monitor
- AI Assistant: CodeCompanion for OpenAI-powered code suggestions
- Project Navigation: Harpoon for quick file marking (Ctrl+1-4), project switching
- Surround.nvim:
cs,ds,ysbracket/tag operations - Comment.nvim:
gccline/block commenting - nvim-autopairs: Auto-pair brackets and tags
- Visual-multi: Multiple cursor support
- Todo-comments: Highlight and organize TODOs (
:TodoTelescope) - Auto-save: Automatic file saving
- Undo tree: Visual undo history (
:UndotreeToggle) - Smooth scrolling: Animated page scrolling
<C-h/j/k/l>β Window navigation<leader>pfβ Find files (Telescope)<leader>psβ Live grep (Telescope)<leader>eβ Toggle file explorer (NvimTree)Ctrl+1-4β Jump to Harpoon marked files<leader>pβ Switch projects (Telescope + project.nvim)
gdβ Goto definitiongDβ Goto declarationgiβ Goto implementationgrβ Goto referencesKβ Hover documentation<leader>rnβ Rename symbol<leader>caβ Code actions<leader>cfβ Format buffer[d/]dβ Next/previous diagnostic<leader>dsβ Show line diagnostics
F5β ContinueF10β Step overF11β Step intoF12β Step out<leader>bβ Toggle breakpoint<leader>Bβ Conditional breakpoint<leader>duβ Toggle DAP UI<leader>deβ Evaluate expression
gccβ Toggle comment (Comment.nvim)gnn/grn/grc/grmβ Treesitter incremental selectioncsβ Change surround (Surround.nvim)dsβ Delete surroundysβ Add surround<leader>stβ Toggle terminal (7-line split)<leader>yβ Yank to clipboard (visual)<leader>Yβ Yank whole buffer to clipboard
:Gitβ Open Fugitive interface:GBrowseβ Open GitHub URL in browser (Rhubarb)- Gitsigns signs in left margin show git changes
<leader>auβ Compile and upload sketch (arduino-cli)<leader>amβ Open serial monitor (split window)
<leader>qsβ Save session<leader>qrβ Restore session:TodoTelescopeβ List all TODOs:UndotreeToggleβ Visual undo history<leader>qqβ Quit Neovim
~/.config/nvim/
βββ init.lua # Entry point
βββ lazy-lock.json # Plugin lock file (lazy.nvim)
βββ lua/
β βββ plugins/ # Plugin declarations (7 organized modules)
β β βββ init.lua # lazy.nvim bootstrap
β β βββ core.lua # Core plugins (plenary, web-devicons)
β β βββ ui.lua # UI plugins (theme, statusline, explorer, etc.)
β β βββ navigation.lua # Navigation plugins (telescope, harpoon, etc.)
β β βββ editor.lua # Editor plugins (surround, comment, autopairs, etc.)
β β βββ git.lua # Git plugins (gitsigns, fugitive, etc.)
β β βββ ai.lua # AI plugins (codecompanion)
β β βββ lsp.lua # LSP/dev plugins (mason, treesitter, dap, etc.)
β βββ config/ # Feature configurations
β β βββ lsp.lua # Native LSP configuration
β β βββ lsp/ # Language-specific LSP setup (jdtls, null-ls)
β β βββ keymaps.lua # All keybindings
β β βββ options.lua # Vim options
β β βββ cmp.lua # Completion setup
β β βββ dap.lua # Debugging configuration
β β βββ ...
β βββ custom/ # Custom user code (Arduino, etc.)
β βββ cameleer/ # Custom navigation plugin
β βββ utils.lua # Utility functions
βββ lsp/ # Native LSP server configurations
β βββ lua_ls.lua
β βββ rust_analyzer.lua
β βββ tsserver.lua
β βββ pyright.lua
β βββ clangd.lua
β βββ ...
βββ ftplugin/ # Filetype-specific setup
βββ java.lua # Java configuration (jdtls)
βββ lua.lua # Lua configuration
- Clone or copy this configuration to
~/.config/nvim/ - Install Neovim 0.10+ β Required for native LSP API
- Start Neovim β lazy.nvim auto-installs on first run
- Install language servers via Mason (
:Masoncommand) or manually
lazy.nvim handles all plugin installation, caching, and dependency management automatically.
All LSP servers are configured in /lua/config/lsp.lua and individual files under /lsp/. This approach gives direct access to Neovim's LSP API without abstraction layers.
-- Example: Direct LSP configuration without nvim-lspconfig
vim.lsp.config("rust_analyzer", {
on_attach = on_attach,
capabilities = capabilities,
settings = { ... }
})
vim.lsp.enable({ "rust_analyzer" })- Virtual text with bullet prefix
- Rounded borders for floating previews
- Custom signs with icons
- Severity-sorted diagnostics
Special Java support via ftplugin/java.lua:
- nvim-jdtls for enhanced LSP features
- DAP with breakpoints and test debugging
- Debug adapter bundles (java-debug-adapter, java-test)
- Workspace:
~/.cache/jdtls/workspace/
- LSP-based formatting via language servers
- none-ls for additional linting (e.g., prettierd for code formatting)
- ESLint with custom handler for JavaScript/TypeScript
Custom integration in /lua/custom/arduino.lua:
- Compile sketches with arduino-cli
- Upload to board
- Monitor serial output
- Language server support for
.inofiles
Core (3): plenary.nvim, nvim-web-devicons
UI (7): rose-pine (theme), lualine (statusline), nvim-tree, alpha (dashboard), markview, nui, notify
Navigation (5): telescope, harpoon, project.nvim, auto-session, cameleer (custom)
Editing (13): comment.nvim, surround.nvim, colorizer, todo-comments, autopairs, ts-autotag, which-key, auto-save, cutlass, neoscroll, undotree, visual-multi, live-share
Git (4): gitsigns, mini.diff, fugitive, rhubarb
AI (1): codecompanion.nvim
LSP & Dev (15): mason, none-ls, nvim-dap, dap-ui, mason-nvim-dap, jdtls, treesitter, nvim-cmp, pest.nvim (custom), kulala, lazydev
- Neovim: 0.10+ (for native LSP API)
- Git: For lazy.nvim plugin installation and git integration
- Python: Required for treesitter and some plugins
- Language Servers: Installed via Mason (
:Mason) - Node.js: For TypeScript/JavaScript language server and others
- Optional: arduino-cli for Arduino support, OPENAI_API_KEY for CodeCompanion
- Color Scheme: rose-pine (moon variant)
- Icons: nvim-web-devicons for file type indicators
- Fonts: Recommended to use a Nerd Font for proper icon rendering
- Create
/lsp/your_server.luawith configuration - Add to
lsp_serverslist in/lua/config/lsp.lua - Call
:Masonto install the server
- Declare in
/lua/plugins/(core, ui, navigation, editor, git, ai, or lsp modules) - Add configuration in
/lua/config/if needed - Restart neovim or run
:Lazy install
Edit /lua/config/keymaps.lua and add your mappings following the existing structure.
- Leader key:
<Space>(spacebar) - Plugin Manager: lazy.nvim (auto-installing, auto-updating, fast)
- Plugin Lock File:
lazy-lock.jsontracks exact versions (commit to version control) - Auto-save is enabled by default
- Sessions are saved automatically (toggle with
<leader>qs/r) - Persistent undo stored in
~/.local/state/nvim/undo/ - Relative line numbers enabled for easier navigation
- Plugins installed to:
~/.local/share/nvim/lazy/(managed by lazy.nvim)
Feel free to extend and customize this configuration for your workflow. The modular structure makes it easy to add new plugins and configurations.
Personal configuration, feel free to fork and adapt!
Built for Neovim 0.10+ with native LSP β¨