Filesystem MCP Server
A Ruby server for performing filesystem operations like reading and writing files within specified directories.
Filesystem MCP Server
Ruby server implementing Model Context Protocol (MCP) for filesystem operations using the vector_mcp gem.
Features
- File operations: read, write, edit, move
- Directory operations: create, list
- Advanced search with filtering and sorting
- Bulk metadata operations
- Optional authentication and authorization
- Secure filesystem boundaries using MCP roots
Installation
- Install Ruby 3.1+ and bundler
- Clone this repository
- Run
bundle install
Usage
Basic Mode
ruby file_system_mcp.rb ~/Documents ~/Desktop
Secure Mode (with authentication)
FILESYSTEM_MCP_API_KEY=your-secret-key ruby file_system_mcp.rb --enable-auth ~/Documents
Claude Desktop Configuration
Add to your claude_desktop_config.json:
{
"mcpServers": {
"filesystem": {
"command": "ruby",
"args": [
"/path/to/file_system_mcp.rb",
"~/Documents",
"~/Desktop"
]
}
}
}
For secure mode:
{
"mcpServers": {
"filesystem": {
"command": "ruby",
"args": [
"/path/to/file_system_mcp.rb",
"--enable-auth",
"~/Documents"
],
"env": {
"FILESYSTEM_MCP_API_KEY": "your-secret-key"
}
}
}
}
Tools
File Operations
- read_file - Read complete file contents
- read_multiple_files - Read multiple files at once
- write_file - Create/overwrite files
- edit_file - Make precise text replacements with diff preview
- move_file - Move/rename files and directories
Directory Operations
- list_directory - List contents with optional metadata
- create_directory - Create directories recursively
Search Operations
- search_files - Basic recursive search with patterns
- find_files - Advanced search with sorting, filtering, and metadata
Info Operations
- get_file_info - Get detailed file/directory metadata
- get_bulk_file_info - Get metadata for multiple files efficiently
Security
The server enforces filesystem boundaries using MCP roots - it can only access directories specified as command-line arguments.
Optional authentication adds API key verification for all operations.
Requirements
- Ruby 3.1+
- vector_mcp gem v0.3.1+
Máy chủ liên quan
DLIS MCP Server
Analyze and extract information from DLIS (Digital Log Interchange Standard) files, including channel data and metadata.
PDF Agent MCP
A server for AI agents to selectively process and extract content from PDF documents.
Folder MCP
A server for local folder operations and file system access.
MCP File Preview Server
Preview local HTML files and capture screenshots, saving them to a local directory.
MCP Apple Notes
Perform semantic search and retrieval augmented generation over your Apple Notes.
OpenPyXL MCP Server
An MCP server that wraps the OpenPyXL library, enabling clients to retrieve data from Excel files.
IDE MEMORY MCP
IDE Memory MCP gives AI coding agents a persistent memory layer that works across any IDE supporting the Model Context Protocol. Write project context once — the AI remembers it everywhere.
FTP Access
Provides access to an FTP server for file operations.
Filesystem MCP Server
Provides file system operations, analysis, and manipulation capabilities through a standardized tool interface.
Filesystem MCP Server
A secure server for filesystem operations with controlled access to specified directories.