Function collective::config::from_defaults

source ยท
pub fn from_defaults<P: AsRef<Path>, C: DeserializeOwned + Default + Serialize>(
    application_name: &str,
    additional_paths: &[(P, Option<ConfigFileFormat>)],
    format: ConfigFileFormat,
) -> Result<C, ConfigError>
Expand description

Similar to from_paths. Uses a default set of paths:

  • CURRENT_WORKING_DIRECTORY/config.toml
  • /etc/CRATE/config.toml