user3086199
user3086199

Reputation: 1

How to get all commits with a Fork

Im trying to make a copy of a repo I have access to. However when I fork it to my own account not all the latest changes come. For example the original has 840 commits and 7 contributors and my fork has only 733 and 4 contributors. Also the read me file is not updated.

How can I get a complete copy of all the changes/updates, etc?

(I am a newbie so I need very basic and simple instructions.)

Upvotes: 0

Views: 1048

Answers (1)

Kyle Boon
Kyle Boon

Reputation: 5231

When you fork a repository it will only include the master branch by default. If you want the other branches the easiest thing to do is clone the forked copy to your workspace then add the original repository as a new remote. I usually do the following:

git remote add upstream url-to-original-repository
git fetch --all
git branch -a

That will list all the branches and you can checkout any of the upstream branches that are interesting.

Upvotes: 1

Related Questions