pub struct BinaryIdentity {
pub role: &'static str,
pub name: String,
pub path: String,
pub sha256: Option<String>,
pub version: Option<String>,
pub marker: Option<&'static str>,
pub running: bool,
pub channel: &'static str,
pub note: Option<&'static str>,
}Expand description
One executable dev-prune owns on this machine, and the digest a scanner sees.
A separate type from TrustRow because the hash has to survive into --json as a
field of its own. Somebody comparing their copy against a published .sha256 should
not have to parse it back out of a sentence.
Fields§
§role: &'static strStable identifier for --json: what this executable is for, not what it is
named, so a reader does not have to know that devp is the short name.
name: StringThe file name, for a human.
path: StringWhere it is.
sha256: Option<String>Lower-case hex SHA-256, or None when the file could not be read.
version: Option<String>The version this copy was built as, read out of its own bytes. None for a
build older than the stamp, which is every release before 1.17.0.
marker: Option<&'static str>latest release when this copy matches the newest release dev-prune has been
told about, newest here when no release check has run and this is simply the
highest version on the machine. None otherwise.
Two different claims and two different words, because a machine that has never asked GitHub anything cannot honestly call anything “latest”.
running: boolWhether this is the executable answering right now.
channel: &'static strWhich package manager put this copy here, as a word — cargo, npm, uv,
standalone. The path alone does not answer “why do I have three of these”,
and the answer decides which command removes the one you did not want.
note: Option<&'static str>Why this one’s digest differs from the others, when it does.
Implementations§
Auto Trait Implementations§
impl Freeze for BinaryIdentity
impl RefUnwindSafe for BinaryIdentity
impl Send for BinaryIdentity
impl Sync for BinaryIdentity
impl Unpin for BinaryIdentity
impl UnsafeUnpin for BinaryIdentity
impl UnwindSafe for BinaryIdentity
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
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> ⓘ
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> ⓘ
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 more