Documentation
¶
Overview ¶
Package navigation provides CLI commands for navigating branches in a stack.
Index ¶
- func NewBottomCmd() *cobra.Command
- func NewCheckoutCmd() *cobra.Command
- func NewCheckoutUI(_ output.Output, _ output.Logger) (*tui.Runner, actions.CheckoutHandler)
- func NewChildrenCmd() *cobra.Command
- func NewDownCmd() *cobra.Command
- func NewLogCmd() *cobra.Command
- func NewMainCmd() *cobra.Command
- func NewParentCmd() *cobra.Command
- func NewTopCmd() *cobra.Command
- func NewTrunkCmd() *cobra.Command
- func NewUpCmd() *cobra.Command
- type InteractiveCheckoutHandler
- type SimpleCheckoutHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCheckoutCmd ¶
NewCheckoutCmd creates the checkout command
func NewCheckoutUI ¶
NewCheckoutUI creates a runner and handler pair for checkout operations. The runner manages terminal state; the handler processes events. Caller must defer runner.Cleanup() to restore terminal on exit. Currently returns nil runner as interactive selection is handled inline.
func NewChildrenCmd ¶
NewChildrenCmd creates the children command
Types ¶
type InteractiveCheckoutHandler ¶
type InteractiveCheckoutHandler struct{}
InteractiveCheckoutHandler provides interactive TUI for TTY environments
func (*InteractiveCheckoutHandler) SelectBranch ¶
func (h *InteractiveCheckoutHandler) SelectBranch(ctx *app.Context, opts actions.CheckoutOptions) (string, error)
SelectBranch prompts the user to select a branch using the interactive log selector
type SimpleCheckoutHandler ¶
type SimpleCheckoutHandler struct{}
SimpleCheckoutHandler provides non-interactive output for non-TTY environments
func (*SimpleCheckoutHandler) SelectBranch ¶
func (h *SimpleCheckoutHandler) SelectBranch(_ *app.Context, _ actions.CheckoutOptions) (string, error)
SelectBranch returns an error since interactive selection is not available in non-TTY mode