libgit2

git_repository_head

Version:

Retrieve and resolve the reference pointed at by HEAD.

Signature

int git_repository_head(git_reference **head_out, git_repository *repo);

Parameters

In
head_out

pointer to the reference which will be retrieved

In
repo

a repository object

Returns

int

0 on success; error code otherwise

Versions