# git-tools MCP server

> Enables coding agents to manage git state, commits, history rewrites, stacked branches, worktrees, and pushing to remotes.

- Repository: https://github.com/craft-agent/git-tools
- Page: https://hostedmcp.org/servers/craft-agent/git-tools
- Transport: stdio
- Stars: 0
- Latest version: 0.4.0

## Install

### Claude Code

```sh
claude mcp add git-tools -- npx -y @craftsamo/git-tools
```

### Cursor (`~/.cursor/mcp.json`)

```json
{
  "mcpServers": {
    "git-tools": {
      "command": "npx",
      "args": [
        "-y",
        "@craftsamo/git-tools"
      ]
    }
  }
}
```

### VS Code (`.vscode/mcp.json`)

```json
{
  "servers": {
    "git-tools": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@craftsamo/git-tools"
      ]
    }
  }
}
```

### VS Code CLI

```sh
code --add-mcp '{"name":"git-tools","type":"stdio","command":"npx","args":["-y","@craftsamo/git-tools"]}'
```

### Claude Desktop (`claude_desktop_config.json`)

```json
{
  "mcpServers": {
    "git-tools": {
      "command": "npx",
      "args": [
        "-y",
        "@craftsamo/git-tools"
      ]
    }
  }
}
```

### Codex

```sh
codex mcp add git-tools -- npx -y @craftsamo/git-tools
```

### Codex config.toml (`~/.codex/config.toml`)

```toml
[mcp_servers.git-tools]
command = "npx"
args = ["-y", "@craftsamo/git-tools"]
```

### Gemini CLI

```sh
gemini mcp add -s user git-tools npx -- -y @craftsamo/git-tools
```

### Gemini settings.json (`~/.gemini/settings.json`)

```json
{
  "mcpServers": {
    "git-tools": {
      "command": "npx",
      "args": [
        "-y",
        "@craftsamo/git-tools"
      ]
    }
  }
}
```

## Tools (20)

- `repo`
- `commit`
- `rebase`
- `worktree`
- `push`
- `git_repo_read`
- `git_commit_read`
- `git_commit_stage`
- `git_commit_create`
- `git_commit_amend`
- `git_commit_verify`
- `git_rebase_read`
- `git_rebase_start`
- `git_rebase_resume`
- `git_rebase_split`
- `git_worktree_read`
- `git_worktree_add`
- `git_worktree_remove`
- `git_push_read`
- `git_push_send`

## FAQ

### What capabilities does the repo toolset provide?

The repo toolset allows for local reads including status, history, origin information, and conflict detection.

### Can I use this server in read-only mode?

Yes, you can pass the --read-only flag when configuring the server in your MCP host.

### Does this tool support GitHub pull requests?

No, pull requests and native GitHub stacks are handled by a separate tool called github-tools.
