Getting Started with GitHub – Hello World

Benjamin Akhigbe

Github Hello World

Hello World is a traditional programming exercise in the computing programming world. It is a simple exercise that gets you started when learning something new. Let’s get started with GitHub, the code hosting platform for version control and collaboration. Enables you and your team to work together on projects from anywhere.

This article explores using GitHub repository for Hello World project.

Using a repository for Hello World

A repository is usually used to organize a single project. Repositories can contain folders, files, images, videos, spreadsheets, and data sets – practically anything your project needs. Your ‘hello-world’ repository can be a place where you store ideas, resources, or even share and discuss things with others.

Branching

Branching is the way to work on different versions of a repository at one time. By default your repository has one branch named main which is considered to be the definite branch. You use branches to experiment and make edits before committing them to main.

When you create a branch off the main branch, you’re making a copy, or snapshot, of main as it was at that point in time. If someone else made changes to the main branch while you were working on your branch, you could pull in those updates.

Commit

On GitHub, saved changes are called commits. Each commit has an associated commit message, which is a description explaining why a particular change was made. Commit messages capture the history of your changes, so other contributors can understand what you’ve done and why.

Pull

Pull Requests are the heart of collaboration on GitHub. When you open a pull request, you’re proposing your changes and requesting that someone review and pull in your contribution and merge them into their branch. Pull requests show diffs, or differences, of the content from both branches. The changes, additions, and subtractions are shown in green and red.

As soon as you make a commit, you can open a pull request and start a discussion, even before the code is finished.

By using GitHub’s ‘@mention’ system in your pull request message, you can ask for feedback from specific people or teams, whether they’re down the hall or 10 time zones away. You can even open pull requests in your own repository and merge them yourself. It’s a great way to learn the GitHub flow before working on larger projects.

Merge

Merging your Pull Requests would pull the ‘readme-edits’ branch and merge into the main branch of your software project. This would see the changes that have been incorporated. Once, the team deletes the old branch after the pull request has been successfully been merged and closed.

Summary

Creating a ‘Hello-World’ project on the GitHub repo as a beginner, a newbie to software development, is a first step into programming.  But most importantly creating your first GitHub repo with ‘Hello World’ enables you to create a open source repository that enables you to manage the branch, make changes and commits to the codebase on GitHub using the power of Pull requests and merge. You may or may not be familiar with GitHub in general. I’d love to hear from you about how GitHub has benefitted your software development projects. If you’re just getting started with GitHub, check out our previous posts of our series – Getting Started with GitHub – The Basics of Source Control, Getting Started with GitHub – Free vs Paid Accounts and Getting Started with GitHub – Tips and Tricks, and learn more about GitHub.