[][src]Struct build_info_build::GitInfo

pub struct GitInfo {
    pub commit_id: String,
    pub commit_short_id: String,
    pub commit_timestamp: DateTime<Utc>,
    pub dirty: bool,
    pub branch: Option<String>,
    pub tags: Vec<String>,
}

Information about a git repository

If a git repository is detected (and, thereby, this information included), the build script will be rerun whenever the currently checked out commit changes.

Fields

commit_id: String

Full commit hash for the currently checked out commit

commit_short_id: String

Short commit hash for the currently checked out commit

The length of this string depends on the effective value of the git configuration variable core.abbrev, and is extended to the minimum length required for the id to be unique (at the time it was computed).

commit_timestamp: DateTime<Utc>

Timestamp of the currently checked out commit

dirty: bool

true iff the repository had uncommitted changes when building the project.

branch: Option<String>

Names the branch that is currently checked out, if any

tags: Vec<String>

All tags that point to the current commit (e.g., ["v0.0.10", "sample@v0.0.10"])

Trait Implementations

impl Clone for GitInfo[src]

impl Debug for GitInfo[src]

impl<'de> Deserialize<'de> for GitInfo[src]

impl Display for GitInfo[src]

impl Eq for GitInfo[src]

impl Hash for GitInfo[src]

impl Ord for GitInfo[src]

impl PartialEq<GitInfo> for GitInfo[src]

impl PartialOrd<GitInfo> for GitInfo[src]

impl Serialize for GitInfo[src]

impl StructuralEq for GitInfo[src]

impl StructuralPartialEq for GitInfo[src]

Auto Trait Implementations

impl RefUnwindSafe for GitInfo

impl Send for GitInfo

impl Sync for GitInfo

impl Unpin for GitInfo

impl UnwindSafe for GitInfo

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.