% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/commit.R
\name{git_history}
\alias{git_history}
\alias{git_commit_info}
\alias{git_commit_id}
\alias{git_commit_stats}
\alias{git_log}
\alias{git_stat_files}
\title{View commit history}
\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{
\item{ref}{revision string with a branch/tag/commit value}

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

\item{max}{lookup at most latest n parent commits}

\item{after}{date or timestamp: only include commits starting this date}

\item{path}{character vector with paths to filter on; only commits that
touch these paths are included}

\item{files}{vector of paths relative to the git root directory.
Use \code{"."} to stage all changed files.}
}
\value{
\itemize{
\item \code{git_commit_info()} and \code{git_commit_stats()} return a list.
}
}
\description{
\itemize{
\item \code{git_commit_stats()} returns information about commit insertion and deletion
\item \code{git_commit_info()} a list of commit info
\item \code{git_commit_id()} is a shortcut for \code{git_commit_info()$id}
\item \code{git_log()} shows the most recent commits
\item \code{git_ls()} lists all the files that are being tracked in the repository.
\item \code{git_stat_files()} shows information of when \code{files} was last modified.
}
}
\seealso{
Other git:
\code{\link{git_archive}},
\code{\link[=git_branch]{git_branch()}},
\code{\link[=git_commit]{git_commit()}},
\code{\link[=git_config]{git_config()}},
\code{\link[=git_diff]{git_diff()}},
\code{\link[=git_fetch]{git_fetch()}},
\code{\link{git_ignore}},
\code{\link[=git_merge]{git_merge()}},
\code{\link[=git_rebase]{git_rebase()}},
\code{\link{git_remote}},
\code{\link{git_repo}},
\code{\link[=git_reset]{git_reset()}},
\code{\link[=git_restore]{git_restore()}},
\code{\link[=git_revert]{git_revert()}},
\code{\link[=git_signature]{git_signature()}},
\code{\link{git_stash}},
\code{\link{git_tag}},
\code{\link{git_worktree}}
}
\concept{git}
\section{Related libgit2 documentation}{\href{https://libgit2.org/docs/reference/main/commit/index.html}{\code{commit}}.}

