Code Contribution
Last updated
Last updated
Copyright © 2021 MOSIP. This work is licensed under a Creative Commons Attribution (CC-BY-4.0) International License unless otherwise noted.
The recommended Github workflow here is for developers to submit code and documentation contributions to Inji open-source repositories.
Fork the repository.
Clone the fork to your local machine. E.g.:
Set the upstream project as the original from where you forked. E.g.:
Make sure you never directly push upstream.
Confirm the origin and upstream.
This should display origin and upstream as below:
1. Create a new issue in GitHub.
Follow the issue template provided.
Please provide as much information as possible.
If you want to develop a new feature, please elaborate on the idea and discuss the design before starting development. 2. In your local repository, fetch the upstream.
3. On your local repo, switch to a branch if you are working on an older release or stay in main/develop
branch.
You will get a warning from git. Don't worry, our next step will take care of this warning.
4. Create a new issue branch with the name of the issue.
5. Make sure you are up-to-date with the upstream repo.
You should do this quite often to ensure you are up to date.
6. Now feel free to make the change in the code or documentation. Reach out to our community for any queries. Once done with the work, commit your changes by referring to the Issue ID in the commit message. Eg:
7. Once again ensure that you are up-to-date with the upstream repo as it may have moved forward.
8. Build and test your code. Make sure to follow the coding guidelines. Provide unit test cases for the changes you have built.
9. Push to your forked repo (origin).
10. On your forked remote repository from GitHub, create a pull request using the Contribute button. Direct the pull-request to main
or any specific branch upstream.
Most often it's the same branch in the upstream (as in Step 3).
11. Make sure the automatic tests/checks on GitHub for your pull request pass.
12. Reviewers shall review the pull request. Reach out to the community for a faster response.