-
Check out Andrei's videos on github if you haven't watched it already.
-
On the GitHub page for this repository, click on the button "Fork."
-
Clone your forked repository to your computer:
For example, run this command inside your terminal:
git clone https://github.com/<your-github-username>/Github-Demo.git
Replace <your-github-username>!
Learn more about forking and cloning a repo.
-
Move to project directory:
cd Github-Demo.git
-
Before you make any changes, keep your fork in sync to avoid merge conflicts:
git remote add upstream https://github.com/lucifer510/Github-Demo.git git pull upstream master
If you run into a merge conflict, you have to resolve the conflict. There are a lot of guides online, or you can watch this tutorial.
-
After adding the upstream and checking that all files are up to date, we now will create new branch before editing any files. There are two ways to do so:
git checkout -b <branch-name>
git branch <branch-name> git switch <branch-name>
-
On your computer, open your text editor, and add your name to the
CONTRIBUTORS.md
file.
⚠️ IMPORTANT NOTE #1: Add your name somewhere in the middle. Not at the top or bottom in order to avoid the chance of you getting a merge conflict!⚠️ IMPORTANT NOTE #2: Please do NOT edit or remove other people from the list, even to fix their indentation etc. This will likely prevent your PR from being merged.
-
Add the changes with
git add
,git commit
(write a good commit message, if possible):git add CONTRIBUTORS.md git commit -m "Add <your-github-username>"
Replace <your-github-username>!
-
Push your changes to your repository:
git push origin <branch-name>
-
Go to the GitHub page of your fork, and make a pull request:
Read more about pull requests on the GitHub help pages.
Finally, open-source projects use the following tools to organize discussion. Reading through the archives will give you a good picture of how the community thinks and works.
Issue tracker: Where people discuss issues related to the project.
Pull requests: Where people discuss and review changes that are in progress.