modelcontextprotocol / modelcontextprotocol/servers

add new tool git-status and support for --require-clean-branch on filesystem server

Open
#1,759 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement server-git
Dominant language
TypeScript
Stars
90.5k
Forks
11.7k
Avg merge
2d 2h
Merged PRs (30d)
5

Description

Is your feature request related to a problem? Please describe.
one of the main concerns when using the filesystem server is untracked changes to files/directories. this feature allows us to ensure the files being changed are in a git repo with a clean branch before making changes.

Describe the solution you'd like
a new tool git-status that can check the working dir git status and return "clean" or "not clean" with a new flag --require-clean-branch. when set filesystem will require a clean git branch when making changes to files/dirs.

Describe alternatives you've considered
Alternatives right now: don't prompt it to do work unless you've manually checked the dir/repo status first. not great. i could ensure it's only working in git repos now with a more fine-tuned configuration. ie: allow access to less directories, but nothing prevents changes to files not yet committed.

Additional context
this would be gold.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the filesystem server implementation, its existing tool registration, and its option or flag parsing. Trace how file and directory changes are authorized, then verify that git-status reports the requested clean or not-clean result and that --require-clean-branch enforces the stated requirement before changes are made.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
backend
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.