Documentation
¶
Overview ¶
internal/config/config.go
Index ¶
- Variables
- type Config
- func (c *Config) GetPR(branch string) (int, error)
- func (c *Config) GetParent(branch string) (string, error)
- func (c *Config) GetTrunk() (string, error)
- func (c *Config) ListTrackedBranches() ([]string, error)
- func (c *Config) RemovePR(branch string) error
- func (c *Config) RemoveParent(branch string) error
- func (c *Config) SetPR(branch string, pr int) error
- func (c *Config) SetParent(branch, parent string) error
- func (c *Config) SetTrunk(branch string) error
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrBranchNotTracked = errors.New("branch not tracked")
ErrBranchNotTracked is returned when a branch is not tracked.
View Source
var ErrNoPR = errors.New("no PR associated with branch")
ErrNoPR is returned when a branch has no associated PR.
View Source
var ErrNotInitialized = errors.New("stack not initialized: run 'gh stack init' first")
ErrNotInitialized is returned when stack tracking is not initialized.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
Config provides access to stack metadata stored in .git/config.
func (*Config) ListTrackedBranches ¶
ListTrackedBranches returns all branches that have a stackParent set.
func (*Config) RemoveParent ¶
RemoveParent removes the parent tracking for a branch.
Click to show internal directories.
Click to hide internal directories.