Skip to contents
  • git_commit_stats() returns information about commit insertion and deletion

  • git_commit_info() a list of commit info

  • git_commit_id() is a shortcut for git_commit_info()$id

  • git_log() shows the most recent commits

  • git_ls() lists all the files that are being tracked in the repository.

  • git_stat_files() shows information of when files was last modified.

Usage

git_commit_info(ref = "HEAD", repo = ".")

git_commit_id(ref = "HEAD", repo = ".")

git_commit_stats(ref = "HEAD", repo = ".")

git_log(ref = "HEAD", max = 100, after = NULL, path = NULL, repo = ".")

git_stat_files(files, ref = "HEAD", max = NULL, repo = ".")

Arguments

ref

revision string with a branch/tag/commit value

repo

The path to the git repository. If the directory is not a repository, parent directories are considered (see git_find()). To disable this search, provide the filepath protected with I(). When using this parameter, always explicitly call by name (i.e. repo = ) because future versions of gert may have additional parameters.

max

lookup at most latest n parent commits

after

date or timestamp: only include commits starting this date

path

character vector with paths to filter on; only commits that touch these paths are included

files

vector of paths relative to the git root directory. Use "." to stage all changed files.

Value

  • git_commit_info() and git_commit_stats() return a list.