Neovim MCP Server
以下摘录自该仓库的 README(片段) · 在 GitHub 读完整 README →
A Model Context Protocol (MCP) server that provides seamless integration with
Neovim instances, enabling AI assistants to interact with your editor through
connections and access diagnostic information via structured resources.
Supports both stdio and HTTP server transport modes for different integration
scenarios.
Features
- **Multi-Connection Support**: Manage multiple concurrent Neovim instances
- **LSP Integration**: Complete LSP workflow with code actions, hover, and diagnostics
- **Universal Document Identifier**: Work with files by buffer ID, relative path,
or absolute path
- **MCP Resources**: Structured diagnostic data via connection-aware URI schemes
- **Multi-Transport Support**: Both stdio and HTTP server transport modes
- **Dynamic Tool System** ⚠️ **(Experimental)**: User-extensible custom tools
- **Plugin Integration**: Automatic setup through Neovim plugin
Installation
Use Cargo install from crates.io
Using Nix
This repository is a flake that exposes the server as its default
package and app.
Run it directly, without installing anything:
Or install it imperatively into your profile:
Declarative setup with home-manager
The snippet below installs the Neovim plugin and the server binary,
then registers it with Claude Code declaratively. No cargo install
build step and no manual claude mcp add:
This registers the nvim MCP server for every project, so you can skip
the manual claude mcp add step below.
**Tip:** git spawns throwaway Neovim instances to edit commit, merge and
rebase messages. If those load your full config they each call setup()
and register an extra socket in the same git root. Guard the call so
exactly one socket exists per repository:
From Source
Usage Cases Collection
- LSP Hover Translation (From #85)
- Diagnostic Analysis and Code Fixes (From #10)
- Smart Context Retrieval (From #86)
- And more in Discussions
Quick Start
1. Setup Neovim Integration
With a plugin manager like lazy.nvim:
2. Configure claude or other MCP clients
Documentation
For detailed information, see:
- **Usage Guide**: Detailed usage workflows, CLI options,
and transport modes