#[non_exhaustive]pub enum Source {
Repository,
CargoVcsInfoFile,
}
Expand description
The source from which the version control information was read.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Repository
The version control info was read directly from the repository data.
CargoVcsInfoFile
The version control information was read from the .cargo_vcs_info.json
file.
This is only present in packages published to crates.io
. It is also only
present in repositories which use git
, and is unreliable, as there is no
guarantee that this value corresponds to an actual commit in the repository.
If the source
is set to this value, then the version control info
should be seen as potentially unreliable.
For more info, see The Cargo Book.
Trait Implementations§
impl Copy for Source
impl Eq for Source
impl StructuralPartialEq for Source
Auto Trait Implementations§
impl Freeze for Source
impl RefUnwindSafe for Source
impl Send for Source
impl Sync for Source
impl Unpin for Source
impl UnwindSafe for Source
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