dnf-repofile 0.1.0

Pure Rust library for parsing, managing, validating, diffing, and rendering DNF/YUM .repo configuration files
Documentation
use crate::types::*;
use camino::Utf8PathBuf;
use indexmap::IndexMap;

/// DNF `[main]` configuration section
#[derive(Debug, Clone, PartialEq, Eq, Default)]
pub struct MainConfig {
    pub arch: Option<String>,
    pub basearch: Option<String>,
    pub releasever: Option<String>,
    pub cachedir: Option<Utf8PathBuf>,
    pub persistdir: Option<Utf8PathBuf>,
    pub logdir: Option<Utf8PathBuf>,
    pub config_file_path: Option<Utf8PathBuf>,
    pub installroot: Option<Utf8PathBuf>,
    pub reposdir: Vec<Utf8PathBuf>,
    pub varsdir: Vec<Utf8PathBuf>,
    pub pluginconfpath: Vec<Utf8PathBuf>,
    pub pluginpath: Vec<Utf8PathBuf>,
    pub debuglevel: Option<DebugLevel>,
    pub logfilelevel: Option<LogLevel>,
    pub log_rotate: Option<LogRotate>,
    pub log_size: Option<StorageSize>,
    pub installonly_limit: Option<InstallOnlyLimit>,
    pub errorlevel: Option<ErrorLevel>,
    pub metadata_timer_sync: Option<MetadataTimerSync>,
    pub allow_vendor_change: Option<DnfBool>,
    pub assumeno: Option<DnfBool>,
    pub assumeyes: Option<DnfBool>,
    pub autocheck_running_kernel: Option<DnfBool>,
    pub best: Option<DnfBool>,
    pub cacheonly: Option<DnfBool>,
    pub check_config_file_age: Option<DnfBool>,
    pub clean_requirements_on_remove: Option<DnfBool>,
    pub debug_solver: Option<DnfBool>,
    pub defaultyes: Option<DnfBool>,
    pub diskspacecheck: Option<DnfBool>,
    pub exclude_from_weak_autodetect: Option<DnfBool>,
    pub exit_on_lock: Option<DnfBool>,
    pub gpgkey_dns_verification: Option<DnfBool>,
    pub ignorearch: Option<DnfBool>,
    pub install_weak_deps: Option<DnfBool>,
    pub keepcache: Option<DnfBool>,
    pub log_compress: Option<DnfBool>,
    pub module_obsoletes: Option<DnfBool>,
    pub module_stream_switch: Option<DnfBool>,
    pub obsoletes: Option<DnfBool>,
    pub plugins: Option<DnfBool>,
    pub protect_running_kernel: Option<DnfBool>,
    pub strict: Option<DnfBool>,
    pub upgrade_group_objects_upgrade: Option<DnfBool>,
    pub zchunk: Option<DnfBool>,
    pub installonlypkgs: Vec<String>,
    pub protected_packages: Vec<String>,
    pub exclude_from_weak: Vec<String>,
    pub group_package_types: Vec<String>,
    pub optional_metadata_types: Vec<String>,
    pub tsflags: Vec<TsFlag>,
    pub usr_drift_protected_paths: Vec<String>,
    pub multilib_policy: Option<MultilibPolicy>,
    pub persistence: Option<Persistence>,
    pub rpmverbosity: Option<RpmVerbosity>,
    pub module_platform_id: Option<ModulePlatformId>,
    pub extras: IndexMap<String, Vec<String>>,
}