git_branch_name

Get the branch name

Given a reference object, this will check that it really is a branch (ie. it lives under "refs/heads/" or "refs/remotes/"), and return the branch part of it.

@param out_ Pointer to the abbreviated reference name. Owned by ref, do not free.

@param ref A reference object, ideally pointing to a branch

@return 0 on success; GIT_EINVALID if the reference isn't either a local or remote branch, otherwise an error code.

extern (C) nothrow @nogc
int
git_branch_name
(
const(char)** out_
,)

Meta