使用说明
local-file-mcp-server
A simple mcp server to serve local files
Development getting started
This project uses uv, a better and faster python package manager.
Install it according to this documentation.
Prepare dev environment
Create venv and install all dependencies defined in pyproject.toml:
uv sync --all-groups
Run server locally
uv run main.py
Add MCP server to vscode
- Press
CTR + SHIFT + P, select 'MCP: Add server' - Select 'Command'
- As Command, type in: 'uv --directory "/ABSOLUTE/PATH/TO/REPOS/FOLDER/" run main.py'
- Enter Server ID, i.e. 'my-local-file-mcp-server'
- The mcp server should show under 'MCP Servers - Installed' area:
Example 1: Query local logfiles
Open ChatWindow with the tool 'get_logfiles' enabled as context and ask something along the lines: 'What happened between the communication of service a and service b according to the logs?'
The model should be able to pick up the test-logfiles in the ./logs subfolder and answer the question in this context.
