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

Method has_git_sha

atomic-repository/src/repository/insert.rs:3764–3774  ·  view source on GitHub ↗

Check if a Git SHA has been indexed.

(&self, git_sha: &str)

Source from the content-addressed store, hash-verified

3762
3763 /// Check if a Git SHA has been indexed.
3764 pub fn has_git_sha(&self, git_sha: &str) -> Result<bool, RepositoryError> {
3765 use atomic_core::pristine::GitShaIndexTxnT;
3766
3767 let txn = self
3768 .pristine
3769 .read_txn()
3770 .map_err(|e| RepositoryError::Database(e.to_string()))?;
3771
3772 txn.has_git_sha(git_sha)
3773 .map_err(|e| RepositoryError::Database(e.to_string()))
3774 }
3775
3776 /// List indexed Git SHAs without loading historical change objects.
3777 pub fn indexed_git_shas(&self) -> Result<Vec<String>, RepositoryError> {

Callers 2

index_git_shasMethod · 0.45

Calls 1

read_txnMethod · 0.80

Tested by

no test coverage detected