lib_conf_example_readme/lib.rs
1//! This is an example library for [`lib_conf`] and does not provide actual functionality.
2pub mod crab_log {
3 use lib_conf::LibConfig;
4
5 /// Settings for `crab-log`
6 #[derive(Debug, Clone, LibConfig)]
7 #[config(example_field_name = "logging")]
8 pub struct CrabLogConfig {
9 /// Enables the Logger library
10 #[config(copy, default = true)]
11 pub(crate) enabled: bool,
12
13 /// Enables verbose logging
14 #[config(copy, default = false)]
15 pub(crate) verbose: bool,
16
17 /// Enables file logging at the given path
18 ///
19 /// If no path is provided, file logging is disabled.
20 pub(crate) log_file_path: Option<String>,
21 }
22}