how to switch to branch from master in git cmd code example Example 1: canging branch in git $ git checkout feature Example 2: canging branch in git $ git branch