Right now, the Git project has only one branch: master.

To create a new branch, use:

git branch new_branch

Here new_branch would be the name of the new branch you create, like photos or blurb. Be sure to name your branch something that describes the purpose of the branch. Also, branch names can’t contain whitespaces: new-branch and new_branch are valid branch names, but new branch is not.



Let’s create a new version of a resumé to apply for a fencing instructor role.

Create a new branch called fencing.

Remember to spell the word “fencing” correctly.

Next, view your branches as you did in the previous exercise.

Notice in the output there now appear two branches: master and fencing.

Sign up to start coding

By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.
Already have an account?