pub struct PerCommandConfig {
pub command_case: Option<CaseStyle>,
pub keyword_case: Option<CaseStyle>,
pub line_width: Option<usize>,
pub tab_size: Option<usize>,
pub dangle_parens: Option<bool>,
pub dangle_align: Option<DangleAlign>,
pub max_pargs_hwrap: Option<usize>,
pub max_subgroups_hwrap: Option<usize>,
pub wrap_after_first_arg: Option<bool>,
pub continuation_align: Option<ContinuationAlign>,
}Expand description
Per-command overrides. All fields are optional — only specified fields override the global config for that command.
§YAML/TOML key names
Two fields use different names in config files than in this Rust struct (for historical reasons):
| Rust field | YAML/TOML key |
|---|---|
max_pargs_hwrap | max_hanging_wrap_positional_args |
max_subgroups_hwrap | max_hanging_wrap_groups |
All other fields use the same name in both.
Fields§
§command_case: Option<CaseStyle>Override the command casing rule for this command only.
keyword_case: Option<CaseStyle>Override the keyword casing rule for this command only.
line_width: Option<usize>Override the line width for this command only.
tab_size: Option<usize>Override the indentation width for this command only.
dangle_parens: Option<bool>Override dangling paren placement for this command only.
dangle_align: Option<DangleAlign>Override dangling paren alignment for this command only.
max_pargs_hwrap: Option<usize>Override the hanging-wrap positional argument threshold for this command only.
max_subgroups_hwrap: Option<usize>Override the hanging-wrap subgroup threshold for this command only.
wrap_after_first_arg: Option<bool>Keep the first positional argument on the command line when wrapping.
continuation_align: Option<ContinuationAlign>Override the continuation-alignment rule for this command.
Trait Implementations§
Source§impl Clone for PerCommandConfig
impl Clone for PerCommandConfig
Source§fn clone(&self) -> PerCommandConfig
fn clone(&self) -> PerCommandConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for PerCommandConfig
impl Debug for PerCommandConfig
Source§impl Default for PerCommandConfig
impl Default for PerCommandConfig
Source§fn default() -> PerCommandConfig
fn default() -> PerCommandConfig
Source§impl<'de> Deserialize<'de> for PerCommandConfig
impl<'de> Deserialize<'de> for PerCommandConfig
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>,
Source§impl JsonSchema for PerCommandConfig
impl JsonSchema for PerCommandConfig
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
$ref keyword. Read moreSource§impl PartialEq for PerCommandConfig
impl PartialEq for PerCommandConfig
Source§impl Serialize for PerCommandConfig
impl Serialize for PerCommandConfig
impl Eq for PerCommandConfig
impl StructuralPartialEq for PerCommandConfig
Auto Trait Implementations§
impl Freeze for PerCommandConfig
impl RefUnwindSafe for PerCommandConfig
impl Send for PerCommandConfig
impl Sync for PerCommandConfig
impl Unpin for PerCommandConfig
impl UnsafeUnpin for PerCommandConfig
impl UnwindSafe for PerCommandConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.