# Patchloom

Structured editing tool for JSON, YAML, TOML, and Markdown files that keeps formatting intact. Helpful when an agent must apply multi-file updates in a single turn.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 19
- Author: patchloom
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/patchloom/patchloom
- Updated: 2026-10-24
- HTML: https://affpapa.org/en/nevibecode/mcp/patchloom

## What it does

Standard filesystem servers treat documents as raw text strings. That approach frequently leads LLMs to corrupt indentation in YAML files or drop trailing commas in JSON. Patchloom uses structured parsers instead. It updates entries through target selectors, leaving comments and formatting intact.

The server supports multi-file grouping with `batch` and `tx` operations. Instead of waiting through multiple LLM round-trips, an agent issues one call to patch several files. If a check fails under strict settings, Patchloom reverts the entire transaction. It also provides AST modifications across 20 programming languages and edits Markdown tables relative to specific headings.

When running as an MCP server, path sandboxing remains permanently active to block directory traversal with `../` or absolute targets. Running it via `npx` requires an existing Node.js setup on your host system.

## Requirements
- Needs: Node.js (commands run via npx)

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add patchloom -- npx -y patchloom
```

### Codex

**Platform CLI**
```bash
codex mcp add patchloom -- npx -y patchloom
```

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "patchloom": {
            "command": "npx",
            "args": [
                "-y",
                "patchloom"
            ]
        }
    }
}
```

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "patchloom": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "patchloom"
            ]
        }
    }
}
```

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add patchloom npx -y patchloom
```

## When to use it
- modify YAML and TOML keys without erasing comments
- bundle multi-file edits into a single atomic transaction
- insert rows into Markdown tables by heading name
- rename code symbols using AST across 20 languages
- revert failed batch modifications automatically

## Example prompts
- Update the database port to 5432 in config.yaml using patchloom.
- Bump the release version to 2.0.0 in package.json, config.toml, and README.md in one batch.
- Append a new row to the table under the API heading in README.md.

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119160
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47392
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43872

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
