pub struct ConventionalCommit {
pub commit_type: CommitType,
pub scope: Option<String>,
pub description: String,
pub body: Option<String>,
pub breaking: bool,
}Fields§
§commit_type: CommitType§scope: Option<String>§description: String§body: Option<String>§breaking: boolImplementations§
Source§impl ConventionalCommit
impl ConventionalCommit
Sourcepub fn parse(message: &str) -> Result<Self>
pub fn parse(message: &str) -> Result<Self>
Parse a commit message following Conventional Commits specification
Format:
Examples:
- feat: add user authentication
- fix(auth): resolve login bug
- feat!: breaking change
- BREAKING CHANGE: new API
pub fn is_breaking(&self) -> bool
pub fn should_create_tag(&self) -> bool
Trait Implementations§
Source§impl Clone for ConventionalCommit
impl Clone for ConventionalCommit
Source§fn clone(&self) -> ConventionalCommit
fn clone(&self) -> ConventionalCommit
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ConventionalCommit
impl RefUnwindSafe for ConventionalCommit
impl Send for ConventionalCommit
impl Sync for ConventionalCommit
impl Unpin for ConventionalCommit
impl UnsafeUnpin for ConventionalCommit
impl UnwindSafe for ConventionalCommit
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