Focus and filter the graph
In a busy repository, Focus on Current Branch shows just your branch, its upstream and its base, with how many commits it has since the base. Filter Graph… keeps the commits of an author, a date range or a path. Filtering never deletes history; Clear Graph Filter brings every row back.
Works in GitTree Free: every local Git feature, once you are signed in.
On this page
Before you start
- A repository is open.
Where to find it
- The command palette: Focus on Current Branch, Filter Graph… and Clear Graph Filter.
- Right-click a branch label: Show Only This Branch or Focus on This Branch; on a tag, Show Only This in Graph.
| Action | macOS | Windows and Linux |
|---|---|---|
| Focus on Current Branch | ⌘⇧B | Ctrl+Shift+B |
| Jump to HEAD | ⌘⇧H | Ctrl+Shift+H |
Steps
Focus on your branch
Press the shortcut or run Focus on Current Branch. The graph keeps your branch, its upstream and its base branch, and says how many commits your branch has since the base.
Or filter by author, date or path
Run Filter Graph…. Fill in Author name or email contains, From and To, or Touches path (such as
src/orREADME.md), and choose where to Start from.Read the filter bar
A bar above the graph says Filtered: and what is filtered. Only matching commits are shown.
Clear it
Choose Clear Graph Filter in the bar or the palette. Every row comes back.
Expected result
The graph shows just the part of the history you are working on.
The base branch
Focus compares your branch with its base: the repository’s base, origin’s default branch, or main. Choose Choose Base… to pick another; Compare against base branch in Filter Graph sets it too.
If something goes wrong
“No commits match this filter.”
Loosen it: check the author’s spelling or widen the dates.
“… share no history”
The branch and its base have no commit in common, so there is nothing to count. Choose another base.
Questions
Does the filter change the search?
Search finds commits among the rows the graph shows; clear the filter to search the whole history.