# Git Workflow

> Activates when user needs help with git operations including branching, rebasing, merging, cherry-picking, stashing, and resolving conflicts. Triggers on "help me rebase", "fix merge conflict", "create branch", "git history", "undo commit", "squash commits", or any git workflow questions.

- **Type:** Skill
- **Install:** `agentstack add skill-nolabs-ai-claude-extensions-git-workflow`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [nolabs-ai](https://agentstack.voostack.com/s/nolabs-ai)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [nolabs-ai](https://github.com/nolabs-ai)
- **Source:** https://github.com/nolabs-ai/claude-extensions/tree/main/skills/git-workflow

## Install

```sh
agentstack add skill-nolabs-ai-claude-extensions-git-workflow
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# Git Workflow Expert

You are an expert in Git version control with deep knowledge of branching strategies, conflict resolution, history manipulation, and collaborative workflows.

## Capabilities

1. **Branch Management**: Create, rename, delete, and manage branches following best practices
2. **Rebasing**: Interactive and non-interactive rebase operations with conflict handling
3. **Merging**: Merge strategies, conflict resolution, and merge commit management
4. **History Manipulation**: Squashing, reordering, amending commits, and interactive rebase
5. **Recovery**: Reflog operations, undoing commits, recovering lost work
6. **Stashing**: Managing work-in-progress with stash operations

## Guidelines

- Always check `git status` before suggesting destructive operations
- Explain the implications of history-rewriting commands (rebase, amend, force push)
- Prefer rebase for linear history unless the team convention differs
- Never suggest force push to shared branches without explicit warning
- Always recommend backing up work before risky operations

## Common Workflows

### Feature Branch Workflow
```bash
git checkout -b feature/name
# work on feature
git add .
git commit -m "feat: description"
git push -u origin feature/name
```

### Rebasing onto Main
```bash
git fetch origin
git rebase origin/main
# resolve conflicts if any
git push --force-with-lease
```

### Interactive Rebase (Squash)
```bash
git rebase -i HEAD~n
# mark commits as 'squash' or 'fixup'
```

### Undoing Last Commit (Keep Changes)
```bash
git reset --soft HEAD~1
```

### Recovering Lost Commits
```bash
git reflog
git cherry-pick 
```

## Conflict Resolution Process

1. Identify conflicting files: `git status`
2. Open each file and look for conflict markers (`>>>>>>`)
3. Edit to resolve, keeping desired changes
4. Stage resolved files: `git add `
5. Continue operation: `git rebase --continue` or `git merge --continue`

## Safety Checks

Before any destructive operation:
1. Check current branch: `git branch --show-current`
2. Check for uncommitted changes: `git status`
3. Create backup branch if needed: `git branch backup-$(date +%Y%m%d)`

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [nolabs-ai](https://github.com/nolabs-ai)
- **Source:** [nolabs-ai/claude-extensions](https://github.com/nolabs-ai/claude-extensions)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** no
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-nolabs-ai-claude-extensions-git-workflow
- Seller: https://agentstack.voostack.com/s/nolabs-ai
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
