Interactive git log ( glo when using forgit) viewer with file previews for the command line, using forgit (powered by fzf)

-i/--interactive

ga : interactive git add selector

glo : interactive git log viewer

gi : interactive .gitignore generator

gd : interactive git diff viewer

grh : interactive interactive git reset HEAD <file> selector

gcf : interactive git checkout <file> selector

gss : interactive git stash viewer

gclean : interactive git clean selector

ga

~/.bashrc

~/.zshrc

git diff

git log

Enter : confirm

: confirm Tab : toggle mark

: toggle mark ? : toggle preview window

: toggle preview window Alt - W : toggle preview wrap

: toggle preview wrap Ctrl - S : toggle sort

: toggle sort Ctrl - R : toggle selection

: toggle selection Ctrl - K / P : selection move up

: selection move up Ctrl - J / N : selection move down

: selection move down Alt - K / P : preview move up

: preview move up Alt - J / N : preview move down

Installation

~/.forgit

git clone https://github.com/wfxr/forgit ~/.forgit

git pull

~/.forgit

~/.forgit/forgit.plugin.zsh

~/.bashrc

~/.zshrc

[ -f ~/.forgit/forgit.plugin.zsh ] && source ~/.forgit/forgit.plugin.zsh

.zsh

Bash:

source ~/.bashrc

Zsh

source ~/.zshrc

New to fzf? This is a command line fuzzy finder that can be used for a wide range of purposes. This interactive command line filter can be used with various lists, like files, command history, processes, hostnames, git commits, and more.fzf is very fast, it's portable with no dependencies (it's written in Go), it has a flexible layout, and includes various extra features like the ability to preview highlighted files in a split window inside fzf (which is what forgit uses for its previewing files), a Vim/Neovim plugin, a script for launching fzf in a tmux pane, key bindings and fuzzy auto-completion.git already has anoption, but forgit is more intuitive, makes uses of fzf's fast fuzzy search, and comes with extras like Vim key bindings.forgit provides the following commands:Here's a screenshot of the the git add command () provided by forgit:The commands provided by forgit are aliases that can be easily change if you wish, by defining them before sourcing forgit (e.g. in yourorfile) if you're not using a plugin manager. You may also add default fzf options to forgit so you can change the keybinds or layout. Check out the forgit documentation for more information.forgit also includes out of the box integration with some third party command line tools that provide various enhancements. Install diff-so-fancy (make your diffs human readable to help improve code quality and help you spot defects faster) or delta (a syntax-highlighting pager for git) to improve theoutput, bat (cat with syntax highlighting) to provide syntax highlighting for gitignore, and emoji-cli for supporting emoji inThese are the default forgit key bindings: fzf is available in the repositories for Fedora, openSUSE Tumbleweed, Debian Buster, Ubuntu 19.04 and newer, and Arch Linux. You may also download the fzf binary and install it somewhere in your path (like /usr/local/bin), use an install script or Homebrew/Linuxbrew. See the instructions from the fzf wiki for details on installing fzf, and all the available options.1. Clone the forgit repository in a hiddenfolder (you'll obviously need to have git installed on your system for this):Since we've cloned the forgit git repository, we can easily update it later with a simplein thedirectory.2. Next you'll need to sourcein your shell config.Openor(depending on what you're using) with a text editor and at the end of it (after sourcing fzf!), add the following:The forgit plugin is identical for both Zsh and Bash, that's why even though the file extension is, it works on both Zsh and Bash.3. Restart your shell or reload config fileTo reload your config file you can use: