git show-ref --heads

Category: Git - Core

git show-ref --heads

List all local branch refs

Prints every local branch as a full hash plus refs/heads/name pair. It is the plumbing-level view of what git branch shows. Add --tags to include tags, or no flag to list every ref in the repository.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.