pub struct GitCheckConfiguration<'a> { /* private fields */ }
Expand description
Configuration for checks to run against a repository.
Implementations§
Source§impl<'a> GitCheckConfiguration<'a>
impl<'a> GitCheckConfiguration<'a>
Sourcepub fn add_check(&mut self, check: &'a dyn Check) -> &mut Self
pub fn add_check(&mut self, check: &'a dyn Check) -> &mut Self
Add a check to be run on every commit.
Sourcepub fn add_branch_check(&mut self, check: &'a dyn BranchCheck) -> &mut Self
pub fn add_branch_check(&mut self, check: &'a dyn BranchCheck) -> &mut Self
Add a check to be once for the entire branch.
Sourcepub fn add_topic_check(&mut self, check: &'a dyn TopicCheck) -> &mut Self
pub fn add_topic_check(&mut self, check: &'a dyn TopicCheck) -> &mut Self
Add a check to be once for the entire topic.
Sourcepub fn run_commit(
&self,
ctx: &GitContext,
commit: &CommitId,
owner: &Identity,
) -> Result<CheckResult, RunError>
pub fn run_commit( &self, ctx: &GitContext, commit: &CommitId, owner: &Identity, ) -> Result<CheckResult, RunError>
Run checks over a given commit.
Sourcepub fn run_topic<R>(
&self,
ctx: &GitContext,
reason: R,
target_branch: &CommitId,
topic: &CommitId,
owner: &Identity,
) -> Result<TopicCheckResult, RunError>
pub fn run_topic<R>( &self, ctx: &GitContext, reason: R, target_branch: &CommitId, topic: &CommitId, owner: &Identity, ) -> Result<TopicCheckResult, RunError>
Run checks over a given topic and collect results from the checks.
Sourcepub fn run_topic_multi_base<'b, R, B>(
&self,
ctx: &GitContext,
reason: R,
target_branch: &CommitId,
bases: B,
topic: &CommitId,
owner: &Identity,
) -> Result<TopicCheckResult, RunError>
pub fn run_topic_multi_base<'b, R, B>( &self, ctx: &GitContext, reason: R, target_branch: &CommitId, bases: B, topic: &CommitId, owner: &Identity, ) -> Result<TopicCheckResult, RunError>
Run checks over a given topic involving multiple base commits.
Trait Implementations§
Source§impl<'a> Clone for GitCheckConfiguration<'a>
impl<'a> Clone for GitCheckConfiguration<'a>
Source§fn clone(&self) -> GitCheckConfiguration<'a>
fn clone(&self) -> GitCheckConfiguration<'a>
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for GitCheckConfiguration<'_>
impl Debug for GitCheckConfiguration<'_>
Source§impl<'a> Default for GitCheckConfiguration<'a>
impl<'a> Default for GitCheckConfiguration<'a>
Source§fn default() -> GitCheckConfiguration<'a>
fn default() -> GitCheckConfiguration<'a>
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl<'a> Freeze for GitCheckConfiguration<'a>
impl<'a> !RefUnwindSafe for GitCheckConfiguration<'a>
impl<'a> Send for GitCheckConfiguration<'a>
impl<'a> Sync for GitCheckConfiguration<'a>
impl<'a> Unpin for GitCheckConfiguration<'a>
impl<'a> !UnwindSafe for GitCheckConfiguration<'a>
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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