Git MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
GIT_DEFAULT_PATHNoDefault path for Git operations
GITHUB_PERSONAL_ACCESS_TOKENNoGitHub Personal Access Token for GitHub operations

Schema

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Tools

Functions exposed to the LLM to take actions

NameDescription
init

Initialize a new Git repository

clone

Clone a repository

status

Get repository status

add

Stage files

commit

Create a commit

push

Push commits to remote

pull

Pull changes from remote

branch_list

List all branches

branch_create

Create a new branch

branch_delete

Delete a branch

checkout

Switch branches or restore working tree files

tag_list

List tags

tag_create

Create a tag

tag_delete

Delete a tag

remote_list

List remotes

remote_add

Add a remote

remote_remove

Remove a remote

stash_list

List stashes

stash_save

Save changes to stash

stash_pop

Apply and remove a stash

bulk_action

Execute multiple Git operations in sequence. This is the preferred way to execute multiple operations.