pub enum Revalidation {
Revalidated {
tree: String,
index: PathBuf,
events: Vec<PolicyEvent>,
committed_paths: Vec<String>,
hook_changes: HookChanges,
},
Blocked {
events: Vec<PolicyEvent>,
exit_code: i32,
},
}Expand description
What: The result of revalidating a replayed tree. Why: A blocked tree stops the commit with the policies’ events; a revalidated one is rebuilt and landed.
In TS you’d write (pseudocode):
type Revalidation = { kind: 'revalidated'; ... } | { kind: 'blocked'; result };Variants§
Revalidated
The replayed commit may land.
Fields
§
events: Vec<PolicyEvent>The settled pass’s events, with the fix summary the corrections earned.
§
hook_changes: HookChangesWhat the re-run pre-commit staged.
Blocked
A policy blocked the replayed commit.
Fields
§
events: Vec<PolicyEvent>The blocking pass’s events.
Auto Trait Implementations§
impl Freeze for Revalidation
impl RefUnwindSafe for Revalidation
impl Send for Revalidation
impl Sync for Revalidation
impl Unpin for Revalidation
impl UnsafeUnpin for Revalidation
impl UnwindSafe for Revalidation
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more