Branches Review

If your repository has dozens of branches, you will appreciate the "Branches Review" view, accessible in the "Workspace" section in the sidebar. You can also open it via View → Show Branches Review or by pressing CTRL + 6.

By comparing your local branches to a base branch of your choice, this view will help you identify which branches have been stale or become obsolete, so that you can clean up your Git repository with confidence.

The Branches Review view comparing all local branches to the "develop" branch

Choose the base branch using the "Compare local branches to" drop-down at the top of the view. When comparing, you can find your branches in three possible states:

  • The green checkmark means that you can safely merge this branch without any conflicts.
  • The yellow warning icon means that you will encounter merge conflicts when merging the branch.
  • The grey merge icon means that the branch has been fully merged.

For each branch, unpushed / unpulled commit indicators will show you by how many commits the branch is ahead or behind, in relation to the branch you are comparing them to. You'll also see the branch's remote tracking branch (highlighted in red if it no longer exists on the remote) and when it was last updated.

In case of branches that have merge conflicts, selecting these branches will show you more information. Click the warning badge next to the branch names to see which files would be in conflict.

A branch with merge conflicts selected in Branches Review, with a popover listing the conflicted files

Filtering The Branch List

The filter menu in Branches Review with options for Active, Stale, Fully Merged, Mergeable, Merge Conflicts, Tracking Error, and Pull Requests

Using the buttons in the top-right corner of the view, you can sort branches by name or by the date they were last updated. You can also filter your list of branches by many parameters, such as:

  • Active or Stale
  • Fully Merged, Mergeable, or with Merge Conflicts
  • With or without Pull Requests
  • With Tracking Errors

Finding Cleanup Candidates Combining filters gives you an instant cleanup list: stale branches that are fully merged and have no open pull request are usually a very safe place to start.

Automatic Branch Management Once you've identified stale and fully merged branches, Tower can help you keep your repository organized with automatic branch management. This feature continuously monitors your branches and provides tools to archive them, keeping your sidebar clean while preserving branches for future reference.