Back to MCP directory
publicPublicdnsLocal runtime

Filesystem (Rust)

rs_filesystem是一个简单的文件系统工具集,可用于Claude桌面或其他MCP客户端,提供资源、提示和工具显示功能,并通过MCP协议进行通信。

article

README

🚀 rs_filesystem: 基于Rust的MCP文件系统工具

rs_filesystem是一套简洁的文件系统工具,适用于Claude桌面或其他MCP客户端,能有效满足相关文件系统操作需求。

🚀 快速开始

✨ 主要特性

  • 丰富的CLI选项:提供了多种命令行选项,方便用户进行不同操作。
  • 适配Claude桌面:可在Claude桌面环境中便捷使用。

📦 安装指南

文档未提及安装步骤,暂不展示。

💻 使用示例

基础用法

rs_filesystem提供了以下CLI选项:

  • --mcp:启用MCP服务器
  • --resources:显示资源
  • --prompts:显示提示
  • --tools:显示工具

高级用法

在Claude Desktop中使用MCP CLI服务器的步骤如下:

  1. 编辑claude_desktop_config.json:通过Claude桌面的设置 -> 开发者 -> 编辑配置进入。
  2. servers部分添加以下配置:
{
   "mcpServers": {
      "rs_filesystem": {
         "command": "/path/to/rs_filesystem",
         "args": [
            "--mcp"
         ],
         "env": {
            "MCP_RS_FILESYSTEM_ALLOWED_DIRECTORIES": "/路径/数字/一:/路径/数字/二"
         }
      }
   }
}

请确保使用实际的rs_filesystem可执行文件路径。 请确保设置MCP_RS_FILESYSTEM_ALLOWED_DIRECTORIES环境变量为冒号分隔的允许目录列表。 这些工具仅在指定目录内有效。

如果你想查看MCP日志,请使用tail -n 20 -f ~/Library/Logs/Claude/rs_filesystem.logs.jsonl

📚 详细文档

参考资料

  • MCP规范:https://spec.modelcontextprotocol.io/
  • Model Context Protocol (MCP): https://modelcontextprotocol.io/introduction
  • rpc-router: JSON-RPC路由库 - https://github.com/jeremychone/rust-rpc-router/
  • Zed上下文服务器:https://github.com/zed-industries/zed/tree/main/crates/context_server
help

Runtime guide

cloud

Hosted runtime

Hosted servers run from a provider-managed environment. You usually connect the MCP client to the hosted endpoint or follow the provider's authorization flow, without keeping a local process alive

  1. Open provider connection page
  2. Authorize or copy endpoint
  3. Connect from your MCP client
terminal

Local runtime / other methods

Local servers run on your own machine or infrastructure. You normally copy the server_config into your MCP client, install the required package, and provide env variables from env_schema when needed

  1. Copy server_config
  2. Install required package
  3. Fill env variables and restart client