pub async fn ref_hash(
repo_path: PathBuf,
reference: String,
) -> Result<String, GitError>Expand description
Re-exported commit/sync/diff APIs. Returns the full commit hash for a git reference.
§Arguments
repo_path- Path to the git repository or worktree.reference- Branch, tag, or commit-ish to resolve.
§Returns
The full commit hash as a string.
§Errors
Returns a GitError if the reference cannot be resolved to a commit.