Hey there, have you heard about GitHub? Well while GitHub might be the best open source go-to place for all programmers, what really is the platform all about? And is the platform really worth all the hype, one might ask? Well, this platform is really straight forward. Whenever the name GitHub is mentioned, developers all over the world get excited for reasons practically unknown to me. Well, this was before I knew about the platform and what it stands for and now I know many developers are so hyped about it. If you are a programmer and you haven’t heard of GitHub, or let’s say you have heard about it but don’t know what it really is about, then you need to read this article and digest every piece of information that will be shared within it.
GitHub
The GitHub platform is seen by many users as a code sharing and publishing platform and that it is also a social networking platform for programmers. Well, they are not wrong as the platform can be called or associated with both. But do you know why both statements about GitHub are true, it hasn’t really explained why the platform is so special. GitHub is a code-sharing platform. This code sharing platform is essential for version control and collaboration. Since this platform is made for collaborators, it lets them work together or collaborate on projects from just about anywhere.
In GitHub, there is Git. Now, what is Git? Git is at the heart of operations at GitHub. Git is an open-source project. This open-source project called Git manages and stores revisions of projects and it is mostly used for codes. It can also be used to manage any other type of files such as word documents or final cut projects. When a programmer makes a change to a file stored on the platform, the changes are made directly t the central repository (a repository is a directory or storage space where your projects are kept).
GitHub is one of the best repositories hosting service in the world currently. Unlike other platforms just like it, it adds its own features. This platform is a command-line tool and if you are a programmer who has made use of the platform before then you should know. But even at that, the platform provides a web-based graphical interface and access control and other collaboration features. This company and platforms is so popular that it found itself on the TechCrunch, tech website.
TechCrunch reported that Andreessen Horowitz invested a whopping $100 million investment in the company. You may be wondering as to what the company and platform will do with all that money or whether it is a good or bad investment in the part of the investor. Personally I think that it is a great investment for both parties since the platform is one of the best in what it does if not the best.
GitHub Login
Now that you have an idea as to what the GitHub platform is all about, let’s move on to other aspects of the platform. For programmers and software developers who already have an account on the platform, you will need to login to get access to your account and features offered by the platform. Logging in to your account in GitHub is free and easy and it shouldn’t consume any more of your time. To login to your account on GitHub, follow the steps below;
- Go to GitHub on your device.
- Click on the sign-in tab at the top right corner of the GitHub page.
- Enter your username or email address and password in the login field.
- Lastly, click on the sign-in button.
You will be signed in or logged in to your account immediately. It’s that easy.
GitHub Sign Up
As a newbie to the platform, you will need to create an account or sign up for an account in order to start making use of it. Creating an account on GitHub is easy. To create a GitHub account;
- Go to https://github.com/.
- Click on the sign-up button at the top right corner of the GitHub page.
- You will be redirected to the account registration page where you will be required to create a username and password and provide your email address.
- Next, you will be required to verify your account by solving a puzzle. To verify your account, click on the verify button.
- After verifying your account, click on the create account button.
That’s it. You have just created a GitHub account where you can join millions of other developers from all over the globe. GitHub is a freemium tool meaning it is free but in other to access other features on the platform you will have to subscribe to it by choosing a plan.
GitHub Tutorial
Now that you are new to the platform, would you want a tutorial on how things work? If you would then you need to pay close attention to this header. With this tutorial, you will learn about GitHub essentials such as repositories, branches, commits, and pull requests. With this tutorial, you don’t necessarily need to know how to code, install Git, or use the command line. I will be guiding you through 5 steps in this tutorial and the tutorial starts now
Step 1: Create A Repository
I have already explained to you what a repository is but here is a quick one for you just in case you are just joining us. A repository is used in organizing a single project and they can contain images, videos, folders, and files, and just about anything a project needs. To create a new repository;
- Log in to your GitHub account.
- In the top right corner, close to your profile icon, click on the ‘add or plus’ icon.
- Select a new repository.
- Give your new repository a name (hello-world) and write a short description about it.
- Next, select the initialize this repository with a README.
- Lastly, click on create repository.
That’s it.
Step 2: Create Branch
What is branching? Well, this is a way to work on various versions of a repository at the same time. Your repository has one branch by default named ‘main’. This branch is considered to be the definitive branch. The main aim of branches is that they serve as experiments in making edits before adding them to the main branch. Normally when you create a branch off the main, it simply means that you are making a copy at the point in time. To create a new branch;
- Go to the new repository you created, hello-world.
- At the top of the file list that says branch: main, click on the drop-down icon.
- In the new branch text box, enter a branch name.
- Click on the create branch button or box.
You have just successfully created a branch.
Step 3: Make And Commit Changes
Now to make edits, you need to read this next step carefully. Saved changes on GitHub are called commits and each commit on this platform has an associated commit message. This message is a description of why a particular change was made. To make and commit changes;
- Click on the README.MD file.
- To edit, click on the edit or pencil icon at the top right corner of the file page.
- Write a short description of yourself in the editor.
- Next, write a commit changes explaining the changes that you made.
- Lastly, click on the commit changes button.
Now you have made changes to your README file on your readme edits branch. This action will differentiate this branch from the main branch.
Step 4: Open A Pull Request
Pull requests are the main aspects of collaboration on the GitHub platform. Whenever a person pulls a request on this platform, he or she is proposing changes and requesting that someone else reviews and pull in their contribution and then merge them into their branch. Pull requests generally show differences of the content from both branches and these changes are shown in green and red colors.to open a pull request;
- Click on the pull request tab or button from the pull request page.
- Next, click on the new pull request button which is green in color.
- Select the branch you made in the examples comparisons box to compare with main.
- Cross-check the changes in the differences on the compare page to see if they are intact.
- Click on the green Create pull request button when you are done scrutinizing the changes you made.
- Enter a title for your pull request and add a brief description of your changes.
Lastly, when you are done with your message, click on the create pull request button.
Step 5: Merge Your Pull Request
The final step of this tutorial comprises o you bringing your changes together, in other words, merging your README edits branch to the main branch. To do this;
- Click on the Merge pull request button which is green in color to merge the changes you have made into main.
- Click on the confirm merge button.
You can now proceed to delete the branch since you have now successfully incorporated your changes. The delete branch button is purple in color. With the completion of this tutorial, you have just learned how to create a project and also make a pull request on GitHub. You will however need an account for all of the above to be possible. To learn how to create an account, check the GitHub sign up header above.