pub struct BranchProtection {
pub required_status_checks: Option<RequiredStatusChecks>,
pub enforce_admins: bool,
pub required_pull_request_reviews: Option<PullRequestReviewEnforcement>,
pub restrictions: Option<BranchRestrictions>,
pub required_linear_history: bool,
pub allow_force_pushes: bool,
pub allow_deletions: bool,
pub block_creations: bool,
pub required_conversation_resolution: bool,
pub lock_branch: bool,
pub allow_fork_syncing: bool,
}Expand description
Branch protection rules that control how a branch can be modified
Fields§
§required_status_checks: Option<RequiredStatusChecks>Status checks that must pass before merging
enforce_admins: boolWhether to enforce all configured restrictions for administrators
required_pull_request_reviews: Option<PullRequestReviewEnforcement>Pull request review requirements
restrictions: Option<BranchRestrictions>Restrictions on who can push to the branch
required_linear_history: boolWhether to require a linear commit history (no merge commits)
allow_force_pushes: boolWhether to allow force pushes to the branch
allow_deletions: boolWhether to allow branch deletions
block_creations: boolWhether to block creation of matching branches
required_conversation_resolution: boolWhether to require all conversations on code to be resolved before merging
lock_branch: boolWhether to lock the branch, making it read-only
allow_fork_syncing: boolWhether to allow users with push access to sync from upstream forks
Trait Implementations§
Source§impl Debug for BranchProtection
impl Debug for BranchProtection
Source§impl<'de> Deserialize<'de> for BranchProtection
impl<'de> Deserialize<'de> for BranchProtection
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>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Documented for BranchProtection
impl Documented for BranchProtection
Source§impl DocumentedFields for BranchProtection
impl DocumentedFields for BranchProtection
Source§const FIELD_NAMES: &'static [&'static str]
const FIELD_NAMES: &'static [&'static str]
Field names, as accepted by
Self::get_field_docs. Read moreSource§const FIELD_DOCS: &'static [&'static str]
const FIELD_DOCS: &'static [&'static str]
The static doc comments on each field or variant of this type, indexed
by field/variant order.
Source§impl FieldTypes for BranchProtection
impl FieldTypes for BranchProtection
Source§impl PartialEq for BranchProtection
impl PartialEq for BranchProtection
Source§impl Serialize for BranchProtection
impl Serialize for BranchProtection
impl StructuralPartialEq for BranchProtection
Auto Trait Implementations§
impl Freeze for BranchProtection
impl RefUnwindSafe for BranchProtection
impl Send for BranchProtection
impl Sync for BranchProtection
impl Unpin for BranchProtection
impl UnsafeUnpin for BranchProtection
impl UnwindSafe for BranchProtection
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> FromResponse for Twhere
T: DeserializeOwned,
impl<T> FromResponse for Twhere
T: DeserializeOwned,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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 moreSource§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request