Back to Skills

git-spice

verified

This skill should be used when the user asks about "stacked branches", "git-spice", "gs command", "stacked PRs", "stacked pull requests", "stacked merge requests", "branch stacks", "restack branches", "submit stack", "gs branch", "gs stack", "gs upstack", "gs downstack", "gs repo sync", or needs help managing multiple dependent branches.

View on GitHub

Marketplace

clode

alexeldeib/clode

Plugin

clode

productivity

Repository

alexeldeib/clode
1stars

skills/git-spice/SKILL.md

Last Verified

January 20, 2026

Install Skill

Select agents to install to:

Scope:
npx add-skill https://github.com/alexeldeib/clode/blob/main/skills/git-spice/SKILL.md -a claude-code --skill git-spice

Installation paths:

Claude
.claude/skills/git-spice/
Powered by add-skill CLI

Instructions

# git-spice CLI

git-spice (`gs`) is a CLI tool for managing stacked Git branches.
It tracks relationships between branches, enables easy navigation,
and creates stacked Pull Requests on GitHub or Merge Requests on GitLab.

## Key Concepts

- **Stack**: Collection of branches stacked on top of each other
- **Trunk**: The default branch (main/master) with no base
- **Upstack**: Branches above the current branch
- **Downstack**: Branches below the current branch (not including trunk)
- **Restacking**: Rebasing a branch onto its base to maintain linear history

## Command Reference

### Repository Commands (`gs repo` / `gs r`)

| Command | Shorthand | Description |
|---------|-----------|-------------|
| `gs repo init` | `gs ri` | Initialize git-spice in a repository |
| `gs repo sync` | `gs rs` | Pull latest changes, delete merged branches |
| `gs repo restack` | `gs rr` | Restack all tracked branches |

### Branch Commands (`gs branch` / `gs b`)

| Command | Shorthand | Description |
|---------|-----------|-------------|
| `gs branch create <name>` | `gs bc` | Create and track a new stacked branch |
| `gs branch track` | `gs bt` | Track an existing branch |
| `gs branch untrack` | `gs but` | Stop tracking a branch (keep in Git) |
| `gs branch checkout <name>` | `gs bco` | Check out a branch (interactive if no name) |
| `gs branch delete <name>` | `gs bd` | Delete a tracked branch |
| `gs branch rename <new>` | `gs brn` | Rename the current branch |
| `gs branch submit` | `gs bs` | Submit current branch as a CR |
| `gs branch restack` | `gs br` | Restack current branch onto its base |
| `gs branch edit` | `gs be` | Interactive rebase of branch commits |
| `gs branch squash` | `gs bsq` | Squash all commits in current branch |
| `gs branch split` | `gs bsp` | Split branch into multiple branches |
| `gs branch onto <base>` | `gs bo` | Move branch to a different base |
| `gs branch fold` | `gs bf` | Fold branch into its base |

### Stack Commands (`gs stack` / `gs s`)

| 

Validation Details

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