git-mastery-suite

Resolve complex Git history and branching problems with interactive rebases, conflict resolution, and bisect debugging.

Updated Aug 27, 2026
One-click install
npx skills add https://github.com/doctorduke/claude-config --skill git-mastery-suite
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-mastery-suite
Source: https://github.com/doctorduke/claude-config/tree/main/skills/git-mastery-suite
Command: npx skills add https://github.com/doctorduke/claude-config --skill git-mastery-suite

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Git can be complex and error-prone, leading to lost work, broken history, and team friction. This Skill automates advanced Git operations, allowing you to fix mistakes, manage complex workflows, and maintain a clean, reliable codebase without deep manual expertise.

Core Features & Use Cases

  • History Rewriting & Cleanup: Effortlessly rebase, squash, reword, or drop commits to maintain a pristine Git history.
  • Mistake Recovery: Instantly recover lost commits or branches using the reflog, undoing accidental resets or force pushes.
  • Parallel Development: Use Git worktrees to work on multiple branches simultaneously without stashing or context switching.
  • Use Case: You accidentally force-pushed to main and lost critical commits. Use this Skill to recover the lost history, rebase it onto the correct main, and push a clean, corrected branch, all with guided commands.

Quick Start

Recover the last 3 lost commits from the reflog and create a new branch called 'recovery-feature' from them.

Frequently Asked Questions about git-mastery-suite

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

FAQPage Schema
How do I recover lost commits after an accidental force push or reset?

Recover lost commits using Git's reflog, which tracks all HEAD movements. Run `git reflog` to find the commit SHA, then create a new branch from it or rebase it onto your current branch. This restores work that appears deleted but remains in Git's history until garbage collection.

What's the best way to clean up and rewrite Git history with interactive rebase?

Interactive rebase lets you reword, squash, drop, or reorder commits to maintain a clean history. Use `git rebase -i` to select commits, then choose actions like squash to combine them or reword to edit messages. This produces a polished, linear history before merging.

How do I work on multiple Git branches simultaneously without stashing?

Git worktrees create isolated working directories for different branches, eliminating context switching and stash overhead. Run `git worktree add` to spawn a parallel workspace, work independently on each branch, then merge and clean up. This accelerates parallel development workflows.

Can I resolve complex merge conflicts and maintain repository integrity?

This Skill handles interactive conflict resolution, commit surgery, and safe recovery strategies for professional repositories. Combine rebasing, worktrees, and reflog techniques to untangle broken history, fix botched merges, and restore a reliable codebase without data loss.

How do I use Git bisect to debug and find the commit that introduced a bug?

Bisect automates binary search through commit history to locate the exact change that broke functionality. Mark a known-good and known-bad commit, then bisect tests intermediate commits until it isolates the culprit, speeding root-cause analysis in large repositories.

What are the limitations of rebasing and when should I avoid it?

Rebasing rewrites history and should not be used on shared, published branches where teammates have already committed. Use it only on local or feature branches before pushing. Force-pushing rebased branches to shared branches causes conflicts and frustration; merge is safer for collaborative work.