Create, list, and checkout branches.

git_branch_list(repo = ".")

git_branch_checkout(branch, force = FALSE, repo = ".")

git_branch_create(name, ref = "HEAD", checkout = TRUE, repo = ".")

git_branch_delete(name, repo = ".")

git_branch_fast_forward(ref, repo = ".")

git_branch_set_upstream(remote = "origin", repo = ".")

Arguments

repo

a path to an existing repository, or a git_repository object as returned by git_open, git_init or git_clone.

branch

name of branch to check out

force

ignore conflicts and overwrite modified files

name

string with name of the branch / tag / etc

ref

string with a branch/tag/commit

checkout

move HEAD to the newly created branch

remote

name of existing remote from git_remote_list

See also