See all branches in local repository
git branch
# asterisk notifies you which branch you are on now
Create a branch called hot_fix
git branch hot_fix
Switch to the branch called hot_fix
git checkout hot_fix
# verify you are now on the hot_fix branch
git branch
Compare 2 branches
git diff master..hot_fix
Rename branch hot_fix to hot_fix_Bug5638
git branch -m hot_fix hot_fix_Bug5638
Delete a branch
git branch -d branch_name
Delete a branch with commits that isn’t merged yet
git branch -D branch_name
Merge hot_fix branch into master branch
# Check differences
git diff master..hot_fix
# Change to the master branch
git checkout master
# Merge changes
git merge hot_fix