Git Tips Slides
PageUp x2: previous · PageDown x2: next · Home: index

gitk

gitk is the native GUI for browsing Git history.

I do not use it often, but if you want a quick graphical overview, it is practical and usually good enough.

Common usages:

# Usual default: show all local branches, remote-tracking branches, and tags
gitk --all

# Focus on a few branches only
gitk main my-feature-branch

# Inspect the history of one file across all branches
gitk --all -- path/to/file

I think --all makes sense in most repos. Without it, gitk only shows the history reachable from the current branch, which is often too narrow.

The exception is a huge repo: then --all can become noisy or slow, and it is better to limit by date, branch, or path.