tig
Browse Git repository history in a TUI
TLDR
Show the sequence of commits starting from the current one in reverse chronological order
Show the history of a specific branch
Show the history of specific files or directories
Show the difference between two references (such as branches or tags)
Display commits from all branches and stashes
Start in stash view, displaying all saved stashes
Display help in TUI
SYNOPSIS
tig [options] [command]
PARAMETERS
-h, --help
Show help message and exit.
-v, --version
Show version information and exit.
-c file, --config file
Use specified configuration file.
-l log-options, --log-options log-options
Pass options to the underlying 'git log' command (only for tig main view).
-w, --width width
Set terminal width.
-H, --height height
Set terminal height.
--no-mouse
Disable mouse support.
--only- Patches
Shows only the files that were patched (files that were changed in this commit).
DESCRIPTION
Tig is a text-mode interface for Git, designed to function as a Git repository browser. It allows users to navigate through commits, diffs, and the staging area in a terminal-based environment. It provides a user-friendly interface to explore and understand Git repositories without relying on complex command-line arguments. Tig supports features like interactive staging, commit viewing, branch browsing, and diff inspection. It's particularly useful for developers who prefer a terminal-centric workflow but want a more intuitive way to interact with Git repositories than the standard Git commands offer. Tig displays the history of the code changes, displaying commit messages, diffs, and file contents.
KEY BINDINGS
Tig has various key bindings for navigation and actions. Common key bindings include:
- j/k: Scroll down/up.
- Enter: View details (e.g., diff of a commit).
- q: Quit.
- /: Search.
CONFIGURATION
Tig's behavior can be customized through a configuration file, typically located at ~/.tigrc. This file allows users to define key bindings, colors, and other preferences.
HISTORY
Tig was created to provide a more interactive and user-friendly interface to Git than the standard command-line tools. It was developed to address the need for easier navigation and exploration of Git repositories within a terminal environment. Its usage has grown among developers who appreciate a terminal-centric workflow but desire improved usability for common Git tasks.