v0.3.0

Fine-Grained Control
for AI File Operations

Surgical precision for editing. Ironclad control over access. 10 MCP tools for complete file and filesystem management.

How It Works

Every line gets a unique fingerprintβ€”a 2-character hash of its content. When your AI agent wants to edit line 2, it references 2:7f instead of just "line 2".

If someone inserts a line above, the old line 2 becomes line 3β€”but its hash stays 7f. Hashfile finds it automatically.

🎯
Content-Addressed

Anchors reference what the line says, not where it is

πŸ”’
Verified Edits

File hash prevents editing stale content

read_text_file
1:a3|function calculateTotal(items) {
2:7f| return items.reduce((sum, item) => sum + item.price, 0);
3:2c|}
file_hash: 8f3a9b β€’ total_lines: 3
edit_text_file
$ edit at anchor 2:7f
1:a3|function calculateTotal(items) {
2:b9| return items.reduce((sum, i) => sum + i.price * i.qty, 0);
3:2c|}
βœ“ Edit applied successfully

Complete File Management

🎯

Surgical Editing

Hash-anchored operations target the right content, not just line numbers. Edits survive file changes with fuzzy matching.

πŸ”’

Access Control

AGENTS.md frontmatter + automatic .gitignore support. Hierarchical discovery for fine-grained control with zero duplication.

πŸ“

10 MCP Tools

4 read tools (raw & hashline), 2 write tools, 1 edit tool, 3 filesystem tools. Complete API for file operations.

🌳

Token-Efficient

Compact tree format for directory listings. 10x more efficient than JSON. Optimized for AI context windows.

πŸ¦€

Built with Rust

Fast, safe, and reliable. Single binary with zero runtime dependencies. Works on Linux, macOS, and Windows.

⚑

Drop-In Compatible

Standard MCP filesystem server API plus hash-anchored editing. Replace your filesystem server with zero config.

Quick Start

// 1. Download the binary for your platform
curl -L https://github.com/mrorigo/hashfile-mcp/releases/download/v0.3.0/hashfile-mcp-YOUR_PLATFORM.tar.gz | tar xz

// 2. Add to your MCP client config (e.g., Claude Desktop)
{
  "mcpServers": {
    "hashfile": {
      "command": "/path/to/hashfile-mcp"
    }
  }
}

// 3. Use the tools in your AI agent
read_text_file({ "path": "/path/to/file.txt" })
edit_text_file({
  "path": "/path/to/file.js",
  "file_hash": "8f3a9b",
  "operations": [{...]
})