MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / git2_oid_of

Function git2_oid_of

atomic-repository/src/repository/resurrection.rs:102–106  ·  view source on GitHub ↗
(oid: &atomic_core::operation::GitObjectId)

Source from the content-addressed store, hash-verified

100}
101
102fn git2_oid_of(oid: &atomic_core::operation::GitObjectId) -> Result<git2::Oid, RepositoryError> {
103 git2::Oid::from_bytes(oid.as_bytes()).map_err(|error| RepositoryError::InvalidOperation {
104 message: format!("invalid Git OID: {error}"),
105 })
106}
107
108/// How the resurrection compared the recomputed projection to the binding.
109#[derive(Debug, Clone, PartialEq, Eq)]

Callers 1

Calls 1

as_bytesMethod · 0.45

Tested by

no test coverage detected