In a couple of months, Hacktoberfest 2022 will start. Hacktoberfest is a celebration of open source contribution for which you can get awesome swags. So let's practice to get ready!
You will need to signup for a GitHub account if you don't have one.
Go on the repository where you want to make a contribution and click on the grey "Fork" button on the top of the repository. This makes a copy of the repository in a new repository on your GitHub account.
Click on the "Code" button and copy the https (or the ssh if you have an ssh key) adress. In your terminal, write the following line:
git clone *paste the adress you copied here*
In your terminal, go into the new directory the cloning created:
cd *Name of the repository*
Choose the name of the branch, and type:
git checkout -b *Name of your new branch*
Now you can open the file you want to modify in your IDE, make the modifications and save your work.
Back in the terminal stage your changes:
git add *Name of the file you modified*
Then commit the file with a short description of your modification(s):
git commit -m "Short description"
And push your repository to GitHub:
git push origin *name of your branch*
In your forked repository, you now have a button saying "Compare & Pull Request"! Click on it, it will open a new page where you can explain to the maintainers of the repository the changes you made. A brief but good description as well as a screenshot really help the maintainers to review your PR. You can also ask a question if you have any.
When you're done, you can click on the button underneath: "Create Pull Request".
That's it! You created your first PR! Congratulations! 🎉 Now, you just have to wait for your PR to be reviewed and eventually merged. Be patient!