Common utility commands for Git repositories. abort Abort current git operation. add-submodule Add submodule to repository. add-username-remote Adds a remote for the current repository for the given GitHub us ername. alias Define, search and show aliases. amend-push-submodules Amend current changes and push all submodules. amend-push Amend current changes and push (inc. submodules). apush-submodules Amend current changes and push all submodules. apush Amend current changes and push (inc. submodules). archive-file Export the current HEAD of the git repository to an archive. attic Displays a list of deleted files in your repository. The output is designed to be copy and pasted Pass the second field to git s how to display the file contents, or just select the hash withou t to see the commit where removal happened. authors Generate authors report. basename Get name of repository from URL. big-file Show files in the repository larger than a threshold size. branch-name Prints the current branch name in automation-friendly format. branch-rebaser Kicks off an interactive rebase of all the commits on your branc h. _Including pushed commits_, so be careful. branches-that-touch Shows which branches touch files under a path that are remote, u nmerged, have a commit in the last six months and whose name doe sn't start with 'enterprise-'. branches ## Source: git-extra-commands browse View the web page for the current repository. brv List branches sorted by their last commit date. bulk Run git commands on multiple repositories. change-author Change one author/email in the history to another. changelog Generate a changelog report. changes Symlink to git-authors. List authors in the repository in descen ding commit-count order. checkout-by-date Lets you checkout several files at once at the version specified by a date. checkout-commit Uses fzf(https//github.com/junegunn/fzf) to checkout a commit, s howing the commit diff as preview. checkout-default-branch Checks out the default branch of the origin remote so you don't have to remember which repositories use master, main or whatever . checkout-pr Check out a PR locally. checkout-preview Uses fzf(https//github.com/junegunn/fzf) to checkout a branch, s howing what commits diverge between the branches. children-of Shows the children of a given git commit. churn Show which files are getting changed most often in the repositor y. clear-soft Soft clean up a repository. clear Rigorously clean up a repository. clone-init-submodules Clone repository to local (inc. submodules). clone-subset Uses git clone and git filter-branch to remove from the clone al l files but the ones requested, along with their associated comm it history. coauthor Add a co-author to the last commit. comma Adds and commits a file in one command. commit-browser Uses fzf(https//github.com/junegunn/fzf) to browse commit histor y. commit-count ## Source: git-extra-commands commit-push-submodules Commit current changes and push all submodules. commit-push Commit current changes and push (inc. submodules). commits-per-day ## Source: git-extra-commands commits-since Show commit logs since some date. compact ## Source: git-extra-commands conflicts Show files with conflicts. contrib Show user's contributions. copy-branch-name Copy the current branch's name to the clipboard (macOS Only). count Show commit count. cp Copy a file keeping its history. cpush-submodules Commit current changes and push all submodules. cpush Commit current changes and push (inc. submodules). create-branch Create branches. credit Quicker way to assign credit to another author on the latest com mit. current-branch Prints the name of the current branch with no odd characters or formatting, mainly useful in automation scripts. cut-branch Create a new branch pointed at **HEAD** and reset the current br anch to the head of its tracking branch. default-branch Get default branch (local) of repository. delete-branch Delete branches. delete-dangling-commits Clean up dangling commits that are not on any branch. delete-local-merged Delete all local branches that have been merged into **HEAD**. delete-merged-branches Delete merged branches. delete-squashed-and-merged-branches Purges all branches that have been squashed and merged to a targ et branch (defaults to branches merged to master). Requires pygi thub. delete-squashed-branches Delete branches that were squashed. delete-submodule Delete submodules. delete-tag Delete tags. delta Lists changed files. diff-last Show the last change made to a file in the repository. divergence Shows differences between local branch and its tracking branch. edit-conflicts Edit the files that are marked as conflicted during a merge/reba se in your EDITOR/VISUAL. effort Show effort statistics on file(s). feature Create/Merge feature branch. fetch-prs Get all Pull Request branches as local remote branches by refspe c. files List the files different between the current branch and REVIEW_B RANCH, which if unset defaults to the repository's default branc h. find-dirty . flush Compact your repository by dropping all reflogs, stashes, and ot her cruft that may be bloating your pack files. force-clone overwrite local repositories with clone. force-mtimes Sets modification times of all files in the repository their las t change date based on git's log. Useful to avoid too new dates after a checkout confusing make or rake. forest Prints a text-based tree visualisation of your repository. Requi res Git.pm(https//metacpan.org/release/Git). fork Fork a repo on github. fresh-branch Create fresh branches. fullurl Get full URL of repository from partial. functionlog Allows you to get a git log of a particular function, not a file . fzf-add Use fzf(https//github.com/junegunn/fzf) to select files to add t o git. fzf-log-browser Use fzf(https//github.com/junegunn/fzf) to browse the repository 's git log. fzf-pickaxe-browser Use fzf(https//github.com/junegunn/fzf) to display a git log lis t that has been filtered with pickaxe(http//www.philandstuff.com /2014/02/09/git-pickaxe.html) for a search term. fzf-reflog-browser Use fzf(https//github.com/junegunn/fzf) to browse the repository 's git reflog list that can be filtered by entering a fuzzy term at the prompt. Navigation up and down the hash list will previe w the changes of each hash. gh-pages Create the GitHub Pages branch. git Typing git git foo will make git do a git foo instead of complai ning. github-open ## . gitlab-mr Open a merge request on GitLab. graft Merge and destroy a given branch. guilt calculate change between two revisions. help Print usage details of a command. history-eraser ## Source: git-extra-commands history-graph Pretty git log, single line per commit, with branch graphing. ignore-io Get sample gitignore file. ignore Add .gitignore patterns. ignored Show files being ignored by git in the repository. improved-merge Sophisticated git merge with integrated CI check and automatic c leanup. incoming Show commits in the tracking branch that are not in the local br anch. info Returns information on current repository. init-submodules Initialize all submodules. lines Gives you a list of author names with the number of lines last u pdated by that user in files in the current directory tree with the extension specified. local-commits List local commits. lock Lock a file excluded from version control. locked ls files that have been locked. ls-branch-files List files changed between a specified branch and the current br anch. ls-conflicts ## Source: git-extra-commands ls-object-refs Find references to an object with SHA1 in refs, commits, and tre es. All of them. magic Automate add/commit/push routines. mark-all-resolved ## Source: git-extra-commands maxpack Compress a repository's pack files as much as possible. merge-into Merge one branch into another. merge-repo Merge two repo histories. missing Show commits missing from another branch. move-commits git move-commits num-commits correct-branch moves the last n com mits to correct-branch (creating it if necessary). mr Checks out a merge request locally. name Get name of repository from URL. neck Show commits from the HEAD until the first branching point. Comp anion script for git-trail. nuke-untracked-files ## Source: git-extra-commands nuke Nukes a branch locally and on the origin remote. object-deflate Deflate an loose object file and write to standard output. obliterate rewrite past commits to remove some files. oldest-common-ancestor Finds the oldest common ancestor commit between two branches. origin-head Prints the name of the origin remote's default branch. Not every repository uses main or master. outgoing Show commits that are on the local branch that have not been pus hed to the tracking branch. overwritten Aggregates git blame information about original owners of lines changed or removed in the 'base...head' diff. paste Send patches to pastebin for chat conversations. pie-ify git pie-ify pattern replacement. plotrepo Uses dot to draw a graph of the repository. pr Checks out a pull request locally. promote Promotes a local topic branch to a remote tracking branch of the same name. prune-branches Deletes each fully merged branch after prompting for confirmatio n, than asks if you want the deleted branches deleted from your upstream remotes. pruneall Prune branches from specified remotes, or all remotes when no re mote is specified. psykorebase Rebase a branch with a merge commit. publish git publish remote remote-branch. pull-request Create pull request for GitHub project. purge-from-history Permanently delete files or folders from your git repository. pylint Runs pylint on any .py files modified or added in the git status output. rank-contributors Rummages through the changelog and orders contributors by the si ze of the diffs they're responsible for. reauthor Rewrite history to change author's identity. rebase-authors Adds authorship info to interactive git rebase output. rebase-patch Rebases a patch. rebase-theirs Resolve rebase conflicts by favoring 'theirs' version. rebase-work-in-progress ## Source: git-extra-commands recent Shows information about most recent commit on all local branches . recently-checkedout-branches Shows timestamp and name of recently checked-out branches in rev erse chronological order. ref-recent Shows the date, branch name, commit hash, and commit subject of branches, from most recently modified to oldest branches. rel Shows the relationship between the current branch and _ref_. Wit h no _ref_, the current branch's remote tracking branch is used. related Show other files that often get changed in commits that touch fi le. release Commit, tag and push changes to the repository. remote-default-branch Shows the default branch for a specified remote, defaults to ori gin when no remote is specified. rename-branch rename local branch and push to remote. rename-branches Rename multiple branches that start with a given name. rename-remote Rename a remote. rename-tag Rename a tag. repl git read-eval-print-loop. reset-file Reset one file. reset-with-fire Hard reset the working directory, then zap any files not known t o git. restore-mtime Change mtime of files based on commit date of last change. reup Like git pull but show a short and sexy log of changes after mer ging or rebasing. rm-deleted-from-repo Removes files you deleted with rm from the repository for you. root-directory Prints the path to the root of the git repository you're in. root show path of root. roots Show the root commits. rscp ## Source: git-extras run-command-on-revisions Runs a given command over a range of git revisions. scp Copy files to SSH compatible git-remote. sed replace patterns in git-controlled files. setup Set up a git repository. shamend Amends your staged changes as a fixup (keeping the pre-existing commit message) to the specified commit, or HEAD if no revision is specified. show-merged-branches Show merged branches. show-overwritten Aggregates git blame information about the original owners of li nes changed or removed in the 'base...head' diff. show-tree show branch tree of commit history. show-unmerged-branches Show unmerged branches. shrink-repo Shrinks your clone of a git repository. sp Simple push, single short command to commit, and push. Use -a fl ag to add all files to commit. squash squash N last changes up to a ref'ed commit. sr Use fzf to switch to a different git ref. stamp Stamp the last commit message. standup Recall the commit history. stashes ## Source: git-extra-commands stats Displays stats for the files different between the current branc h and REVIEW_BRANCH, which if unset defaults to the repository's default branch. submodule-rm Allows you to remove a submodule easily with git submodule-rm pa th/to/submodule. summary Show repository summary. switch-branch Make it easier to switch to a branch by a substring of its name. More useful if you are good about deleting branches which have been merged upstream and if your branch names include unique ide ntifiers like ticket/issue numbers or feature names. sync Sync local branch with remote branch. tag-and-sign Create and sign a new tag. tag-diff Show the differences between local tags and ones on the remote, if any. taglist ## Source: git-extra-commands tags ## Source: git-extra-commands thanks List the contributors to a repository in descending commit order , even if their contribution has been completely replaced. touch Touch and add file to the index. track Sets up your branch to track a remote branch. Assumes you mean _ origin/localbranchname_. trail Show all branching points in the repository's git history so you can see how to reach commits in the current branch from other b ranches. undelete Undeletes a file. undo-push Undoes your last push to branch **1** of origin. undo Remove latest commits. unlock Unlock a file excluded from version control. unpushed-stat ## Source: git-extra-commands unpushed Show which commits have not been pushed to the tracking branch a nd are safe to amend/rebase. unreleased Shows git commits since the last tagged version. up-old ## Source: git-extra-commands up Like git pull but show a short and sexy log of changes after mer ging or rebasing. upstream-sync Fetches _upstream/yourforkname_ and rebases it into your local f ork, then pushes to your origin remote. url Get full URL of repository from partial. utimes Change files modification time to their last commit date. what-the-hell-just-happened Show what just happened. when-merged Find when a commit was merged into one or more branches. where Shows where a particular commit falls between releases. whoami Shows what username email you have configured for the repositor y you're in. winner Shows what authors have made the most commits, both by number of commits and by number of lines changed. wordiness Shows how wordy people's commit messages are. Useful for shaming the folks who commit atrocities like git commit -m fixup. wtf git-wtf displays the state of your repository in a readable, eas y-to-scan format. It's useful for getting a summary of how a bra nch relates to a remote server, and for wrangling many topic bra nches. xclone Clone repository to local (inc. submodules). If you need command details, use `egit help `. Or else see https://github.com/nodef/extra-git.