Documentation
¶
Index ¶
Constants ¶
View Source
const ( DefaultDataDir = "~/.config/atria" DefaultMonitorDir = "/tmp/atria-monitors" DefaultCacheTTL = 5 DefaultTmuxSession = "" DefaultPtyCols = 120 DefaultPtyRows = 40 )
Default values for configuration fields.
Variables ¶
This section is empty.
Functions ¶
func DefaultPath ¶
func DefaultPath() string
DefaultPath returns the default configuration file path.
Types ¶
type Config ¶
type Config struct {
WatchDirs []string `toml:"watch_dirs"`
TmuxPath string `toml:"tmux_path"`
TmuxSession string `toml:"tmux_session"`
KittenPath string `toml:"kitten_path"`
WezTermPath string `toml:"wezterm_path"`
DataDir string `toml:"data_dir"`
MonitorDir string `toml:"monitor_dir"`
CacheTTL int `toml:"cache_ttl"`
DefaultAgent string `toml:"default_agent"`
LaunchDir string `toml:"launch_dir"`
PtyCols int `toml:"pty_cols"`
PtyRows int `toml:"pty_rows"`
FocusMode string `toml:"focus_mode"`
UpdateCheck *bool `toml:"update_check"`
Integrations []string `toml:"integrations"` // ["iterm2", "tmux"]
}
Config holds the application configuration parsed from a TOML file.
func Load ¶
Load reads configuration from the given TOML file path. If the file does not exist, a Config with default values is returned without an error.
func (*Config) Save ¶
Save writes the config to the given TOML file path with help comments. Fields at default values are written as comments. Non-default values are written uncommented. Creates parent directories if needed.
func (*Config) UpdateCheckEnabled ¶ added in v0.3.0
UpdateCheckEnabled returns whether the upgrade check is enabled. Defaults to true when not explicitly set.
Click to show internal directories.
Click to hide internal directories.