pub enum Fix {
None,
Rewrite,
}Expand description
Whether a check can rewrite the files it inspects.
Off by default and per check, never global: a hook that edits your files without being asked is a larger surprise than one that complains.
Variants§
None
Reports only. Every check, until somebody declares otherwise.
Rewrite
Runs a command that rewrites files, and stages what it changed.
Only reachable from a Stage::PreCommit declaration. A pre-push hook
must not modify the worktree or index: the pushed commit would then
differ from the tree the developer is looking at.
Implementations§
Trait Implementations§
impl Copy for Fix
impl Eq for Fix
impl StructuralPartialEq for Fix
Auto Trait Implementations§
impl Freeze for Fix
impl RefUnwindSafe for Fix
impl Send for Fix
impl Sync for Fix
impl Unpin for Fix
impl UnsafeUnpin for Fix
impl UnwindSafe for Fix
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