A Model Context Protocol server for Git repository interaction and automation. This server provides tools to read, search, and manipulate Git repositories via Large Language Models.
git_status
repo_path
(string): Path to Git repositorygit_diff_unstaged
repo_path
(string): Path to Git repositorycontext_lines
(number, optional): Number of context lines to show (default: 3)git_diff_staged
repo_path
(string): Path to Git repositorycontext_lines
(number, optional): Number of context lines to show (default: 3)git_diff
repo_path
(string): Path to Git repositorytarget
(string): Target branch or commit to compare withcontext_lines
(number, optional): Number of context lines to show (default: 3)git_commit
repo_path
(string): Path to Git repositorymessage
(string): Commit messagegit_add
repo_path
(string): Path to Git repositoryfiles
(string[]): Array of file paths to stagegit_reset
repo_path
(string): Path to Git repositorygit_log
repo_path
(string): Path to Git repositorymax_count
(number, optional): Maximum number of commits to show (default: 10)git_create_branch
repo_path
(string): Path to Git repositorybranch_name
(string): Name of the new branchstart_point
(string, optional): Starting point for the new branchgit_checkout
repo_path
(string): Path to Git repositorybranch_name
(string): Name of branch to checkoutgit_show
repo_path
(string): Path to Git repositoryrevision
(string): The revision (commit hash, branch name, tag) to showgit_init
repo_path
(string): Path to directory to initialize git repogit_branch
repo_path
(string): Path to the Git repository.branch_type
(string): Whether to list local branches ('local'), remote branches ('remote') or all branches('all').contains
(string, optional): The commit sha that branch should contain. Do not pass anything to this param if no commit sha is specifiednot_contains
(string, optional): The commit sha that branch should NOT contain. Do not pass anything to this param if no commit sha is specified{
"mcpServers": {
"mcpServers": {
"git": {
"command": "uvx",
"args": [
"mcp-server-git",
"--repository",
"path/to/git/repo"
]
}
}
}
}