Function get_ahead_behind
Source pub async fn get_ahead_behind(
repo_path: PathBuf,
) -> Result<(u32, u32), GitError>
Expand description
Re-exported commit/sync/diff APIs.
Returns the number of commits ahead and behind the upstream branch.
§Arguments
repo_path - Path to the git repository root
§Returns
Ok((ahead, behind)) on success.
§Errors
Returns a GitError if git rev-list fails or returns unexpected
output.