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

Method has_git_sha

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

Check if a Git SHA has been indexed.

(&self, git_sha: &str)

Source from the content-addressed store, hash-verified

3840
3841 /// Check if a Git SHA has been indexed.
3842 pub fn has_git_sha(&self, git_sha: &str) -> Result<bool, RepositoryError> {
3843 use atomic_core::pristine::GitShaIndexTxnT;
3844
3845 let txn = self
3846 .pristine
3847 .read_txn()
3848 .map_err(|e| RepositoryError::Database(e.to_string()))?;
3849
3850 txn.has_git_sha(git_sha)
3851 .map_err(|e| RepositoryError::Database(e.to_string()))
3852 }
3853
3854 /// List indexed Git SHAs without loading historical change objects.
3855 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