Whether or not you’re starting off a fully new software package project or wanting to just take a “Docs as Code” method with your documentation on GitHub, a single of the first measures is producing a repository (repo). Here’s how it’s finished.
Why Produce a GitHub Repo?
Git is an open-supply distributed revision manage program that enables a number of builders (and writers!) to continually and consecutively make and track modifications to code or documentation in a centralized site without the need of overriding an individual else’s function. This version command helps make it so that if something breaks, you can quickly hunt down the source of the issue and revert back to a doing work version just before the problematic code is pushed.
It is also fantastic for tracking who contributed to what and when. This is specifically important when numerous people from distinctive time zones are contributing to just one undertaking.
Associated: What Is GitHub, and What Is It Made use of For?
By making a GitHub repo, you deliver these added benefits to your task. Moreover, if you enable your repo to be open up to the general public, many others can contribute—whether that will involve correcting broken code or even generating corrections to typos. You may perhaps even be able to release a functioning beta version forward of plan. Open up supply is a wonderful matter.
How to Produce a GitHub Repo
To established up a project on GitHub, you will require to make a repo. To do so, log in to (or make) your GitHub account. After logged in, simply click the “+” icon on the appropriate side of the header menu (which is available from any place on the web page). Decide on “New Repository” in the drop-down menu that appears.
You are going to now be on the “Create a New Repository” webpage. Decide on the owner of the repo and give it a limited, memorable title. Retain in brain that the name of the repo wants to be URL-pleasant. Though there is no demanding convention, the most popular way is to use all lowercase letters whilst separating terms with a hyphen, these types of as instance-repo-title
. If you use spaces in the title, a hyphen will be additional in its put.
When you’ve named your repo, give it a short description and decide on regardless of whether you want to make the repo general public or non-public.
Subsequent, you can:
- Incorporate a README file: Introduce and describe how to use and add to your project.
- Include .gitignore: Decide on which files to ignore.
- Select a license: Permit other folks know what they can and just cannot do with your project’s code.
These are optional but remarkably advisable to add. When you are all set, simply click “Create Repository.”
Your repo is now created.
After you have produced a repo, you can clone it to your neighborhood device, which enables you to make edits to the information domestically somewhat than directly to the supply data files in the repo.
Related: How to Clone a GitHub Repository