git-mcp-workflow

Guide Git repository inspection and recovery using git-mcp tools.

Updated Mar 11, 2026
One-click install
npx skills add https://github.com/selfagency/agentsy --skill git-mcp-workflow
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-mcp-workflow
Source: https://github.com/selfagency/agentsy/tree/main/.agents/skills/git-mcp-workflow
Command: npx skills add https://github.com/selfagency/agentsy --skill git-mcp-workflow

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

It prevents unsafe Git operations by guiding you through repository inspection and recovery/changes using the git-mcp tool surface instead of brittle shell git commands.

Core Features & Use Cases

  • MCP-first safety workflow: mandates using git-mcp tools for all Git inspection and mutations, including recovery, staging, committing, rebasing, cherry-picking, stashing, bisecting, worktrees, and LFS/release tagging flows.
  • Inspection-before-mutation: standardizes a start sequence (context summary, status, targeted history/diff/branches/remotes) so you understand state before writing history or pushing.
  • Shared-vs-local history guardrails: provides explicit safety order for undo/recovery and warns against risky published-history rewrites unless the user clearly approves.

Quick Start

Use the git-mcp-workflow skill to safely move your work off main after an accidental commit by asking it to inspect repo state first and then follow a reversible recovery path using git-mcp tools.

Frequently Asked Questions about git-mcp-workflow

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I recover from an accidental commit on main safely?

Safe Git recovery requires an inspection-first workflow using git-mcp tools to assess status and history before mutating, ensuring you understand the repository state and avoid unsafe shell git commands during undo operations.

What is the best way to undo a git reset or detached HEAD without losing work?

The best way to undo a git reset or detached HEAD is to apply a safety-ordered recovery sequence using git-mcp tools, which prioritizes reversible actions and protects published history during the restoration process.

Can I use git-mcp tools for staging, rebasing, and cherry-picking instead of shell git?

Yes, you can use git-mcp tools for staging, rebasing, and cherry-picking. The workflow mandates using git-mcp equivalents for all Git mutations and inspections, enforcing shell git avoidance to prevent unsafe operations.

How do I safely rewrite Git history on a shared branch?

Safely rewriting Git history on a shared branch requires explicit guardrails; the workflow warns against risky published-history rewrites unless clearly approved, providing shared-vs-local history protection through git-mcp inspection tools.

Does git-mcp support worktree management and release tagging workflows?

Yes, git-mcp supports worktree management, release tagging, and LFS handling. It standardizes these Git Flow operations by requiring a context summary and targeted status inspection before executing any staging or branching mutations.

When should I not use shell git commands for repository modifications?

You should not use shell git commands for repository modifications when a git-mcp equivalent exists. The workflow enforces shell git avoidance to ensure inspection-before-mutation and apply safety-ordered undo and recovery processes.