reposcry-cache 0.1.0

SQLite cache layer for RepoScry code graph indexing and AI-agent workflows.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::path::Path;

pub struct FileHasher;

impl FileHasher {
    pub fn hash_file(path: &Path) -> anyhow::Result<String> {
        let data = std::fs::read(path)?;
        Ok(blake3::hash(&data).to_hex().to_string())
    }

    pub fn hash_bytes(data: &[u8]) -> String {
        blake3::hash(data).to_hex().to_string()
    }
}