WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
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

@wmclifford
Copy link

Just going to drop a comment and hope to push this to be merged. I am looking for this functionality as well and was going to fork and add it but saw this PR. I'm sure there are probably other folks who would like this as well - is it possible to up priority on this? Thanks in advance.

- 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
@joaommartins joaommartins force-pushed the feat/git-signed-commit branch from 00306e3 to 48edde6 Compare December 9, 2025 22:47
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.

2 participants