Feature Request: Add `gh stack split` to split the current branch at a chosen commit
- Vorherrschende Sprache
- Go
- Sterne
- 1.5k
- Forks
- 70
- Ø Merge
- 1 T. 8 Std.
- Gemergte PRs (30 T.)
- 7
Beschreibung
## Problem
A branch often grows into two or more reviewable concerns, splitting these after the fact is tedious
Today it requires a manual operation: insert 1 PR above, cherry pick commits from PR1 to new PR2, rebase
If more than 1 split is required, it's even more error prone manipulations
## Proposal
`gh stack split [] [--at ]`
- Current branch keeps commits up to ``
- `` and commits above move to ``, inserted **directly above** the current branch in the stack (if some PR are already stacked above current PR)
- Branches already above are rebased onto the new layer; existing PRs keep their identity, the current PR's base is unchanged
Ideally, interactive mode lists the current branch's commits, user picks the split point and types the new branch name: this could happen in the `gh stack modify` view
Beitragsleitfaden
Rechercherichtung
Beginne mit dem bestehenden Einstiegspunkt des Befehls gh stack und der Ansicht gh stack modify, da der Vorschlag nahelegt, dort die interaktive Auswahl zum Aufteilen zu integrieren. Definiere das Verhalten der Aufteilung für den aktuellen Branch, für Branches, die bereits darüber liegen, und für die Identität des Pull Requests. Überprüfe anschließend, dass gh stack split die angegebenen Branch- und Commit-Optionen unterstützt und die genannten Stack-Beziehungen beibehält.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- git, github, go
- Bereich
- cli
- Issue-Typ
- Feature
- Schwierigkeit
- 5/5
- Geschätzter Aufwand
- Über eine Woche
- Aktivitätsstatus
- Aktiv
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 42/100