how to change branch git lav code example
Example 1: how to switch branches in git
git checkout [branch name]
Example 2: sitch a branch command line
$ git switch <existing_branch>
$ git switch -c <non_existing_branch>
git checkout [branch name]
$ git switch <existing_branch>
$ git switch -c <non_existing_branch>