From fa9fb0e220629c0be1e361c8c0467f4a4fecc123 Mon Sep 17 00:00:00 2001 From: Swati Goel Date: Fri, 24 Nov 2023 15:34:31 +0530 Subject: [PATCH] docs(INJI-585): Update code contribution Signed-off-by: Swati Goel --- docs/contribution/code-contribution.md | 24 ++++++++++++++++-------- 1 file changed, 16 insertions(+), 8 deletions(-) diff --git a/docs/contribution/code-contribution.md b/docs/contribution/code-contribution.md index 9a63f451b..e478cb9a0 100644 --- a/docs/contribution/code-contribution.md +++ b/docs/contribution/code-contribution.md @@ -10,7 +10,7 @@ The recommended Github workflow here is for developers to submit code and docume ## Setup your development machine -1. Fork repository of interest. +1. Fork the repository. 2. Clone the fork to your local machine. E.g.: ``` @@ -32,20 +32,28 @@ The recommended Github workflow here is for developers to submit code and docume ``` $ git remote -v ``` + This should display origin and upstream as below: + + ``` + origin https://github.com//inji.git (fetch) + origin https://github.com//inji.git (push) + upstream https://github.com/mosip/inji.git (fetch) + upstream https://github.com/mosip/inji.git (push) + ``` ## Code changes -1. Create a new issue in GitHub. +1\. Create a new issue in GitHub. 1. Follow the issue template provided. 2. Please provide as much information as possible. 3. 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. +2\. In your local repository, fetch the upstream. ``` $ git fetch upstream ``` -3\. On your local repo, switch to a branch if you are working on an older release or stay in `main/develop` branch. +3\. On your local repo, switch to a branch if you are working on an older release or stay in `main/develop` branch. ``` $ git checkout upstream/ @@ -91,12 +99,12 @@ $ git pull upstream $ git push --set-upstream origin issue- ``` -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. +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. {% hint style="info" %} -Most often it's the same branch in the upstream (as in Step 3). +Most often it's the same branch in the upstream (as in Step 3). {% endhint %} -11\. Make sure the automatic tests on GitHub for your pull request pass. +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](https://community.mosip.io) for a faster response. +12\. Reviewers shall review the pull request. Reach out to the [community](https://community.mosip.io) for a faster response.