Skip to main content
Glama
surajfale

Git Commit MCP Server

by surajfale

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
AI_MODELNoOpenAI model to use (default: gpt-4o-mini)gpt-4o-mini
ENABLE_AINoSet to true to use AI generation (default: true)true
LOG_LEVELNoLogging level: DEBUG, INFO, WARNING, ERROR (default: INFO)INFO
FORCE_SSH_ONLYNoRequire SSH for Git operations (default: true)true
OPENAI_API_KEYYesRequired when ENABLE_AI=true for AI-powered commit messages

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}
prompts
{
  "listChanged": false
}
resources
{
  "subscribe": false,
  "listChanged": false
}
experimental
{}

Tools

Functions exposed to the LLM to take actions

NameDescription
git_commit_and_pushA

Track changes, generate commit message, commit, and optionally push.

This tool automates the Git commit workflow by:

  1. Detecting all changes in the repository

  2. Generating a conventional commit message

  3. Staging and committing the changes

  4. Optionally pushing to remote (if confirm_push is True)

  5. Updating the CHANGELOG.md file

Supports both local repositories and remote repository URLs. For remote repositories, the tool will clone them to a workspace and perform operations there.

Args: repository_path: Path to the Git repository or remote URL (default: current directory) Supports: - Local paths: ".", "/path/to/repo", "relative/path" - SSH URLs: "git@github.com:user/repo.git" - HTTPS URLs: "https://github.com/user/repo.git" confirm_push: Whether to push to remote after committing (default: False)

Returns: Dictionary containing commit result information: - success: Whether the operation completed successfully - commit_hash: The SHA hash of the created commit - commit_message: The full commit message used - files_changed: Number of files affected - pushed: Whether the commit was pushed to remote - changelog_updated: Whether CHANGELOG.md was updated - message: Human-readable status message - error: Error message if operation failed

generate_commit_messageA

Analyze changes and generate a Conventional Commit message using AI.

  • For remote repositories, only SSH URLs are allowed.

  • Uses OpenAI gpt-4o-mini (configurable) when ENABLE_AI=true.

  • Falls back to heuristic generator on failure or when AI is disabled.

Returns: { success, commit_message, files_changed, message, error? }

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/surajfale/git-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server