FAQ: Git Branching - git branch 2

This community-built FAQ covers the “git branch 2” exercise from the lesson “Git Branching”.

Paths and Courses
This exercise can be found in the following Codecademy content:

Web Development

Learn Git

FAQs on the exercise git branch 2

There are currently no frequently asked questions associated with this exercise – that’s where you come in! You can contribute to this section by offering your own questions, answers, or clarifications on this exercise. Ask or answer a question by clicking reply (reply) below.

If you’ve had an “aha” moment about the concepts, formatting, syntax, or anything else with this exercise, consider sharing those insights! Teaching others and answering their questions is one of the best ways to learn and stay sharp.

Join the Discussion. Help a fellow learner on their journey.

Ask or answer a question about this exercise by clicking reply (reply) below!

Agree with a comment or answer? Like (like) to up-vote the contribution!

Need broader help or resources? Head here.

Looking for motivation to keep learning? Join our wider discussions.

Learn more about how to use this guide.

Found a bug? Report it!

Have a question about your account or billing? Reach out to our customer support team!

None of the above? Find out where to ask other questions here!

How do we view our branches?

Nevermind, git branch.

I can’t get past page 3? i do the git branch new_fencing but it is not working? does anyone know what it is?

how do we get past page 3?? i put in the code correctly but it keeps saying i did not name it fencing, but I did! HELP!!!

1 Like

I have the same problem and I can not move forward and I tried everything is very frstante al guien who can help please ¡¡¡¡¡¡¡

Im having trouble how were you able to resolve the problem?

were you able to solve the problem? Im stuck also.

Stuck on page 3? Type, “git branch fencing” without the quotations. I was stuck for an entire day and that’s the only thing that worked.

2 Likes

Thank you so much I had been stuck on this problem for a while lol. Thanks again.

Hi guys, what does -M mean in the following code:
git branch -M main

same problem in 2023

“git branch fencing” is correct sentence. If you have stuck even typed this, just refresh the browser. It work for me!

I will explain how to get rid of this problem, in steps:

  1. make sure you delete the branches you created
    use the command git branch --delete 'here you put your branch that you want to delete ’ no quotes
  2. after you delete the extra branch make sure you have only 2 branches created, master and fencing
  3. make sure you are on the right branch, sometimes you moved by mistake on the wrong branch, you need to be on the master branch. To move on the master branch type git checkout master

your code should look like this
git branch
fencing

  • master <------the star should be on master

Hope this helps everyone, have a nice day!

it is not working
i tried this code also but problem is the same