Tag: git

Total 21 Posts

Git: Merge Branch into Master

One of Git's most powerful features is the ability to easily create and merge branches. Git's distributed nature encourages users to create new branches often and to merge them regularly as a part of the development process. This fundamentally improves the development workflow for most projects by encouraging smaller, more

Continue Reading

Git: Push Tags to a Remote Repo

If you've been using Git for any significant amount of time then you probably already know how to push your commits from a local branch to a remote repository. But, as you may be aware, Git doesn't just track commits, there are other objects/references as well, like tags.


Continue Reading

Git: Change Remote Repo URL

While I had initially thought that it's very rare for a remote repository to change location, it actually happens a lot more than I realized. A remote repo may change from one private server to another (like a NAS), from a personal GitHub repo to one in an organization, or

Continue Reading

Git: Checkout a Remote Branch

In order to checkout a branch from a remote repository, you will have to perform two steps. First, you need to fetch the actual branch data, which includes the commits, files, references, etc. Second, you'll want to actually check it out so your working directory contains the branch files.


Continue Reading

Git: Revert a Merge

If you merge a branch in to another, and for whatever reason decide you want to undo the merge, there are some ways to do this with Git.

The solution to this is simpler if you haven't yet pushed the changes to a remote repo, and if you have then

Continue Reading

Git: Fetch a Remote Branch

When collaborating with colleagues, or even when you're just using an open source library, you'll often need to fetch a branch from a remote repository using Git.

The "base case" to fetch a branch is fairly simple, but like with many other Git operations, it can become quite

Continue Reading

Git: Push Local Branch and Track It

Whether you've been programming for decades or just started out, at some point in your career you'll need to share your changes to a codebase. Or maybe if you're like me, you might just be paranoid and want to store everything in a remote repository, like GitHub, for safe-keeping in

Continue Reading