Skip to main content
Glama

MCP File System Server

by kvas-it

MCP 文件系统服务器

MCP 服务器提供文件系统操作。支持浏览、读取、写入、分析文件以及执行命令。

工具

文件和目录操作

  • ls(path) ——列出目录内容
  • cd(path) - 更改工作目录(支持使用 ~ 扩展主目录)
  • read_file(path) - 读取文件内容
  • write_file(path, content) - 将内容写入文件
  • mkdir(path) ——创建目录
  • rm(path) - 删除文件或空目录
  • rmdir(path) - 递归删除目录和内容
  • cp(src, dst) - 复制文件或目录
  • mv(src, dst) - 移动文件或目录

编辑和搜索

  • edit_file(path, changes) - 对文件应用多个搜索/替换操作,其中 changes 是 (search_text, replace_text) 元组的列表
  • grep(pattern, path) - 在文件中搜索正则表达式模式

分析

  • summary(path) - 生成 Python (.py) 和 Markdown (.md) 文件的摘要:
    • Python:列出函数和类
    • Markdown:列出标题(以#开头的行)

批量操作

  • read_files(paths) - 读取多个文件,返回将路径映射到内容的字典
  • summarize(paths) - 为多个文件生成摘要,返回将路径映射到摘要的字典

项目导航

  • work_on(path) - 切换到目录,列出其内容,并从 CLAUDE.md 获取注释。在聊天开始时,它有助于熟悉项目。

代码质量

  • ruff_check(paths) - 在指定文件上运行 ruff linter
  • ruff_format(paths) - 使用 ruff 格式化文件

命令执行

  • shell_command(command, args=None, cmdline=None, timeout=30) - 运行 shell 命令并捕获其输出

    ⚠️ 安全警告:此工具允许在主机系统上执行任意命令。在允许命令运行之前,请务必检查并验证命令,尤其是在输入源不受信任的情况下。

-
security - not tested
F
license - not found
-
quality - not tested

local-only server

The server can only run on the client's local machine because it depends on local resources.

该服务器提供了执行导航、读取、写入和文件分析等基本文件系统操作的接口,使用户能够有效地管理目录和文件。

  1. 工具
    1. 文件和目录操作
    2. 编辑和搜索
    3. 分析
    4. 批量操作
    5. 项目导航
    6. 代码质量
    7. 命令执行

Related MCP Servers

  • -
    security
    A
    license
    -
    quality
    The Claude Dev Server enables direct interaction with the file system within a specified workspace, allowing users to perform file and directory operations and implement code artifacts in software development using natural language commands.
    Last updated -
    2
    Python
    MIT License
    • Apple
  • -
    security
    F
    license
    -
    quality
    An MCP server that allows Claude AI to perform filesystem operations including reading, writing, listing, moving files, and searching directories within specified allowed paths.
    Last updated -
    5
    1
    JavaScript
  • A
    security
    A
    license
    A
    quality
    A Model Context Protocol server that enables enhanced file system operations including reading, writing, copying, moving files with streaming capabilities, directory management, file watching, and change tracking.
    Last updated -
    12
    6
    TypeScript
    MIT License
  • A
    security
    A
    license
    A
    quality
    An MCP server that provides tools for reading, writing, and editing files on the local filesystem.
    Last updated -
    1
    1,387
    Python
    Apache 2.0
    • Apple

View all related MCP servers

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/kvas-it/mcp-server-fs'

If you have feedback or need assistance with the MCP directory API, please join our Discord server