a git repository has several branches. Each branch follows a development line, and it has its origin in another branch at some point in time (except for the first branch, usually called master
), which starts as the default branch until someone changes, which almost never happens)
If you are new to git, remember these 2 basics. Now you just need to clone the repository, and it will be in some branch. if the branch is the one you are looking for, amazing. If not, you just need to switch to another branch - this is called checkout. Just type git checkout <branch-name>
In some cases, you want to receive updates for a particular branch. Just do git pull origin <branch-name>
and it will โloadโ new commits (changes). If you have not made any changes, this should be easy. If you also make changes to these branches, conflicts can occur. let me know if you need more information on this case.
source share