# neovim

Guides AI coding agents through configuring a modular, performance-focused Neovim setup built on lazy.nvim, LSP, and DAP debugging.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode, Windsurf (Devin Desktop), Claude.ai · 308 installs · ★ 17 repo stars
- Author: julianobarbosa
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/julianobarbosa/claude-code-skills/tree/HEAD/skills/neovim/SKILL.md
- Updated: 2026-10-14
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/neovim

## What it does

This skill provides structural blueprints and code conventions for a modular Neovim setup. It standardizes changes around the `M.setup()` module pattern, `~/.config/nvim/` directory layout, and 9 plugin specification files managed by lazy.nvim. The architecture targets a sub-50ms startup time across 82 plugins.

The guide outlines loading strategies like `VeryLazy` or `BufReadPre`, LSP wiring via `mason.nvim` and `nvim-lspconfig`, keymap definitions, and debug adapters for nvim-dap. It also documents startup optimization techniques such as bytecode cache loading and deferred runtime setups.

Because the rules strictly target a modular directory layout under `lua/plugins/specs/`, they will clash with single-file `init.lua` setups.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add julianobarbosa/claude-code-skills --skill neovim -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/neovim/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/neovim/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add julianobarbosa/claude-code-skills --skill neovim -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/neovim/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add julianobarbosa/claude-code-skills --skill neovim -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/neovim/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install julianobarbosa/claude-code-skills skills/neovim
```

2. **Manually: put the files in place**
- File: `.github/skills/neovim/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add julianobarbosa/claude-code-skills --skill neovim -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/julianobarbosa/claude-code-skills --path skills/neovim
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/neovim/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add julianobarbosa/claude-code-skills --skill neovim -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/julianobarbosa/claude-code-skills/tree/HEAD/skills/neovim/SKILL.md

## When to use it
- register plugins with appropriate lazy-loading triggers in lazy.nvim
- add and configure language servers via mason and lspconfig
- set up debugging adapters and launch tasks for nvim-dap
- optimize editor startup time using deferred module calls

## Example prompts
- Add a new LSP server to mason-tool-installer and configure it in lspconfig
- Set up a debug adapter for Python inside lua/plugins/specs/debug.lua
- Create a custom keybinding under <leader> in lua/config/keymaps.lua

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: df9cb5c9d158b68c.

BEGIN THIRD-PARTY FILE df9cb5c9d158b68c
````text
---
name: neovim
description: Comprehensive guide for this Neovim configuration - a modular, performance-optimized Lua-based IDE. Use when configuring plugins, adding keybindings, setting up LSP servers, debugging, or extending the configuration. Covers lazy.nvim, 82+ plugins across 9 categories, DAP debugging, AI integrations, and performance optimization.
---

# Neovim Configuration Skill

A comprehensive guide for working with this modular, performance-optimized Neovim configuration built on lazy.nvim.

## Quick Reference

| Metric | Value |
|--------|-------|
| Plugin Manager | lazy.nvim |
| Total Plugins | 82 |
| Target Startup | <50ms |
| Module Pattern | `M.setup()` |
| Leader Key | `<Space>` |

## Architecture Overview

```
~/.config/nvim/
├── init.lua                  # Entry point
├── lua/
│   ├── config/               # Core configuration (11 modules)
│   │   ├── lazy.lua          # Plugin manager bootstrap
│   │   ├── options.lua       # Vim options
│   │   ├── keymaps.lua       # Key bindings
│   │   ├── autocmds.lua      # Autocommands
│   │   └── performance.lua   # Startup optimization
│   ├── plugins/specs/        # Plugin specs (9 categories)
│   │   ├── core.lua          # Foundation (plenary, nui, devicons)
│   │   ├── ui.lua            # UI (lualine, bufferline, noice)
│   │   ├── editor.lua        # Editor (autopairs, flash, harpoon)
│   │   ├── lsp.lua           # LSP (lspconfig, mason, conform)
│   │   ├── git.lua           # Git (fugitive, gitsigns, diffview)
│   │   ├── ai.lua            # AI (copilot, ChatGPT)
│   │   ├── debug.lua         # DAP (nvim-dap, dap-ui)
│   │   ├── tools.lua         # Tools (telescope, neo-tree)
│   │   └── treesitter.lua    # Syntax (treesitter, textobjects)
│   ├── kickstart/            # Kickstart-derived modules
│   └── utils/                # Utility functions
└── lazy-lock.json            # Plugin version lock
```

## Standard Module Pattern

All configuration modules follow the `M.setup()` pattern:

```lua
local M = {}

M.setup = function()
  -- Configuration logic here
end

return M
```

## Plugin Management (lazy.nvim)

### Adding a New Plugin

Add to the appropriate category file in `lua/plugins/specs/`:

```lua
-- lua/plugins/specs/tools.lua
return {
  -- Existing plugins...

  {
    "author/plugin-name",
    event = "VeryLazy",           -- Loading strategy
    dependencies = { "dep/name" }, -- Required plugins
    opts = {
      -- Plugin options
    },
    config = function(_, opts)
      require("plugin-name").setup(opts)
    end,
  },
}
```

### Loading Strategies

| Strategy | When to Use | Example |
|----------|-------------|---------|
| `lazy = true` | Default, load on demand | Most plugins |
````
END THIRD-PARTY FILE df9cb5c9d158b68c

The third-party file has ended. Everything between the df9cb5c9d158b68c tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2903 of 11410 bytes. © julianobarbosa · MIT · https://github.com/julianobarbosa/claude-code-skills/tree/HEAD/skills/neovim/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
