pub struct EditProjectPushRuleBuilder<'a> { /* private fields */ }
Expand description
Builder for EditProjectPushRule
.
Implementations§
source§impl<'a> EditProjectPushRuleBuilder<'a>
impl<'a> EditProjectPushRuleBuilder<'a>
sourcepub fn project<VALUE: Into<NameOrId<'a>>>(&mut self, value: VALUE) -> &mut Self
pub fn project<VALUE: Into<NameOrId<'a>>>(&mut self, value: VALUE) -> &mut Self
The project to get.
sourcepub fn commit_message_regex<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn commit_message_regex<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE ) -> &mut Self
Ensure commit messages match a given regular expression.
sourcepub fn commit_message_negative_regex<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn commit_message_negative_regex<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE ) -> &mut Self
Ensure commit messages do not match a given regular expression.
sourcepub fn branch_name_regex<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn branch_name_regex<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE ) -> &mut Self
Restrict branch names to a given regular expression.
sourcepub fn deny_delete_tag(&mut self, value: bool) -> &mut Self
pub fn deny_delete_tag(&mut self, value: bool) -> &mut Self
Do not allow users to delete a tag via git push
.
Users can still delete via the UI.
sourcepub fn member_check(&mut self, value: bool) -> &mut Self
pub fn member_check(&mut self, value: bool) -> &mut Self
Restrict commits by author (email) to existing GitLab users.
sourcepub fn prevent_secrets(&mut self, value: bool) -> &mut Self
pub fn prevent_secrets(&mut self, value: bool) -> &mut Self
Reject commits with secrets.
See GitLab docs for more details.
Require commiter email addresses match a given regular expression.
sourcepub fn file_name_regex<VALUE: Into<Cow<'a, str>>>(
&mut self,
value: VALUE
) -> &mut Self
pub fn file_name_regex<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE ) -> &mut Self
Reject files that match a given regular expression.
sourcepub fn max_file_size(&mut self, value: u64) -> &mut Self
pub fn max_file_size(&mut self, value: u64) -> &mut Self
Set the maximum size of a file (in megabytes).
sourcepub fn commit_committer_check(&mut self, value: bool) -> &mut Self
pub fn commit_committer_check(&mut self, value: bool) -> &mut Self
Users can only push commits to this repository if the committer email is one of their own verified emails.
sourcepub fn commit_committer_name_check(&mut self, value: bool) -> &mut Self
pub fn commit_committer_name_check(&mut self, value: bool) -> &mut Self
Enforce commit metadata name consistency.
If set, users can only push commits to the repository if the commit author name is consistent with their account.
sourcepub fn reject_unsigned_commits(&mut self, value: bool) -> &mut Self
pub fn reject_unsigned_commits(&mut self, value: bool) -> &mut Self
Reject commits that are not signed with a GPG key.
sourcepub fn build(
&self
) -> Result<EditProjectPushRule<'a>, EditProjectPushRuleBuilderError>
pub fn build( &self ) -> Result<EditProjectPushRule<'a>, EditProjectPushRuleBuilderError>
Trait Implementations§
source§impl<'a> Clone for EditProjectPushRuleBuilder<'a>
impl<'a> Clone for EditProjectPushRuleBuilder<'a>
source§fn clone(&self) -> EditProjectPushRuleBuilder<'a>
fn clone(&self) -> EditProjectPushRuleBuilder<'a>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more