Documentation
¶
Overview ¶
cmd/abort.go
cmd/adopt.go
cmd/continue.go
cmd/create.go
cmd/init.go
cmd/link.go
cmd/log.go
cmd/orphan.go
cmd/restack.go
cmd/root.go
cmd/shortcuts.go
cmd/submit.go
cmd/sync.go
cmd/undo.go
cmd/unlink.go
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrConflict = errors.New("rebase conflict: resolve and run 'gh stack continue', or 'gh stack abort'")
ErrConflict indicates a rebase conflict occurred during restack.
Functions ¶
Types ¶
type RestackOptions ¶ added in v0.6.3
type RestackOptions struct {
// DryRun prints what would be done without actually rebasing.
DryRun bool
// Operation is the type of operation being performed (state.OperationRestack
// or state.OperationSubmit).
Operation string
// UpdateOnly skips creating new PRs; only existing PRs are updated.
// Submit-only.
UpdateOnly bool
// OpenWeb opens PRs in the browser after creation/update. Submit-only.
OpenWeb bool
// PushOnly skips the PR creation/update phase entirely. Submit-only.
PushOnly bool
// Branches is the complete list of branch names being submitted, used
// to rebuild the full set for push/PR phases after restack completes.
// Submit-only. Mirrors state.RestackState.Branches.
Branches []string
// StashRef is the commit hash of auto-stashed changes (if any), persisted
// to state so they can be restored when the operation completes or is aborted.
StashRef string
// Worktrees maps branch names to linked worktree paths. When non-nil, branches
// present in the map are rebased directly in their worktree directory instead
// of being checked out in the main working tree.
Worktrees map[string]string
}
RestackOptions configures the behaviour of doRestackWithState.
The submit-specific fields (UpdateOnly, OpenWeb, PushOnly, Branches) are only meaningful when Operation is state.OperationSubmit; they are persisted to restack state so that the push/PR phases can be resumed after a conflict.
type SubmitOptions ¶ added in v0.6.3
type SubmitOptions struct {
// DryRun prints what would be done without actually pushing or creating PRs.
DryRun bool
// UpdateOnly skips creating new PRs; only existing PRs are updated.
UpdateOnly bool
// OpenWeb opens created/updated PRs in the browser.
OpenWeb bool
// PushOnly skips the PR creation/update phase entirely.
PushOnly bool
}
SubmitOptions configures the push and PR phases of submit.
Click to show internal directories.
Click to hide internal directories.