config

package
v1.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 31, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package config loads application and repository configuration from YAML.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppConfig

type AppConfig struct {
	WorktreeDir       string
	InitCommands      []string
	TerminateCommands []string
	SortByActive      bool
	AutoFetchPRs      bool
	MaxUntrackedDiffs int
	MaxDiffChars      int
	TrustMode         string
	DebugLog          string
	CustomCommands    map[string]*CustomCommand
}

AppConfig defines the global lazyworktree configuration options.

func DefaultConfig

func DefaultConfig() *AppConfig

DefaultConfig returns the default configuration values.

func LoadConfig

func LoadConfig(configPath string) (*AppConfig, error)

LoadConfig reads the application configuration from a YAML file.

type CustomCommand added in v1.1.0

type CustomCommand struct {
	Command     string
	Description string
	ShowHelp    bool
	Wait        bool
}

CustomCommand represents a user-defined command binding.

type RepoConfig

type RepoConfig struct {
	InitCommands      []string
	TerminateCommands []string
	Path              string
}

RepoConfig represents repository-scoped commands from .wt

func LoadRepoConfig

func LoadRepoConfig(repoPath string) (*RepoConfig, string, error)

LoadRepoConfig loads repository-specific commands from .wt in repoPath

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL