pub struct AttrRule {
pub attr_base: String,
pub pattern: String,
pub pattern_flags: u32,
pub nowildcardlen: usize,
pub skip: bool,
pub line: usize,
pub attrs: Vec<(String, AttrValue)>,
}Expand description
One line in a gitattributes file.
Fields§
§attr_base: StringDirectory of the .gitattributes file that defined this rule (repo-relative, /,
no trailing slash). Empty for the repository root file.
pattern: StringPattern body (no leading !; trailing / stripped; same as Git after parse_path_pattern prep).
pattern_flags: u32From parse_path_pattern: basename-only match vs full path under attr_base.
nowildcardlen: usizeLength of leading literal segment before first wildcard (Git nowildcardlen).
skip: boolIf true, this rule was discarded (negative pattern) after emitting a warning.
line: usize1-based line number in the source file.
attrs: Vec<(String, AttrValue)>Attribute assignments in source order (last wins for duplicates on this line).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for AttrRule
impl RefUnwindSafe for AttrRule
impl Send for AttrRule
impl Sync for AttrRule
impl Unpin for AttrRule
impl UnsafeUnpin for AttrRule
impl UnwindSafe for AttrRule
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