How can I switch to another branch in git?

If another_branch already exists locally and you are not on this branch, then git checkout another_branch switches to the branch. If another_branch does not exist but origin/another_branch does, then git checkout another_branch is equivalent to git checkout -b another_branch origin/another_branch; git branch -u origin/another_branch. That’s to create another_branch from origin/another_branch and set origin/another_branch as the … Read more

What is git tag, How to create tags & How to checkout git remote tag(s)

Let’s start by explaining what a tag in git is A tag is used to label and mark a specific commit in the history.It is usually used to mark release points (eg. v1.0, etc.). Although a tag may appear similar to a branch, a tag, however, does not change. It points directly to a specific commit in the history and will not … Read more