pub struct CommonConfigFile {
pub log_level: Option<String>,
pub log_format: Option<String>,
}Expand description
Common config-file fields shared by every project crate. Flatten into
your ConfigFileRaw with #[serde(flatten)].
The CLI counterpart is generated inline by the MergeConfig derive
macro — each app gets per-app-prefixed env vars
(<app>_log_level, <app>_log_format, <app>_config), which a
shared struct cannot deliver since clap bakes env names into the
struct’s own attributes at the struct’s compile site.
Fields§
§log_level: Option<String>§log_format: Option<String>Trait Implementations§
Source§impl Debug for CommonConfigFile
impl Debug for CommonConfigFile
Source§impl Default for CommonConfigFile
impl Default for CommonConfigFile
Source§fn default() -> CommonConfigFile
fn default() -> CommonConfigFile
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for CommonConfigFile
impl<'de> Deserialize<'de> for CommonConfigFile
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 CommonConfigFile
impl RefUnwindSafe for CommonConfigFile
impl Send for CommonConfigFile
impl Sync for CommonConfigFile
impl Unpin for CommonConfigFile
impl UnsafeUnpin for CommonConfigFile
impl UnwindSafe for CommonConfigFile
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