create new branch git and checkout code example
Example 1: git create new branch
// Example for creating a new branch named myNewBranch
git checkout -b myNewBranch
// First Push
git push --set-upstream origin myNewBranch
Example 2: creating new branch in git
Create a new branch named issue1.
$ git branch testing
Example 3: git create and checkout branch
$ git branch <branch_name>
$ git checkout <branch_name>