Creating My First GitHub Repository! ๐Ÿš€

Creating My First GitHub Repository! ๐Ÿš€

ยท

5 min read

Hey Guys!!!

My name is Atharva and I am a high school student, interested in the world of development. This blog is a part of the "Open Source" track. In this blog, I will be sharing how I made my first ever (small-scale) repository on GitHub and how you can make your repository as you learn more things and are ready for the outside world.

Link to my repository: github.com/the-amazing-atharva/Hello-World-..

Some Snippets :

But before we begin, make sure you have a GitHub account and Git Bash installed on your computer. If you don't have one, you can easily create an account on GitHub.com and download Git Bash here.

Let's Begin!!!

Let's start by creating our first C++ program :

  1. Open your favourite text editor and create a new file called "hello.cpp".

  2. Type the following code into the file:

#include <iostream>

int main() {
    std::cout << "Hello, World!" << std::endl;
    return 0;
}
  1. Save the file in a directory of your choice.

  2. This will be the location of your local repository.

Snippet :

Adding it to Github :

  1. Open Git Bash in the same directory as the "hello.cpp" file.

  2. Initialize a new local repository by running the command :

$ git init
  1. Add the "hello.cpp" file to the repository by running the command :
$ git add hello.cpp
  1. Commit the changes with a commit message by running the command :
$ git commit -m "Initial commit: Hello World program"
  1. Now that our code is ready in our local repository, let's share it with the world by creating a new repository on GitHub.

  2. Go to your GitHub account, and create a new repository.

  3. Once the repository is created, you'll be provided with instructions on how to link your local repository with the remote repository on GitHub.

    The instructions will look something like this:

$ git remote add origin https://github.com/yourusername/helloworld.git
$ git push -u origin master

And that's it! Your "Hello, World!" program is now live on GitHub! ๐Ÿš€

Share the link to your repository with your friends and other developers or beginners and the world. Show off your first-ever GitHub repository and let the world know that you're on your way to becoming a C++ pro! ๐Ÿ’ป

Advantages of Creating Repositories on GitHub :

  1. Version control: GitHub allows you to track changes to your code over time, making it easy to collaborate with others and roll back to previous versions of your code if needed.

  2. Collaboration: GitHub makes it easy to collaborate with others on projects by allowing multiple users to work on the same codebase at the same time, and track changes made by each user.

  3. Backup: GitHub provides a secure and reliable backup of your code, so you don't have to worry about losing your work due to a computer crash or other technical issues.

  4. Open-source contributions: GitHub is a popular platform for open-source software development, allowing developers to easily contribute to open-source projects and share their open-source projects with the community.

  5. Showcasing your work: GitHub allows you to create a portfolio of your work and share it with others, which can be useful when looking for a job or seeking to collaborate with other developers.

  6. Learning: GitHub is a great place to find and learn from other developers and their code. Many developers share their work on GitHub, allowing you to learn new skills, techniques and best practices.

  7. Community Support: Having your code on GitHub means you can get support from the open-source community, which can help you to improve your code and overcome bugs, and also you can offer your help and support to others.

  8. Accessibility: GitHub makes it easy for anyone to access your code from anywhere in the world.

  9. Bug tracking: GitHub provides built-in issue-tracking features that allow you to track and manage bugs, feature requests and other tasks related to your code. This makes it easy to keep track of what needs to be done and who is working on it.

  10. Integration: GitHub provides APIs and webhooks that allow you to integrate it with other tools like automated testing, code quality analysis, and deployment tools. This can streamline your development process and make it more efficient.

In short, GitHub is a comprehensive platform that offers a variety of features and tools to benefit developers, whether they are working alone or as part of a team. It offers everything necessary for efficient code management and collaboration, including version control, backup, open-source contributions, showcasing your work, learning, community support, accessibility, code review, continuous integration and deployment, bug tracking and many more features for developers to manage code and collaborate.

Learnings :

As you can see, creating and sharing a GitHub repository is a simple process. With a little bit of practice, you'll be able to create and share your projects with ease. And remember, the more you share your code, the more feedback you'll receive, and the more opportunities you'll have to collaborate with other developers. So don't be shy, and share your work with the world.

Happy coding! ๐Ÿš€๐Ÿ’ป๐ŸŒŽ

Conclusion :

In conclusion, GitHub is a great platform for developers to share their code and collaborate with others. By creating a repository and sharing your first C++ program, you're on your way to building a portfolio of your work and demonstrating your skills to potential employers or collaborators.

With a little bit of practice, you'll be able to create and share your projects with ease.

Share your code, get feedback, and let the world see your work!

Liked This Blog?

Do react and comment with your thoughts on the points discussed above.

Make sure to follow me :

  1. ๐Ÿ’ป Twitter

  2. ๐Ÿ“š Hashnode

  3. ๐ŸŽ‰ Medium

  4. ๐Ÿ“ GitHub

  5. ๐Ÿ”ฅ LinkedIn

ย