Skip to content

Conversation

@joaommartins
Copy link

Description

  • Add git_commit_signed tool that supports GPG signing of commits
  • Accepts optional key_id parameter to sign with specific GPG key
  • Uses git commit -S flag for signing (works with default or specified key)
  • Add comprehensive tests for signed commits
  • Update GitTools enum and tool registration

Server Details

  • Server: git
  • Changes to: tools, README

Motivation and Context

I use the git mcp server extensively, but I prefer to have my git commits GPG-signed. This change adds slightly modifies the git_commit inputs, but has to use the git.Repo.git.commit function instead of git.Repo.index.commit, which doesn't support GPG-signed git commits.

How Has This Been Tested?

There are tests present that cover the functionality implemented. The commits in this branch were also created using the new tool itself.

Breaking Changes

None.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Protocol Documentation
  • My changes follows MCP security best practices
  • I have updated the server's README accordingly
  • I have tested this with an LLM client
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have documented all environment variables and configuration options

- Add git_commit_signed tool that supports GPG signing of commits
- Accepts optional key_id parameter to sign with specific GPG key
- Uses git commit -S flag for signing (works with default or specified key)
- Add comprehensive tests for signed commits
- Update GitTools enum and tool registration
- Document how to call git_commit_signed via MCP and examples
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant