commit {gitr} | R Documentation |
Git Commit Utilities
Description
Git Commit Utilities
Usage
gitr_commit_msgs(sha = NULL, n = 1L)
scrape_commits(n)
gitr_unstage(file = NULL)
gitr_reset_soft(n = 1L)
gitr_uncommit()
gitr_reset_hard()
gitr_diff_commits(top = 1L, n = 2L)
Arguments
sha |
|
n |
|
file |
|
top |
|
Value
NULL
... invisibly.
A list containing commit message entries.
The sha
and author
of each commit is added as attributes.
Functions
-
gitr_commit_msgs()
: gets the commit messages corresponding to the commitsha
.sha
can becharacter(n)
, but must be valid SHAs corresponding to commits in the repository. -
scrape_commits()
: scrapesn
commit messages for useful change log commits to be used to create aNEWS.md
. -
gitr_unstage()
: un-stages a file from the index to the working directory. Default un-stages all files. -
gitr_reset_soft()
: un-commits the most recently committed file(s) and add them to the staging area. -
gitr_uncommit()
: un-commits the most recently committed file(s) and add them to the staging area. Wrapper aroundgitr_reset_soft()
-
gitr_reset_hard()
:git reset --hard origin/<branch>
. -
gitr_diff_commits()
: gets the diff of the corresponding 2 commits. Order matters!
Examples
## Not run:
gitr_commit_msgs()
gitr_commit_msgs(n = 3)
## End(Not run)