How to Use a TUI Git Client
A complete walkthrough setting up a terminal-based git interface — staging, committing, browsing history, and resolving conflicts visually, without leaving the keyboard or the terminal.
A TUI git client gives you a visual, navigable interface over git’s staging area, commit history, and branches — genuinely faster than composing individual git commands for common day-to-day operations, without leaving the terminal for a full graphical git GUI.
Step 1: choose a TUI git client
lazygit — extremely popular, highly visual, keyboard-driven
tig — text-mode interface, especially strong for
browsing history and diffs
lazygit tends toward a more complete, all-in-one interactive experience; tig leans toward being a fast, focused history/diff browser with lighter-weight staging support.
Step 2: install your chosen tool
# lazygit
brew install lazygit # macOS
sudo apt install lazygit # Debian/Ubuntu (check for a
# current version via the
# project's own install docs)
# tig
sudo apt install tig
brew install tig
Step 3: launch it inside a git repository
cd your-project
lazygit
TUI git clients operate on whatever git repository your current working directory belongs to — no separate configuration step needed to point it at a specific repo.
Step 4: stage and unstage files visually
lazygit: navigate to the "Files" panel →
press Space to stage/unstage a specific file →
press a to stage all
Seeing exactly which files are staged versus unstaged in a persistent visual panel, rather than repeatedly running git status, makes it considerably easier to build precisely the commit you intend.
Step 5: stage individual hunks within a file
lazygit: select a file → press Enter to view its diff →
navigate to a specific hunk → press Space to stage
just that hunk
Partial-file (hunk-level) staging — splitting unrelated changes in the same file into separate, logically coherent commits — is meaningfully easier to do correctly through a visual diff view than via git add -p’s line-by-line prompts alone.
Step 6: commit directly from the interface
lazygit: press c → type a commit message →
confirm
Step 7: browse commit history and diffs
lazygit: navigate to the "Commits" panel →
select any commit to view its full diff
tig: launches directly into a browsable
commit history view by default
Visually browsing history with immediately visible diffs is often faster for understanding “what actually changed and when” than piecing it together from git log and separate git show commands.
Step 8: manage branches visually
lazygit: navigate to the "Branches" panel →
create, checkout, merge, or delete branches
directly from the list
Step 9: resolve merge conflicts through the interface
lazygit: conflicted files are flagged specifically →
navigate into a conflict → select which side to
keep for each conflicting section
Resolving conflicts through a structured visual interface, rather than manually editing conflict markers in a plain text editor, reduces the chance of accidentally leaving a stray conflict marker in the final resolved file.
Why a TUI git client is worth learning alongside the git CLI directly
The git command line remains the right tool for scripting and for operations you want fully explicit control over — a TUI client’s real advantage is making the state of a repository (what’s staged, what’s changed, how history branches) immediately visible and directly manipulable, which is exactly the kind of task that’s awkward to do well through individually-typed commands alone.