Theme 1 – Configure Git to sort branches by committer date (newest first)
Many users set a global or repo‑level config so git branch lists the most recently worked‑on branches at the top.
- “Even better (IMHO!) is git config branch.sort -committerdate (note the -).” — asb
- “I have this as an alias in my .zshrc!! Very handy.” — pkaodev
- “git config --global branch.sort -committerdate.” — mmsc
Theme 2 – The sorting helps when juggling many active branches
Developers working across dozens (or even thousands) of branches find the recency order invaluable for spotting active work and stale branches.
- “At any time I'm working across 5‑30 branches … so it's handy to see my latest branches.” — jamietanna
- “I've seen monorepos with over 10k active branches. But even at a smaller scale (10‑100 branches), it becomes useful when manually stacking and/or rebasing.” — woodruffw
- “Our team's git branch output is a graveyard. Sorting by last commit would be a godsend for quickly identifying active work and stale branches.” — dalton74
Theme 3 – Enhance the list with fuzzy finders or helper tools
Piping the sorted output to fzf or using utilities like git‑recent lets users interactively pick a branch, often showing commit metadata.
- “I love this little fzf bash function … It opens a fuzzy finder window showing the branches … sorted by recency.” — tomtom1337
- “Huge fan of git recent … Spoiler it’s fzf under the hood. But it’s perfect and simple.” — metmac
- “The best upgrade to these kinds of git branch scripts is piping them to fzf.” — jbranchaud