pub struct Config {
pub repo: PathBuf,
pub hostname: String,
pub nix_packages_file: PathBuf,
pub homebrew_file: PathBuf,
pub module_files: Vec<(String, PathBuf)>,
pub prefer_nix_on_equal: bool,
pub platform: Platform,
pub registries: Vec<RegistryConfig>,
}Expand description
Resolved configuration for a nex session.
Fields§
§repo: PathBufPath to the nix config repo root (nix-darwin or NixOS).
hostname: StringHostname for system rebuild.
nix_packages_file: PathBufPath to the primary nix packages file (relative to repo).
homebrew_file: PathBufPath to the homebrew nix file (relative to repo). None on Linux.
module_files: Vec<(String, PathBuf)>Additional nix module files with home.packages lists.
prefer_nix_on_equal: boolWhen true, auto-pick nix for equal-version conflicts without prompting.
platform: PlatformThe detected platform (Darwin or Linux).
registries: Vec<RegistryConfig>Armory package registries for Omegon/package discovery.
Implementations§
Source§impl Config
impl Config
Sourcepub fn resolve(
cli_repo: Option<PathBuf>,
cli_hostname: Option<String>,
) -> Result<Self>
pub fn resolve( cli_repo: Option<PathBuf>, cli_hostname: Option<String>, ) -> Result<Self>
Resolve configuration from CLI args, env vars, config file, and auto-discovery.
Sourcepub fn all_nix_package_files(&self) -> Vec<&PathBuf>
pub fn all_nix_package_files(&self) -> Vec<&PathBuf>
All nix files that contain home.packages lists (for duplicate checking).
Sourcepub fn homebrew_formula_target(&self) -> Option<&Path>
pub fn homebrew_formula_target(&self) -> Option<&Path>
Configured Homebrew formula target, if this profile enables one.
Sourcepub fn homebrew_cask_target(&self) -> Option<&Path>
pub fn homebrew_cask_target(&self) -> Option<&Path>
Configured Homebrew cask target, if this profile enables one.
Sourcepub fn has_homebrew_provider(&self) -> bool
pub fn has_homebrew_provider(&self) -> bool
True when any Homebrew provider target is enabled for this profile.
Sourcepub fn auto_install_sources(&self) -> Vec<Source>
pub fn auto_install_sources(&self) -> Vec<Source>
Sources that auto-resolution may consider for this profile.