Forrest logo
back to the tig tool


tig: Show the sequence of commits starting from the current one in reverse chronological order.
$ tig
try on your machine

The "tig" command is a text-mode interface for Git, a widely used distributed version control system. It provides a visual representation of the commit history and helps users navigate through branches, commits, and other Git objects.

When you run the "tig" command in your terminal, it opens a TUI (Text User Interface) window displaying various sections. These sections generally include the commit graph, a list of branches, file changes, and a diff view.

The commit graph shows the commit history as a vertical line of nodes, with branches and merges represented by lines connecting the nodes. You can move up and down the graph to explore different commits and their relationships.

The branch list displays all the branches in your repository. You can switch between branches, create new branches, delete branches, or merge branches through this section.

The file changes section shows the modifications made to files in the selected commit or branch. You can navigate through files, view changes, and even stage or discard modifications using keyboard shortcuts.

The diff view allows you to compare file changes between different commits or versions. It highlights the added, modified, or deleted lines, enabling you to understand the differences easily.

Apart from these main sections, "tig" also provides various keyboard shortcuts and commands for performing actions like staging changes, browsing commit history, searching for specific commits or files, and more.

Overall, "tig" makes it convenient to interact with Git repositories and helps users visualize, browse, and manage their commits and branches in a text-mode interface.

This explanation was created by an AI. In most cases those are correct. But please always be careful and never run a command you are not sure if it is safe.
back to the tig tool