pub struct Config {
pub provider: ProviderConfig,
pub models: ModelsConfig,
pub tui: TuiConfig,
pub agent: AgentSettings,
pub mcp: McpConfig,
pub external_notify: ExternalNotifyConfig,
pub shell: ShellConfig,
pub browser: BrowserConfig,
pub memory: MemoryConfig,
pub update: UpdateConfig,
pub index: IndexConfig,
}Fields§
§provider: ProviderConfig§models: ModelsConfig§tui: TuiConfig§agent: AgentSettings§mcp: McpConfig§external_notify: ExternalNotifyConfig§shell: ShellConfig§browser: BrowserConfig§memory: MemoryConfig§update: UpdateConfig§index: IndexConfigImplementations§
Source§impl Config
impl Config
pub fn user_root_dir() -> PathBuf
pub fn load() -> Result<Self>
pub fn config_dir() -> PathBuf
pub fn config_path() -> PathBuf
pub fn data_dir() -> PathBuf
pub fn ensure_dirs() -> Result<()>
pub fn save(&self) -> Result<()>
pub fn save_tui_preferences(theme: &str, accent: &str) -> Result<()>
pub fn save_trust_mode(mode: &TrustMode) -> Result<()>
pub fn save_provider_selection( provider_id: &str, model_id: Option<&str>, ) -> Result<()>
pub fn preferred_model_for_provider(&self, provider_id: &str) -> Option<String>
pub fn load_project(project_root: &Path) -> Result<Option<Self>>
pub fn load_local(project_root: &Path) -> Result<Option<Self>>
pub fn merge(global: &Config, project: &Config) -> Config
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Config
impl<'de> Deserialize<'de> for Config
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Config
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnsafeUnpin for Config
impl UnwindSafe for Config
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more