Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialJoyce Chidiadi
1,867 Pointsgit pull practice questions
I am adding my repository to the remote as this: git pull origin tommy
2 Answers
Joyce Chidiadi
1,867 PointsThank you, Jacob.
Jacob Mishkin
23,118 Pointsgenerally, a pull is a fetch and a merge. * git pull origin master
fetches commits from the master branch of the origin remote (into the local origin/master branch), and then it merges origin/master into the branch you currently have checked out.
is your master branch named tommy? Most times the master or main branch is called master by default. if you want to change the name from master to tommy here is how:
git checkout -b tommy master # create and switch to the tommy branch
git push -u origin tommy # push the tommy branch to the remote and track it
git branch -d master # delete local master
git push --delete origin master # delete remote master
git remote prune origin # delete the remote tracking branch
I would stick with a branch called master, that way its easier to understand the branches, and not get confused later on. Most people have two branches, master and develop. that way you know what you have been building and what is the original.