abhinav / abhinav/git-spice

Integration branch: a merged preview of multiple stacks

Offen
#1,244 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
enhancement proposal/accepted
Vorherrschende Sprache
Go
Sterne
762
Forks
72
Ø Merge
18 Std. 24 Min.
Gemergte PRs (30 T.)
28

Beschreibung

## Problem

When work is split across several parallel stacks, there is no single
ref that combines them for local testing or preview. Developers
manually merge tips together to get an integrated view, then have to
redo it by hand every time any stack changes.

## Proposal

Add an **integration branch** feature: a managed, throwaway ref that
merges a configured, ordered set of stack tips onto trunk. It is a
derived artifact — rebuilt from its configured tips on demand — giving
one combined branch for local testing without being load-bearing state.

Components:

- **State model**: repo-scoped integration info carrying the singleton
integration branch name, upstream branch, last-pushed hash (for
`--force-with-lease` leasing), and an ordered list of tips with the
hashes recorded at the last rebuild. Includes persistence of a paused
rebuild so a merge conflict can be resolved and resumed.
- **Git helpers**: `Merge`, `IsClean`, and `CheckoutNewBranch` worktree
primitives needed to build the merged branch.
- **Handler package**: orchestration for rebuild/advance/clean and
conflict-resume logic.
- **CLI**: the `gs integration` command tree.
- **Hooks**: auto-rebuild and auto-submit integration on relevant
operations.
- **Conflict handling**: regenerate conflicted derived files during the
rebuild merge rather than surfacing them as raw conflicts.

## Tracked by

- #1165 — state model for the integration branch
- #1172 — `Merge`, `IsClean`, `CheckoutNewBranch` git helpers
- #1173 — handler package for integration operations
- #1174 — wire the `gs integration` command tree
- #1175 — auto-rebuild and auto-submit hooks
- #1176 — regenerate conflicted derived files on merge

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.