git-advanced-workflows

Guide advanced Git operations including interactive rebase, bisect, worktrees, and reflog.

2|Updated Feb 6, 2026
One-click install
npx skills add https://github.com/bcastelino/agent-skills-kit --skill git-advanced-workflows-bcastelino
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-advanced-workflows
Source: https://github.com/bcastelino/agent-skills-kit/tree/main/skills/git-advanced-workflows
Command: npx skills add https://github.com/bcastelino/agent-skills-kit --skill git-advanced-workflows-bcastelino

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill empowers users to manage complex Git histories, recover from mistakes, and maintain a clean, professional commit log, crucial for collaborative development and project maintainability.

Core Features & Use Cases

  • History Editing: Rebase, squash, reword, and drop commits to refine your commit history.
  • Bug Finding: Utilize git bisect to efficiently pinpoint the exact commit that introduced a bug.
  • Parallel Development: Employ git worktrees to work on multiple features or fixes simultaneously without context switching.
  • Recovery: Leverage git reflog to recover lost commits or branches.
  • Use Case: Before merging a large feature branch, use interactive rebase to squash small fixup commits, reword messages for clarity, and ensure a linear, understandable history.

Quick Start

Use the git-advanced-workflows skill to clean up the last 5 commits on your current branch using interactive rebase.

Frequently Asked Questions about git-advanced-workflows

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

FAQPage Schema
How do I clean up my Git commit history before merging a feature branch?

To clean up Git commit history, use interactive rebase to squash, reword, or drop commits. This refines your commit log into a linear, understandable history before merging large feature branches into the main project.

How does git bisect work for finding a specific bug?

Git bisect works by performing a binary search through your commit history to pinpoint the exact commit that introduced a bug. It efficiently narrows down the faulty code change by checking out intermediate commits for testing.

Can I work on multiple Git branches simultaneously without switching context?

You can work on multiple Git branches simultaneously without context switching by using git worktrees. This feature allows you to manage multiple development streams by linking separate working directories to the same repository.

What is the best way to recover lost commits or deleted branches in Git?

The best way to recover lost commits or deleted branches is using git reflog. It leverages Git's internal record of reference updates to track down and restore accidental data loss from detached HEAD states or hard resets.

Do I need deep Git knowledge to use advanced operations like cherry-picking?

Yes, you need deep understanding of Git's internal mechanisms and command-line interface to safely perform advanced operations like cherry-picking, interactive rebase, and history editing without corrupting your repository.

When should I not use interactive rebase on my repository?

You should not use interactive rebase on branches that have already been pushed and shared with collaborators, as rewriting commit history creates divergent histories that cause severe merge conflicts for other users.