Difference Between Git and GitHub
Git and GitHub are two completely different things. Let me quickly explain what is Git and what is GitHub and how they are actually related.
Most popular definition of Git is following:
Git is distributed version-control system, but this definition is actually too complicated, especially for beginners. Let me explain you what is Git in more simple words. Git allows you to track files in any folder called repository, and Git preserves history of all changes that you make with files in this repository. But how Git does that? How it stores all changes of all files in the folder? Under the hood, Git has its own, let's say, file structure, and every file is stored in a separate document, and every file has special hash, and that's why we can say that Git is simply persistent hash map and it stores keys and values; nothing else. Key is a hash and value is content of every file. Another important notice regarding Git, you can use it locally on your computer, even without internet and locally you will have full access to entire history of all changes that you made in your repository. Git doesn't depend on Internet connection. It stores all data locally on your computer, and that is a great benefit of Git, but why is it called distributed version-control system? That's because you may collaborate with other people and work on the same project, and that's where GitHub comes in.
Github helps to manage your Git repositories, and usually GitHub is used when different people work on the same project. But of course, you may use GitHub, even if you don't have any other collaborators. You may simply use GitHub as a backup service for your repositories, and even if you will delete your local repository; remote repository at GitHub will still be available, and you will be able anytime download your remote repositories from GitHub again locally to your computer and continue working on them. But of course, distributed teams of people that want to work on the same projects will benefit from GitHub the most.
Let's quickly summarize; Git is distributed version-control system. If you want to use Git, you must install it on your local computer and after installation of Git, you can start tracking any changes in any of your folders on your local computer; and again, for that, you don't require any internet connection and under the hood, Git in fact, is special file system that allows you to store changes that you make in any folder. GitHub is repository hosting service, and it allows you to create remote copies of your local Git repositories and more than that, it allows other people to collaborate on your repositories, download them, change, and so on. Of course, GitHub has many other features. For example, with GitHub, you are able to create website with hosting; with domain, it will be sub-domain of github.io and you will also get free SSL encryption. That is a GitHub. Okay, now, when you understand difference between Git and GitHub, we are ready to move on and install Git on your computer. Git is available for different operating systems for Mac OS, Windows, and Linux/Unix.
Comments
Post a Comment