Documentation
¶
Overview ¶
Package config handles loading, saving, and defaulting of NeuronCLI configuration. Configuration is stored as TOML at ~/.config/neuron/config.toml and is created automatically with sensible defaults on first run.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigDir ¶
ConfigDir returns the path to the NeuronCLI configuration directory (~/.config/neuron). The directory is not guaranteed to exist.
func ConfigPath ¶
ConfigPath returns the full path to the TOML configuration file (~/.config/neuron/config.toml).
Types ¶
type AIConfig ¶
type AIConfig struct {
Enabled bool `toml:"enabled"`
Provider string `toml:"provider"` // "ollama", "openai", or "none"
Model string `toml:"model"`
OpenAIKey string `toml:"openai_key"` // leave empty when using Ollama
OllamaURL string `toml:"ollama_url"`
}
AIConfig holds AI/embedding provider settings.
type Config ¶
type Config struct {
VaultPath string `toml:"vault_path"`
Editor string `toml:"editor"` // command used to open notes (e.g. "nvim", "code")
Theme string `toml:"theme"` // "dark" or "light"
GitRemote string `toml:"git_remote"`
AI AIConfig `toml:"ai"`
}
Config is the top-level NeuronCLI configuration.
func DefaultConfig ¶
func DefaultConfig() Config
DefaultConfig returns a Config populated with sensible out-of-the-box values. The editor is taken from the $EDITOR environment variable, falling back to "vi".