Getting started with your first contribution to an open-source project on GitHub can be an exciting and rewarding experience. Here is a step-by-step guide to help you through the process:
If you don't have a GitHub account, sign up for one at github.com.
Familiarize yourself with GitHub by exploring repositories, understanding how issues and pull requests work, and checking out different projects.
Select a project that aligns with your interests and skills. Look for projects with a good first-timer-friendly label, which indicates issues suitable for beginners.
Every project usually has contribution guidelines. Find and read them carefully to understand the project's coding standards, commit message conventions, and other important information.
Follow the project's instructions for setting up your local development environment. This may involve installing specific software or dependencies.
Look for issues labeled as "good first issue" or something similar. These are usually tasks that are suitable for newcomers. Read through the issue description and comments to understand the context.you can also create your new issues by clicking on new issue button(this would depend on the contribution guidelines of the organisation ).
On the project's GitHub page, click the "Fork" button in the top-right corner. This creates a copy of the project in your GitHub account.
Clone the forked repository to your local machine by going to the code button and copying the url code . Now go to vs code and click on clone git repository and paste the url.this will create a copy of the project at your local machine.
Create a new branch for your contribution. firtsly go to main present at the footer of vs code , then in the input click on "create new branch" and then type the name of the new branch and press Enter . This helps keep your changes isolated from the main codebase.
Make the necessary changes in your local machine. Follow the project's coding standards and guidelines.
Now you have to Commit your changes to your local branch by going to Source Control icon at the sidebar . now type the relevant commit message and click on Commit option.A dialog box will appear , click on yes . now since you have created a new branch you will get an option saying "Publish Branch".Click on it.
Now after pressing the commit button , click on Sync changes and click on "Ok" in the dialog box.
On the GitHub page of your fork, click the "New pull request" button. Compare your branch with the main branch of the original repository. Provide a descriptive title and comment about your changes.
The project maintainers or other contributors may review your PR and provide feedback. Be responsive to comments and make necessary changes.
Once your changes are accepted and merged, celebrate your first open-source contribution!
Remember that the contribution process may vary slightly between projects, so always refer to the specific guidelines provided by the project you're contributing to.Although the fundamentals remains the same.