Git basics: What is GitHub?

I'm a full-stack developer from South Africa 🇿🇦. I love writing about JavaScript, HTML and CSS.
Search for a command to run...

I'm a full-stack developer from South Africa 🇿🇦. I love writing about JavaScript, HTML and CSS.
Glad you like it Hassib!
Thanks Jose!
Glad you enjoyed it.
Thank you Sumudu!
I'm so glad you enjoyed the article.
In this series we'll cover some basic, but very important topics in Git, GitHub and Open source
Now that we have a basic introduction into what Git is and how GitHub works, let's make our first ever git repo and push it to GitHub! Yes, we'll be doing all of that today. The result is a repository on GitHub that you or someone else can use to kee...
Most of you know me for my consistency, a golden arrow in my blog series. I've written 1000 articles in 1008 days! Almost an article a day, and my honeymoon was the only holiday I ever took. I'm super proud of this achievement; it has been a fantasti...

It's not the first time I'll be talking about community. I think it's an essential aspect of any successful tool. This shows in my previous explorations of Astro, Medusa, and now Vendure as well. All these products thrive in a super open, welcoming, ...

The cool part about Vendure is how easy it is to set up and how abstract each layer is. Basically, we get the following elements: External database Server Worker Admin UI Frontend While this is amazing, it also brings a bit of complexity when it co...

The previous article looked at customizing Vendure on a data and process level. In this article, we'll look at customizing emails, as they are often a big part of a webshop system. We'll be looking at two different layers of customization for customi...

Even though Vendure is a pretty significant project out of the box, in some cases, we might want to go in and modify some elements to work to our specific use case. In this article, I'll take a high-level look at some elements we can customize within...

Now that we have a basic understanding of what Git is. Let's have a look at what GitHub is.
I love the following analogy as it makes so much sense (I stole this from the internet).
It's the difference between porn and pornhub.
GitHub is a website to host your Git repositories. But not just that, it's broader as it's also a place for millions of other developers to host their code.
Many people do their whole open source community on GitHub, making it one sole point of communication.
GitHub is remarkable in having automated actions, issues and managing team development.
Besides that, it gives us a super good visual overview of our code, branches, and pull-request.
I've opened a repo on GitHub, and this is generally what you are welcomed with:

I've divided this layout into four sections:
Let's go through each of these items and see what they provide us in more detail.

The header of a GitHub repo contains a lot of information and gives us a quick overview of what we can do with this repo.
The left top states the company/user and repo name.
In this example, the company is dailydotdev, and we view the repo daily. It also states it's a public repo so that anyone can contribute to it.
On the right, you see some crucial icons with some numbers. These are very important to open source.
The last part of the header contains a menu to navigate the repo options.
Code: The actual code files of this project. And generally, the homepage we enter.
Issues: Issues are like the name suggest issues that are logged for this repository. For public repos anyone can log a problem, and it's a well-known way of logging issues for open source.







The project files are the actual files of the project, and we can even navigate through folders and open files from this view.

Branch dropdown: This dropdown can be used to switch between all the branches in a repo. And show the code that belongs to that branch.
Branches: This is a list of all the branches and how they compare to the main branch. It quickly shows which branch is ahead or behind from the main/master branch and a PR open.


Go to file: This button can be used to quickly find a file in the project. I must admit I don't use this myself.
Add file: This button can be used to add a file directly into the project. It will also be added to the commit history. But I would always suggest using the normal git-flow.
Code dropdown: This dropdown can be used to download the codebase through a link or via SSH.

The sidebar provides a lot of quick information about a repo in a quick overview.

In the sidebar, we see a lot of cool things:
The readme is an essential part of open source projects. It's the welcome page to your project.
You should use this file to write something about the project, so other people understand what it's for and how to use it.
I'll write a more detailed article on what a good readme should look like.
The short version would be:
This is not a golden standard and can be tailored to your project's needs. My best advice would be to look at what some other big projects are doing with their readme and work from there.
And that's it. I hope you have gotten a good overview of the layout of a GitHub repo and how we can use it. We'll dive into more details in creating our repo and pushing code to it.
Thank you for reading my blog. Feel free to subscribe to my email newsletter and connect on Facebook or Twitter