Viewing branches in Git

Viewing branches in Git 1

when we create multiple branches and sub-branches of our code .we should able to see all the branches before switching we use git branch parameter

we can check merged, unmerged, local all other branches by providing a specific parameters

the current branch has an * (asterisk ) before its name in the git output

View all local branches

 git branch 

View all remote-tracking branches and local branches

git branch -a

View only remote-tracking branches

git branch -r

List merged branches

git branch --merged

List only non-merged branches

git branch --no-merged
Default image
Vishal Devxo
Vishal Devxo is a DevOps engineer and a Backend developer, he spends all his time for creating good tutorials with better visuals and blogging, developed some projects based on Python-Django, some hacking modules and scripts in python