Skip to main content
ClaudeWave
Kavachh avatar
Kavachh

agent-guard-mcp

View on GitHub

Git-aware safe file operations MCP server for AI agents — delete anything except git-tracked source code. Safe to auto-approve.

MCP ServersOfficial Registry0 stars0 forksGoMITUpdated today
Install in Claude Code / Claude Desktop
Method: Manual · agent-guard-mcp
Claude Code CLI
git clone https://github.com/Kavachh/agent-guard-mcp
claude_desktop_config.json (Claude Desktop)
{
  "mcpServers": {
    "agent-guard-mcp": {
      "command": "agent-guard-mcp"
    }
  }
}
1. Run the command above in your terminal (Claude Code), or paste the JSON config into claude_desktop_config.json (Claude Desktop).
2. Replace any <placeholder> values with your API keys or paths.
3. Restart Claude. The MCP server and its tools appear automatically.
💡 Install the binary first: go install github.com/Kavachh/agent-guard-mcp@latest (make sure it ends up on your PATH).
Use cases

MCP Servers overview

# agent-guard-mcp

MCP server (written in **Go**, single static binary) for **git-aware safe file operations**. Give your AI agents (Claude Code, GitHub Copilot CLI, Cursor, …) free rein to delete what they build — while making it impossible for them to delete your git-tracked source code.

**Policy:** anything is deletable *until* it's tracked by a git repository.

## Tools

| Tool | Purpose |
|---|---|
| `safe_delete` | Delete files/dirs; refuses git-tracked files or dirs containing them. Supports `dry_run`. |
| `check_protection` | Report whether paths are protected and why. |
| `guard_status` | Summarize a directory: tracked (protected) vs untracked (deletable) counts. |

## Install

Build the single static binary (no runtime dependencies):
```bash
go build -o agent-guard-mcp .
```
Or install directly:
```bash
go install github.com/kavachh/agent-guard-mcp@latest
```

### Claude Code
```bash
claude mcp add agent-guard -- /path/to/agent-guard-mcp
```

### GitHub Copilot CLI
In `~/.copilot/mcp-config.json`:
```json
{
  "mcpServers": {
    "agent-guard": { "command": "/path/to/agent-guard-mcp", "args": [] }
  }
}
```

### Any MCP client (generic stdio config)
```json
{ "command": "/path/to/agent-guard-mcp", "args": [] }
```

## Recommended agent instructions

Add to your `CLAUDE.md` / `AGENTS.md` / `.github/copilot-instructions.md`:

> Never use `rm` in the shell. Always delete files with the `safe_delete` MCP tool, which protects git-tracked source code.

Since `safe_delete` can never destroy tracked source, it is safe to auto-approve this server's tools in your client's permission settings.

## Example

```
safe_delete { "paths": ["build/", "scratch.txt"] }
→ deleted (untracked)

safe_delete { "paths": ["src/main/java/App.java"] }
→ BLOCKED: git-tracked source file — use `git rm` deliberately if intended
```

## Requirements

- `git` on PATH
- Go ≥ 1.24 (build only — the binary itself has zero dependencies)

## Testing

24-case edge suite (tracked/staged/ignored files, nested repos, symlinks, dry-run, …):
```bash
go build -o agent-guard-mcp . && npm test
```

agent-safetyai-agentsclaudegitgithub-copilotgolangmcpmcp-server

What people ask about agent-guard-mcp

What is Kavachh/agent-guard-mcp?

+

Kavachh/agent-guard-mcp is mcp servers for the Claude AI ecosystem. Git-aware safe file operations MCP server for AI agents — delete anything except git-tracked source code. Safe to auto-approve. It has 0 GitHub stars and was last updated today.

How do I install agent-guard-mcp?

+

You can install agent-guard-mcp by cloning the repository (https://github.com/Kavachh/agent-guard-mcp) or following the README instructions on GitHub. ClaudeWave also provides quick install blocks on this page.

Is Kavachh/agent-guard-mcp safe to use?

+

Kavachh/agent-guard-mcp has not been audited yet by our security agent. Review the original repository on GitHub before using it in production.

Who maintains Kavachh/agent-guard-mcp?

+

Kavachh/agent-guard-mcp is maintained by Kavachh. The last recorded GitHub activity is from today, with 0 open issues.

Are there alternatives to agent-guard-mcp?

+

Yes. On ClaudeWave you can browse similar mcp servers at /categories/mcp, sorted by popularity or recent activity.

Deploy agent-guard-mcp to your cloud

Ship this repo to production in minutes. Each platform spins up its own environment with editable env vars.

Maintain this repo? Add a badge to your README

Drop the badge into your GitHub README to show it's tracked on ClaudeWave. Each badge links back to this page and reflects the live Trust Score.

Featured on ClaudeWave: Kavachh/agent-guard-mcp
[![Featured on ClaudeWave](https://claudewave.com/api/badge/kavachh-agent-guard-mcp)](https://claudewave.com/repo/kavachh-agent-guard-mcp)
<a href="https://claudewave.com/repo/kavachh-agent-guard-mcp"><img src="https://claudewave.com/api/badge/kavachh-agent-guard-mcp" alt="Featured on ClaudeWave: Kavachh/agent-guard-mcp" width="320" height="64" /></a>

More MCP Servers

agent-guard-mcp alternatives