Back to Skills

gitbutler

verified

This skill should be used when the user asks about GitButler, "but" commands (but status, but absorb, but rub, but commit, but undo, but snapshot), working in a gitbutler/workspace branch, safe git history manipulation, editing commits without rebase -i, squashing commits, fixing commit messages, undoing git operations, or using virtual branches. Use GitButler CLI instead of raw git commands when gitbutler/workspace is detected.

View on GitHub

Marketplace

boost-your-ai

aheritier/boost-your-ai

Plugin

gitbutler

development

Repository

aheritier/boost-your-ai
3stars

plugins/gitbutler/skills/gitbutler/SKILL.md

Last Verified

January 21, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/aheritier/boost-your-ai/blob/main/plugins/gitbutler/skills/gitbutler/SKILL.md -a claude-code --skill gitbutler

Installation paths:

Claude
.claude/skills/gitbutler/
Powered by add-skill CLI

Instructions

# GitButler CLI Guide

GitButler (`but`) is a modern Git client that makes history manipulation safe and reversible.

## [IMPORTANT] Detect GitButler Workspace

**Before running any git commands, check if GitButler is active:**

```bash
git branch --show-current
```

**If the result is `gitbutler/workspace`:**
- [PREFER] `but` commands when equivalent exists (commit, squash, undo, amend)
- [OK] Native git for operations `but` doesn't cover (cherry-pick, stash, tag, revert, blame)
- [CAUTION] Some git commands can corrupt virtual branch state (see below)

**Git Command Guidelines:**

| Prefer `but` | Use `git` freely | Use `git` with caution |
|--------------|------------------|------------------------|
| `but commit` over `git commit` | `git cherry-pick` | `git reset --hard` |
| `but rub` over `git rebase -i` | `git stash` | `git push --force` |
| `but undo` over `git reset` | `git tag` | `git rebase` |
| `but absorb` for amending | `git revert` | `git clean` |
| `but describe` for messages | `git blame`, `git bisect` | `git checkout <file>` |

**Why prefer `but` when available?** GitButler manages virtual branches through its workspace:
- `but` commands maintain virtual branch tracking
- `but undo` and oplog provide safer recovery
- Some raw git commands can corrupt the virtual branch state

**Quick detection pattern:**
```bash
# At start of git-related tasks, check:
if [[ $(git branch --show-current) == "gitbutler/workspace" ]]; then
    # Use 'but' commands instead of 'git'
fi
```

---

## Key Advantages Over Git

| Feature | Git | GitButler |
|---------|-----|-----------|
| Undo operations | Complex reflog | `but undo` |
| Time travel | Risky reset | `but restore <sha>` |
| Squash commits | `rebase -i` + editor | `but rub <src> <target>` |
| Fix old commit | stash → rebase → amend | `but absorb` |
| Multiple features | Switch branches constantly | Virtual branches (simultaneous) |

---

## Essential Commands

### Inspection (Always Start Here!)
```bash
but statu

Validation Details

Front Matter
Required Fields
Valid Name Format
Valid Description
Has Sections
Allowed Tools
Instruction Length:
8392 chars