Kedasha Kerr
I'm a Software Engineer who is passionate about encouraging others to get in the industry. I enjoy community building, content creation and learning deeply about Javascript and Developer Advocacy.
Welcome back to GitHub for Beginners, a series designed to help you navigate GitHub with ease.
Our last post covered the top Git commands every developer should know. Today, we’re diving right into the heart of GitHub: repositories! What they are, how to create one, all of their different features and settings, and more.
Whether you’re a developer, a writer, or just curious about version control, understanding repositories is your first step into the world of GitHub.
So, let’s say you created your GitHub account. Now what? Let’s Git right into it and start from the beginning.
A repository, or repo, is a fundamental element of GitHub and Git. It’s a space where project files live, allowing for version control and collaboration.
You can think of a repository as a project folder that tracks changes, stores history, and lets multiple people work together seamlessly.
After you create an account on GitHub, you’ll be taken to your new GitHub dashboard. You should see a green button that says, “Create repository.”
When you click on this green button, it will take you to the “New repository page” which allows you to enter a repository name, select an owner of that repository (you, in this case), add a description for your repository on what your project is about, and choose whether to make the project public or private.
From here, you can initialize your project with a README.
A README file in a GitHub repository provides essential information about the project, including its purpose, usage instructions, how to get started, where to find help, and details on contributors. It serves as an introductory guide for visitors, helping them understand and utilize the project effectively. For now, let’s check the box to add a README.
You likely don’t need a .gitignore file for this project (more to come on that later), so select “None.” Then, underneath “Choose a license” you can select the MIT License from the list.
Once you’re finished with those, click on the green “Create repository” button. You’ve just created your first repository on GitHub!
A license tells others what they can and can’t do with your source code. It’s typically used to share code with others—also known as open source software. This means, based on the license that you choose, anyone on the internet can take your code and use it.
For example, you selected an MIT License for the repository you just created. This is known as a “permissive license,” which gives anyone the ability to use your code how they would want.
Choosing the right license is essential for setting the terms under which others can use, modify, and share your project. Take your time choosing the right one.
You can learn more about licenses and how to choose the right one by going to choosealicense.com.
Forking is actually another way to create a repository, but this time, you’re not starting from scratch. A fork essentially creates a copy of an existing repository, so that you have your own version of it to work on and modify to your liking.
For example, when you want to contribute to an open source project, you’ll first need to fork the repository and then go from there.
This is why it’s super important to choose the correct license, so that others know the limitations of what they can do with your code.
.gitignore
?Finally, we have the “add .gitignore” option on the new repository page. gitignore.io
is a file used in certain projects if you want Git to ignore or not track certain files in your repository.
File exclusion can sometimes be based on the languages, frameworks, and other technologies that you’re using.
You can visit gitignore.io
to generate a .gitignore file for you based on your project needs.
Now that you’ve created your first repository, it’s time to get acquainted with some of its main features.
GitHub repositories are packed with features to enhance collaboration and project management, including:
In the repository settings, you can manage:
This is also where you can enable and disable repository features.
Now, you understand the basics of creating and managing a repository on GitHub. With your first repository set up, you’re now ready to explore its features and start collaborating on your projects!
If you have any questions, pop them in the GitHub Community thread and we’ll be sure to respond.
Here are some more resources to help you on your GitHub journey:
Hey everyone, welcome to GitHub. Keep your feedreader pointed here for daily updates on new features, bug fixes, and general gitbauchery. First up: we just enabled hotkeys for trees and…
The blog is finally here. This is where we’re gonna drop all sorts of Git and GitHub related eggs of knowledge: new features, upcoming features, bug fixes, etc etc. Also,…
Last night I pushed out a feature Tom and I have been talking about since day one: pull requests. That’s the short walkthrough. You can use it to tell people…
Activity feeds are now active. Three, in particular: events for you, events from you, and public events from you. The private feeds are protected with HTTP authentication. You need to…
The first repository in the production db was created October 29th. The first private beta repository was created January 12th. The 1,000th repository was created today, Feburary 25th. (And yeah,…
We added a ‘profile’ link to your badge tonight, giving you easy access to your public profile. It’s, more or less, what everyone else sees. To go with it, we…
rtomayko says GitHub is ‘Myspace for Hackers‘ over on his blog. Flattering, yes, but read closely: this dude gets it. From his post: “Pull requests” happen every day over email…
You can now add multiple emails to your account using the, uh, account link. And hey, are your commits not being linked to your GitHub account? Here’s why: the most…
Update: We’ve discontinued this feature. Just like Facebook and FriendFeed, we’re now showing off our commit log. Not every change merits a blog post, y’know?
Lately people have been asking about our pricing plan. While we’re not ready to reveal it quite yet, we are ready to talk about one aspect of it: GitHub will…