MCP Filesystem Python

by punkpeye
Verified
MIT License
6
  • Apple
  • Linux

local-only server

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

Integrations

  • Supports configuration for Claude Desktop on Linux systems with specific configuration file paths

  • Supports configuration for Claude Desktop on macOS systems with specific configuration file paths

MCP ファイルシステム Python

指定されたディレクトリ内のファイルへの安全な読み取り専用アクセスを提供するモデル コンテキスト プロトコル (MCP) サーバー。

特徴

  • `file://` URI スキームを使用してファイルを MCP リソースとして公開します
  • MCPツールを通じてファイル検索機能を提供する
  • .gitignore パターンを尊重
  • パストラバーサル保護を含むセキュリティ機能
  • MIMEタイプの検出

インストール

UVの使用:

uv add mcp-filesystem-python

使用法

サーバーを実行します。

uv run src/filesystem/server.py /path/to/directory

クロードデスクトップ統合

設定例

Claude Desktop の設定例は `examples` ディレクトリにあります。

  • `examples/claude_desktop_config.json`: macOS/Linux の例
  • `examples/claude_desktop_config_windows.json`: Windows の例

これらのファイルは次の場所に配置する必要があります。

  • macOS: `~/ライブラリ/アプリケーションサポート/Claude/claude_desktop_config.json`
  • Windows: `%AppData%\Claude\claude_desktop_config.json`

必ず次の点に注意してください:

  1. パスを実際のパスに置き換えます
  2. macOS/Linuxの場合はスラッシュ(`/`)、Windowsの場合はバックスラッシュ(`\\`)を使用します
  3. 絶対パスを使用する(相対パスではない)

発達

  1. リポジトリをクローンする
  2. 仮想環境の作成と要件の同期、 uv sync

ライセンス

マサチューセッツ工科大学

-
security - not tested
A
license - permissive license
-
quality - not tested

このサーバーは、MCP を介してディレクトリ ファイルへの安全な読み取り専用アクセスを提供し、ファイル検索、.gitignore 準拠、パス トラバーサル保護、および 'file://' URI スキームを使用した MIME タイプ検出をサポートします。

  1. Features
    1. Installation
      1. Usage
        1. Claude Desktop Integration
          1. Configuration Examples
        2. Development
          1. License
            ID: pjawwhnuzf