DevOps Engineer Masters Program (19 Blogs) Become a Certified Professional
AWS Global Infrastructure

DevOps

Topics Covered
  • DevOps (92 Blogs)
  • Docker (9 Blogs)
  • DevOps Engineer Masters Program (18 Blogs)
  • Kubernetes (11 Blogs)
SEE MORE

Git vs Github – Demystifying The Differences

Last updated on Sep 14,2024 31K Views

Swatee Chand
Sr Research Analyst at Edureka. A techno freak who likes to explore... Sr Research Analyst at Edureka. A techno freak who likes to explore different technologies. Likes to follow the technology trends in market and write...
10 / 10 Blog from Git & GitHub

If you have worked with codes then you must have come across the words like Git and GitHub. It is also possible that you might have used them as well. But do you know what exactly is Git or GitHub and how they are different from each other? Well, if you don’t, no worries! It’s never late to learn new stuff nor its that tough in this case. Read this blog on Git vs GitHub, in which I will be giving you a complete insight of both. I can assure you, by the time you this git vs GitHub blog you will have a clear understanding of both the technologies.

Following are the topics I will be discussing in this Git Vs GitHub blog:

Version Control – Git vs GitHub

To understand the exact difference between git and GitHub you first need to know about version control. So, what do you understand by the term version control? 

The term Version control refers to a system that records changes to a file or set of files over time called the ‘versions’. In other words, these versions will help you in tracking the changes in your codes/project and if necessary, undo those changes as well. This feature of being able to compare, differentiate and revert changes between two versions of a particular project becomes really helpful when working on a larger project. Larger projects mean more people working on the same code which increases the chances of conflicts. Using version control you can easily prevent these conflicts.

This system which controls the versioning of the codes is called a Version Control System (VCS). For a better picture, you can think it as a ‘database’.  Within this database, VCS takes snapshots of your entire project and stores them as versions. Now with the help of these snapshots, you can easily compare the versions and switch between them as per the need. Check out the below picture which shows the entire process:

VCS - Git vs GitHub - Edureka

I think now you clearly understand the concept of version control. One thing I would like to mention here is, don’t get confused between a VCS and a backup/ deployment system. This VCS totally eliminates the need for changing or replacing the toolchain completely unlike the backup systems. Below I have listed few of the advantages of using version control:

  • Version control creates proper workflows which help in preventing the chaos among people using their own development process with different and incompatible tools. 
  • Each version has a description of what the changes in this version are done. These descriptions help in tracking the changes in the code by version.
  • VCS synchronizes the versions and ensures that your changes don’t conflict with others using the same repository. 
  • VCS helps in keeping the history of changes as other people save new versions of your code.  This history can be reviewed to find out by whom, why, and when changes were done.
  • The VCS automation features save yours as well as your teams time and generate consistent results by performing testing, code analysis, and deployment whenever any new versions are saved.

So now let’s proceed ahead with this blog on Git vs GitHub and understand what exactly is Git.

What Is Git? – Git vs GitHub

Now that you know about the version control, it will be really easy for you to understand about Git. So, what is Git?

Git is a version control software which you need to install on your local system in order to use it. For an individual working on a project alone, Git proves to be an excellent software. But what if you are working on a project with a large team. All will be working on the same project but each of you will be having a different version of the same project. Suppose you have made changes in the project directory on your machine and you want to send those changes to your collaborators. Also, you want the changes they make to appear directly in your machine’s project directory. As working on a project, being on the same page with your teammates is very crucial to avoid any type of conflict. So, how you will do that? Well, no worries Git takes care of all but the only condition here is, each of your team members must have Git installed on their systems.

Git also is known as distributed version control system which means using Git you can push and pull yours as well as others changes to other people’s machines:

GIT communication - GIt vs GitHub - Edureka

Now, using Git you can work on the same copy as your team member. But the copy on which you will be working, won’t reflect any of the changes in the main directory unless and until you pull your collaborator’s changes and push back your own changes.

git popularity - Git vs GitHub - Edureka

In today’s market, Git is the most widely and popularly used modern VCS. It is quite matured and is a well maintained open source project. It was developed back in 2005, by Linus Torvalds who is also the creator of Linux OS kernel. If you check the above picture of the Google trends result, you will find that Git has continued to grow in the market since 2005. A varying number of software projects, including commercial as well as open source, completely rely on Git for their version control. So, how Git is different from the rest that makes it so popular?

The major difference between Git and any other VCS like Subversion (SVN), Mercurial, TFS, Perforce, Bazaar etc., is the way Git stores its data. In other systems, information is stored as a list of file-based changes which is also known as delta-based version control. But in case of Git, it stores its data in the form of a stream of snapshots of a miniature filesystem. With Git, whenever you commit or save the state of your project, a snapshot is taken of the present file state and a reference is stored for it. If no changes or updates are done then Git stores a link to the previous file that it has already stored. Following diagram shows how Git stores the versions:git checkin files - Git vs GitHub - Edureka

But Git will only be helpful when you know when is your collaborator’s system is turned on and is connected to a network. So what will you do when your team members are not online? In these situations, a third party having an identical copy of your project, from where you can easily push and pull the changes, will come in handy.

Well, you will be glad to know that, this is what GitHub does and in the next section of this blog on Git vs GitHub, I will explain all about it.

What Is GitHub? – Git vs GitHub

As told, Git is a version control system which tracks the changes when working with computer codes while GitHub is a Web-based Git version control repository hosting service. It provides all of the distributed version control and source code management (SCM) functionalities of Git while topping it with a few of its own features. It is a heaven for the developers where they can store their projects and get connected with like-minded people. You can think it as “cloud for codes”.

gitHub - Git vs GitHub - EdurekaSo basically it is a place to store your identical working directories or repositories. It literally is a hub for the Git repositories which you can use, simply by creating a free account on the GitHub. These accounts come with an abundant storage space where you can store your repositories and build a proper profile which holds a great value. By default the repositories are public i.e., everyone can see your codes but you can make it private as well. So if you are a good coder you can upload your own applications and programs and get recognition from others.

It works along with the collaboration of Git. While Git is a command line tool, GitHub is a Web-based graphical interface which provides you with the access control, basic task management tools along with several collaboration features. Moreover, GitHub can host your project’s source codes in various programming languages and keep the track of the each of the changes made to every iteration. GitHub’s functionality doesn’t end here. It provides following 3 extraordinary features which makes it so powerful:

  1. fork: Or commonly known as forking is copying a repository from one user’s account when you don’t have the write access to it. So you can just copy it and modify it under your own account.
  2. pull: When you have made the changes in codes that you have copied and want to share them with its original order. Then you can send a notification called a “pull request” to them. 
  3. merge: Now the user who is the owner of those codes, if, finds your changes relevant can merge the changes found in your repo with the original repo, by just button click.

If your pull request is accepted by the owner then you get its credit on the original site and shows up in your user profile. It is a kind of a resume that helps the GitHub project maintainer to determine your reputation. So, more the people and projects on GitHub, the better idea a project maintainer gets of its potential contributors. This encourages the young developers and projects to grow more in the industry. I hope now you understand what is Github. So let me now summarize the basic differences between Git and Github.

Git vs GitHub

git logo - Git vs GitHub - EdurekaGitHub logo - Git vs GitHub - Edureka
1. It is a software1. It is a service
2. It is installed locally on the system2. It is hosted on  Web
3. It is a command line tool3. It provides a graphical interface
4. It is a tool to manage different versions of edits, made to files in a git repository4. It is a space to upload a copy of the Git repository
5. It provides functionalities like Version Control System Source Code Management5. It provides functionalities of Git like VCS, Source Code Management as well as adding few of its own features
This concludes this blog on Git vs GitHub. Hope you enjoyed reading this blog and learned something new.
If you found this Git vs GitHub blog, relevant, check out the DevOps Certification course by Edureka, a trusted online learning company with a network of more than 250,000 satisfied learners spread across the globe. The Edureka DevOps Certification Training course helps learners gain expertise in various DevOps processes and tools such as Puppet, Jenkins, Nagios and GIT for automating multiple steps in SDLC.
Got a question for us? Please mention it in the comments section and we will get back to you.

 

Upcoming Batches For DevOps Engineer Masters Program
Course NameDateDetails
DevOps Engineer Masters Program

Class Starts on 12th October,2024

12th October

SAT&SUN (Weekend Batch)
View Details
Comments
2 Comments

Join the discussion

Browse Categories

webinar REGISTER FOR FREE WEBINAR
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP

Subscribe to our Newsletter, and get personalized recommendations.

image not found!
image not found!

Git vs Github – Demystifying The Differences

edureka.co