All notable changes to this project will be documented in this file.
- Dependency Compatibility: Fixed installation error with rmcp-0.10.0
- Generate default schema for tools with no params. Resolves #122
- Document Reading Tool: Added new
readtool for reading document content with universal document identification support. The tool supports reading from buffer IDs, project-relative paths, and absolute file paths with optional line range specification (start/end parameters). This enables comprehensive document content access for analysis and processing workflows - LSP Call Hierarchy Support: Added comprehensive call hierarchy support
with three new LSP tools:
lsp_call_hierarchy_prepare,lsp_call_hierarchy_incoming_calls, andlsp_call_hierarchy_outgoing_calls. These tools provide full call hierarchy navigation capabilities including preparing call hierarchy items at specific positions, finding incoming callers, and discovering outgoing calls with complete range information - LSP Type Hierarchy Support: Added comprehensive type hierarchy support
with three new LSP tools:
lsp_type_hierarchy_prepare,lsp_type_hierarchy_supertypes, andlsp_type_hierarchy_subtypes. These tools provide full type hierarchy navigation capabilities including preparing type hierarchy items at specific positions, finding supertypes (parent types/interfaces), and discovering subtypes (implementations/derived types) with complete range and symbol information - Dynamic Connection Status in Server Info: Enhanced server information to include real-time connection status display showing current connection mode and active connections with their IDs and targets. This provides better visibility into the server state for debugging and operational awareness
- Enhanced Tool Documentation: Added external documentation for
buffer_diagnosticstool with separate markdown file containing detailed parameter descriptions. Updated tool registration to use external documentation instead of inline descriptions for better maintainability and richer documentation - Enhanced Cursor Position Tool: Extended cursor position tool to include buffer ID and window ID in addition to existing buffer name and coordinates, providing more comprehensive cursor context information
- Reduce Token Usage and Improve Compatibility: Removed redundant MCP server instructions and enriched tool descriptions to ensure compatibility with agents that do not parse server-level instructions.
- Position Parameter Refactoring: Refactored LSP tool parameter structures
to use a unified
Positiontype with#[serde(flatten)]attribute instead of separatelineandcharacterfields. This improves API consistency and reduces boilerplate code across all LSP tools that accept position parameters - Position Type Documentation: Simplified Position struct documentation by removing redundant encoding details that are better handled at the protocol level
- Connection Setup Refactoring: Extracted common client setup logic into
setup_new_clientmethod to reduce code duplication betweenconnect_pathandconnect_tcpmethods - Tool Filtering Enhancement: Improved tool filtering to automatically filter out connection-aware tools when no active connections exist, providing cleaner tool listings for users
- FormattingOptions Deserialization: Fixed
FormattingOptionsto support both string and struct deserialization formats for better compatibility with various MCP clients - Dynamic Tools Plugin Dependency (#62): Added plugin availability check before Lua tool discovery to prevent errors when nvim-mcp plugin is not installed. Server now gracefully handles missing plugin and continues with static tools only
- Lua Tool Discovery for Empty Registries: Fixed handling of cases where no Lua tools are registered by returning null/empty map instead of failing. Added fallback values for missing tool descriptions and input schemas to prevent errors during tool registration
- Test Environment Isolation: Added
-i NONEflag to Neovim test instances to disable shada file loading, ensuring consistent test behavior across different environments and preventing interference from user's vim history and settings
- Navigation Tool: Added
navigatetool to navigate to a specific position in the current buffer or open a file at a specific position with universal document identification support - Cursor Position Tool: Added
cursor_positiontool to get current cursor position with buffer name and zero-based row/col coordinates - LSP Readiness Tool: Added
wait_for_lsp_readytool for ensuring LSP client readiness before performing operations, improving reliability of LSP workflows
- Configurable LSP Timeout: Added
NeovimClientConfigwith configurable LSP timeout settings (default: 3000ms) for better control over LSP operation timing - Enhanced Notification Tracking: Comprehensive notification tracking system for robust LSP synchronization and event handling
- Autocmd Setup: Unified autocmd setup replacing diagnostics-specific implementation with more comprehensive event handling
- Test Performance: Optimized integration tests with better timing and one-time binary compilation for improved CI performance
- Code Coverage: Use grcov for LLVM-based code coverage with HTML, Cobertura, and Markdown report generation
- CI Coverage Integration: Added codecov.io integration with automated coverage reporting in GitHub Actions
- Lua Plugin Type Annotations: Added comprehensive type annotations for
SetupOptions,CustomTool, andJSONSchemaclasses to improve IDE support and documentation clarity
- LSP Workspace Symbols: Fixed
lsp_workspace_symbolsreturn type to useOption<DocumentSymbolResult>instead ofWorkspaceSymbolResultfor consistency with other LSP tools - Diagnostic Schema: Relaxed Diagnostic JSON schema to accept code as number or string for better compatibility
- Automatic Connection: Added automatic connection feature with CLI support for seamless integration with current project Neovim instances
- Project-Scoped Auto-Discovery: Automatically find and connect to Neovim instances associated with the current project directory
- Flexible Connection Modes: Support for manual, automatic, and specific target connection modes via CLI
- HTTP Server Transport: Added HTTP server mode for web-based integrations with streamable HTTP transport support
- Multi-Transport Support: Server now supports both stdio (default) and HTTP server transport modes for different integration scenarios
- Dynamic Tool System: Sophisticated dynamic tool registration system through
HybridToolRouterenabling extensible tool functionality without code changes - Lua Integration: Custom tool registration through Neovim configuration using Lua functions with automatic discovery and validation
- Connection-Scoped Tools: Tools automatically registered/unregistered with connection lifecycle for enhanced modularity
- Tool Visibility: Enhanced tool visibility through new resource system
- Tool Registration Resources: New
nvim-tools://URI scheme for monitoring tool availability and connection mappings - HybridToolRouter: Combines static tools (from
#[tool_router]macro) with dynamic tools using lock-free concurrent data structures - Conflict Resolution: Prevents naming conflicts between static and dynamic tools
- Dynamic Routing: Enhanced modular architecture with dynamic routing capabilities
- Tool Registration API: Improved extensibility through dynamic tool registration API
- MCP Helper Functions: Lua plugin provides helper functions (
MCP.success,MCP.error,MCP.text,MCP.json) for creating compatible MCP responses
--connect <MODE>- Connection mode: 'manual' (default), 'auto', or specific target (TCP address/socket path)manual: Traditional workflow using get_targets and connect toolsauto: Automatically connect to all project-associated Neovim instances- Specific target: Direct connection to TCP address or socket path
--http-port <PORT>- Enable HTTP server mode on the specified port--http-host <HOST>- HTTP server bind address (defaults to 127.0.0.1)
- Project Detection: Automatically detects current project root using git repository or working directory
- Socket Pattern Matching: Finds Neovim instances using project-specific socket naming patterns
- Graceful Fallback: Continues serving with manual connection capability if auto-connection fails
- Connection Validation: Validates target formats and provides clear error messages for invalid targets
- Added
hyperfor high-performance HTTP server transport - Added
hyper-utilfor HTTP utilities with server and service features - Added
tower-httpfor HTTP middleware and CORS support - Added
jsonschemafor JSON Schema validation in Lua custom tool parameters - Updated
rmcpto include streamable HTTP server transport features
- LSP Import Organization: Added
lsp_organize_importstool for sorting and organizing imports using LSP with auto-apply enabled by default - LSP Document Range Formatting: Added
lsp_range_formattingtool for formatting specific ranges in documents using LSP with support for LSP 3.15.0+ formatting preferences - LSP Document Formatting: Added
lsp_formattingtool for formatting documents using LSP with support for LSP 3.15.0+ formatting preferences - LSP Symbol Renaming: Added
lsp_renametool for renaming symbols across workspace with optional prepare rename validation - LSP Declaration Support: Added
lsp_declarationtool for finding symbol declarations with universal document identification
Enhanced LSP Integration:
lsp_organize_imports- Sort and organize imports using LSP with auto-apply enabled by default (buffer IDs, project paths, absolute paths)lsp_range_formatting- Format a specific range in a document using LSP with support for LSP 3.15.0+ formatting preferences and optional auto-apply (buffer IDs, project paths, absolute paths)lsp_formatting- Format document using LSP with support for LSP 3.15.0+ formatting preferences and optional auto-apply (buffer IDs, project paths, absolute paths)lsp_rename- Rename symbol across workspace using LSP with optional validation via prepare rename (buffer IDs, project paths, absolute paths)lsp_declaration- Get LSP declaration with universal document identification (buffer IDs, project paths, absolute paths)
- LSP Implementation Support: Added
lsp_implementationstool for finding interface/abstract class implementations with universal document identification (#33) - LSP Definition and Type Definition Support: Added
lsp_definitionandlsp_type_definitiontools for comprehensive symbol navigation with universal document identification
Enhanced LSP Integration:
lsp_implementations- Get LSP implementations with universal document identification (buffer IDs, project paths, absolute paths)lsp_definition- Get LSP definition with universal document identification (buffer IDs, project paths, absolute paths)lsp_type_definition- Get LSP type definition with universal document identification (buffer IDs, project paths, absolute paths)
- Package Metadata: Fixed commit SHA detection for crates.io packages (#38)
- Rust Compatibility: Added minimum supported Rust version (MSRV) requirement to prevent cryptic let-chains errors on older Rust compilers (#37)
- Build System: Enhanced crate metadata and build-time information
- Universal Document Identifier System: Enhanced LSP operations supporting buffer IDs, project-relative paths, and absolute file paths (#15)
- Complete LSP Code Action Workflow: Full lifecycle support for code actions with resolve and apply capabilities (#20)
- Enhanced Symbol Navigation: Workspace symbol search and document symbol analysis
- Advanced LSP Integration: References tracking and comprehensive code analysis tools
Enhanced LSP Integration:
lsp_workspace_symbols- Search workspace symbols by querylsp_references- Get LSP references with universal document identificationlsp_resolve_code_action- Resolve code actions with incomplete datalsp_apply_edit- Apply workspace edits using Neovim's LSP utility functions
Universal LSP Tools (enhanced existing tools):
lsp_code_actions- Now supports universal document identification (buffer IDs, project paths, absolute paths)lsp_hover- Enhanced with universal document identificationlsp_document_symbols- Get document symbols with universal document identification
- Primary Installation: Now available via
cargo install nvim-mcpfrom crates.io - Alternative Methods: Nix and source installation still supported
- Build-time metadata with Git information and timestamp (#28)
- Enhanced DocumentIdentifier deserialization for Claude Code compatibility
- Complete LSP code action lifecycle with native Neovim integration
- Connection resource leak in connect and connect_tcp tools (#13)
- Updated dependencies and fixed rmcp API compatibility
- Multi-Connection Support: Manage multiple concurrent Neovim instances with deterministic connection IDs
- Connection Management: Connect via TCP or Unix socket/named pipe with automatic discovery
- Buffer Operations: List and inspect all open buffers with detailed information
- Diagnostics Access: Retrieve diagnostics for buffers with error/warning details
- LSP Integration: Access code actions and LSP client information
- MCP Resources: Structured diagnostic data via connection-aware URI schemes
- Lua Execution: Execute arbitrary Lua code directly in Neovim
- Plugin Integration: Automatic setup through Neovim plugin
- Modular Architecture: Clean separation between core infrastructure, MCP tools, and resource handlers
Connection Management:
get_targets- Discover available Neovim targetsconnect- Connect via Unix socket/named pipeconnect_tcp- Connect via TCPdisconnect- Disconnect from specific Neovim instance
Buffer Operations:
list_buffers- List all open buffers with names and line countsbuffer_diagnostics- Get diagnostics for a specific buffer
LSP Integration:
lsp_clients- Get workspace LSP clientsbuffer_code_actions- Get available code actions for buffer rangebuffer_hover- Get symbol hover information via LSP
Code Execution:
exec_lua- Execute Lua code in Neovim
Connection Monitoring:
nvim-connections://- List all active Neovim connections
Connection-Scoped Diagnostics:
nvim-diagnostics://{connection_id}/workspace- All diagnostic messages across workspacenvim-diagnostics://{connection_id}/buffer/{buffer_id}- Diagnostics for specific buffer