Git and GitHub Explained like I’m five!

On my journey to becoming a developer, one of the most challenging things to understand has been Git. As a developer, you might be required to make constant changes to your code which lead to releasing new versions.

Git is a version control system that helps us manage the changes made to our code or programs and stores them in repositories; so we can easily changes made over time. For instance, imagine you are writing an essay. While writing this essay, you’re creating duplicates, making changes and saving them with different names to keep track of which version each one is, so you can go back to it when you need to. That’s the whole idea behind version control.

This system allows people to work in groups easily. With git, a team of developers can have their own versions of a project on their computer and later, the team can merge these individual versions into the main version of project.

A lot of times and for different reasons, people confuse Git and GitHub. For me, I think it was the name and how they connect. So..

What is GitHub?

Github is a cloud-based platform where developers host their code for version control and collaboration. It allows you manage git repositories online, work and network with other developers.

This makes it clearer that Git and Github are two different things. To be specific, here are the differences;

  1. Git works locally on your computer while Github is a hosted on the web.
  2. Git is a version control system. Github is a hosting service for Git repositories.
  3. Git is a command line tool while Github is a Graphical User Interface.

How to set up Git

Installing git on your computer

With git being a command line tool, we can access it through our computer terminals. Although, you have to make sure that you have git installed on your computer.

To download git, go to https://git-scm.com/downloads.

Download the git version for your system and follow through with installation process. After installation, go to you computer terminal and run the command;

If it was well installed, it would return the version of git you have installed on your computer.

However, if you use a Mac or Linux Operating System, you can use the default bash terminal that is pre-installed on your computer.

On Windows OS, you can use the inbuilt PowerShell terminal or Git Bash terminal that comes with the Git installation package.

Configure Your Name and Email

Once you’re finished with the installation process, the next step is to set up a name and email that Git can identify you with. In your computer’s terminal, run the following commands:

To check if you have set this up correctly, run this command:

Why is Git important?

To conclude this article, here’s a list of reasons why git is important and every developer should understand it:

  1. It helps you maintain the backup of your source code.
  2. Git gives room for effective collaboration with other developers and teams.
  3. It allows you to sail new features efficiently.
  4. It also makes it easier to deploy source code on server.

--

--

We celebrate and empower women in Technology across Africa by telling their stories, empowering them through technical programs & activities while also helping them share their knowledge and ideas through articles.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store