Skip to content

git-mcp provides 30+ tools organized by function. Every tool accepts a repo_path parameter (the absolute path to the Git repository) unless noted otherwise. When GIT_REPO_PATH is configured server-side, repo_path is optional.

All tools accept a response_format parameter: "markdown" (default, human-readable) or "json" (machine-friendly structured data).

Tool Groups

GroupToolsDescription
Inspectgit_status, git_log, git_show, git_diff, git_blame, git_reflogRead-only repository inspection
Writegit_add, git_restore, git_commit, git_reset, git_revertStage, commit, and undo changes
Branchgit_list_branches, git_create_branch, git_delete_branch, git_rename_branch, git_checkout, git_set_upstreamBranch lifecycle management
Remotegit_list_remotes, git_remote, git_fetch, git_pull, git_pushRemote and transport operations
Advancedgit_stash, git_rebase, git_cherry_pick, git_bisect, git_tag, git_worktree, git_submoduleStash, rebase, tags, worktrees, submodules
Contextgit_context_summary, git_search, git_get_config, git_set_configRepository context and configuration
LFSgit_lfsGit Large File Storage
Git Flowgit_flowGitflow branching model workflows
Docsgit_docsGit documentation search

Common Parameters

These parameters are shared across most tools:

ParameterTypeDescription
repo_pathstringAbsolute path to the Git repository. Required unless GIT_REPO_PATH is set.
response_format"markdown" | "json"Output format. Defaults to "markdown".

Quick Reference

Inspect tools

text
git_status    repo_path
git_log       repo_path  [limit] [offset] [author] [grep] [since] [until] [file_path]
git_show      repo_path  ref
git_diff      repo_path  [mode] [from_ref] [to_ref] [filtered]
git_blame     repo_path  file_path  [ref]
git_reflog    repo_path  [limit]

Write tools

text
git_add       repo_path  [all] [paths]
git_restore   repo_path  paths  [staged] [worktree] [source]
git_commit    repo_path  message  [all] [amend] [no_edit] [sign] [signing_key] [no_verify]
git_reset     repo_path  [mode] [target] [paths] [confirm]
git_revert    repo_path  ref  [no_commit] [mainline]

Branch tools

text
git_list_branches   repo_path  [all]
git_create_branch   repo_path  name  [from_ref] [checkout]
git_delete_branch   repo_path  name  [force]
git_rename_branch   repo_path  old_name  new_name
git_checkout        repo_path  ref  [create]
git_set_upstream    repo_path  branch  upstream

Remote tools

text
git_list_remotes  repo_path
git_remote        repo_path  action  name  [url]
git_fetch         repo_path  [remote] [branch] [prune]
git_pull          repo_path  [remote] [branch] [rebase]
git_push          repo_path  [remote] [branch] [set_upstream] [force_with_lease] [force] [no_verify] [tags]

Advanced tools

text
git_stash        repo_path  action  [message] [index] [include_untracked]
git_rebase       repo_path  action  [onto]
git_cherry_pick  repo_path  action  [ref]
git_bisect       repo_path  action  [ref] [good_ref] [bad_ref] [command]
git_tag          repo_path  action  [name] [target] [message] [sign] [signing_key]
git_worktree     repo_path  action  [path] [branch]
git_submodule    repo_path  action  [url] [path] [recursive]

Context & config tools

text
git_context_summary  repo_path
git_search           repo_path  query  [limit]
git_get_config       repo_path  [key]
git_set_config       repo_path  key  value

LFS tool

text
git_lfs  repo_path  action  [patterns] [remote] [include] [exclude] [everything]

Git Flow tool

text
git_flow  repo_path  action  [name] [main_branch] [develop_branch] [remote] [tag] [tag_message] [delete_branch]

Docs tool (no repo_path)

text
git_docs  action  query

Released under the MIT License.