There was a question that I could never seem to answer when I was teaching myself how to code: “What is GitHub, and what does it do, exactly?”
Even when you go to GitHub’s website, the only information under the About section is, “GitHub is how people build software.”
Well thanks for that thorough explanation, GitHub.
I only understood what GitHub was after it was explained thoroughly at my coding bootcamp. Even then, I didn’t truly understand its capabilities until I was forced to use it over and over again.
So let’s get right to it.
First of all, what is git?
This article does a good job of explaining git, but essentially git thinks of its data like a set of snapshots of a mini filesystem. GitHub is based on the git application, hence the name “Git-Hub”.
What is GitHub?
GitHub.com is a website that is used to allow developers to collaborate on projects by contributing code to the same repositories. It is widely used by companies for version control. In a nutshell, version control means that if something in the code breaks the product, the company can revert back to an earlier version– or “snapshot” as mentioned earlier– that is still working correctly. They can also use GitHub to go through an organized timeline to find out what went wrong, fix it, and get everything back up and running. With GitHub, every code contribution is stamped with the software developer’s name, the time it was committed, and what that piece of code was for. Handy, eh?
There is a social component to GitHub, as well. Software developers can upload code from their personal projects, even, and have a public repository of their code for their friends, recruiters or hiring managers to see. In this way, GitHub is an online portfolio of your code.
That sounds awesome! How do I start using GitHub?
You can create your own GitHub account, and I highly recommend it. Potential employers will look at your GitHub profile if you’re applying to a software developer position with them.
- Go ahead and create your GitHub account. This is just like creating an account on any other website. You choose a username and a password.
- You will need to set up an SSH key that connects your computer securely to your GitHub account. No one else will be able to upload to your GitHub account. The SSH key is essentially is a digital “key” that you hold which only allows you to upload code to your GitHub repositories. You need to create a unique SSH key for each computer you plan on pushing code to your GitHub account with. Once you set it up, that’s it! You don’t have to think about it anymore.
- Use the terminal to upload code from your local machine (your computer or laptop) to your remote machine (GitHub). This part can be scary for people who have never used the terminal before.
- Not sure what the terminal is or how to use it? This short video is super helpful and will get you up and running!
- Create a repository on GitHub, and upload the project folder from your computer to GitHub! This can take quite a few steps and seems tedious at first, but it will became second nature to you. Don’t give up! GitHub workflow is a vital thing to learn if you want to work in a professional programming environment, but it definitely has a learning curve to it.
- This tutorial does a good job of walking you through the process of creating your GitHub repository and uploading your project.
If your head is still spinning from this GitHub stuff, GitHub themselves have some handy guides that walk you step-by-step through different functions of the site!
And if you have any other questions, feel free to comment below.