Documentation
¶
Index ¶
- func BoolPtr(v bool) *bool
- func GlobalConfigPath() string
- func IsWillowRepo(bareDir string) bool
- func ListRepos() ([]string, error)
- func LocalConfigPath(bareDir string) string
- func ReposDir() string
- func ResolveRepo(name string) (string, error)
- func Save(cfg *Config, path string) error
- func SharedConfigPath(worktreeRoot string) string
- func WillowHome() string
- func WorktreesDir() string
- type Config
- type Defaults
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GlobalConfigPath ¶
func GlobalConfigPath() string
func IsWillowRepo ¶ added in v0.1.2
IsWillowRepo checks if bareDir lives under ~/.willow/repos/. Both paths are resolved through EvalSymlinks to handle macOS /var → /private/var.
func ListRepos ¶ added in v0.1.2
ListRepos scans ~/.willow/repos/ for *.git dirs and returns repo names (without .git suffix).
func LocalConfigPath ¶
func ResolveRepo ¶ added in v0.1.2
ResolveRepo returns the bare dir path for a named repo under ~/.willow/repos/.
func SharedConfigPath ¶
func WorktreesDir ¶
func WorktreesDir() string
Types ¶
type Config ¶
type Config struct {
BaseBranch string `json:"baseBranch,omitempty"`
BranchPrefix string `json:"branchPrefix,omitempty"`
Setup []string `json:"setup,omitempty"`
Teardown []string `json:"teardown,omitempty"`
Defaults Defaults `json:"defaults"`
}
func DefaultConfig ¶
func DefaultConfig() *Config
Click to show internal directories.
Click to hide internal directories.