Skip to main content

MCP server for filesystem operations with encoding support and umlaut fixing

Project description

filesystem-edit-mcp

An MCP (Model Context Protocol) server for filesystem operations with encoding support and umlaut fixing for C++ code.

Architecture

High-Level Overview

Encoding & Temp File Flow

Encoding Flow

Features

  • read_text_file: Read files with configurable encoding per file extension
  • edit_file: Edit files with pattern matching and automatic umlaut fixing
  • Path validation: Security boundary enforcement via ALLOWED_DIRS
  • Encoding support: Configure encodings per file pattern (e.g., latin-1 for .cpp)
  • Umlaut fixing: Transform German umlauts in C++ string literals, comments, and character constants

Installation

No extra dependencies. Pure Python — works out of the box.

uvx filesystem-edit-mcp

Configuration

Add to your MCP client config (Windsurf / Cursor / any MCP-compatible client):

{
  "mcpServers": {
    "filesystem-edit-mcp": {
      "command": "uvx",
      "args": ["filesystem-edit-mcp", "/path/to/your/codebase"]
    }
  }
}

Multiple directories:

{
  "mcpServers": {
    "filesystem-edit-mcp": {
      "command": "uvx",
      "args": ["filesystem-edit-mcp", "/path/to/dir1", "/path/to/dir2"]
    }
  }
}

Environment Variables

Variable Description
ALLOWED_DIRS Colon-separated allowed directories — CLI args take precedence
SERVER_CONFIG Path to the server config file (default: server_config.json)

Server Config

{
  "umlaut_config": {
    "string_mapping": { "Ä": "CAE_UMLT", "ä": "AE_UMLT" },
    "comment_mapping": { "Ä": "Ae", "ä": "ae" },
    "char_mapping": { "Ä": "CAE_UMLT_CHAR" }
  },
  "encoding_config": {
    "default": "utf-8",
    "mapping": { "*.cpp": "latin-1", "*.h": "latin-1" }
  }
}

Security

Security Diagram

Path validation prevents access to files outside configured directories.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

filesystem_edit_mcp-1.2.3.tar.gz (522.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

filesystem_edit_mcp-1.2.3-py3-none-any.whl (8.6 kB view details)

Uploaded Python 3

File details

Details for the file filesystem_edit_mcp-1.2.3.tar.gz.

File metadata

  • Download URL: filesystem_edit_mcp-1.2.3.tar.gz
  • Upload date:
  • Size: 522.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.6.6

File hashes

Hashes for filesystem_edit_mcp-1.2.3.tar.gz
Algorithm Hash digest
SHA256 2323832e810b2d5285b131c6276de2c7b787c51d622529a647c7567e0641d9b5
MD5 9a19e4098909212592305c56e070f0d9
BLAKE2b-256 c4eab1f3c1e9ef46c67ffbdeb7f6d48f15275051f81e47c406aa95a615720ce3

See more details on using hashes here.

File details

Details for the file filesystem_edit_mcp-1.2.3-py3-none-any.whl.

File metadata

File hashes

Hashes for filesystem_edit_mcp-1.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 032cf49e9be1df1dff66524061096defa3ee23a21e5dd2120678e219ef543f5b
MD5 c8be50e323c36621d379a58eeb9143b8
BLAKE2b-256 3ca34161637ed0e482f5d9e2fb5a2aad735f462cd25a2daf9c1aa0e84a4184cd

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page