Skip to content

Fork, Clone and Remote

Mohak Gupta edited this page Nov 21, 2019 · 1 revision

Fork

If you want to contribute to the project you will have to create your own copy of the project on GitHub. You can do this by clicking the Fork button that can be found on the top right corner of the landing page of the repository.

Clone

For this you need to install git on your machine. You can download the git from here

  1. If you have forked the project, then run the following command -

    git clone https://github.com/YOUR_GITHUB_USER_NAME/disease-app

  2. If you have not forked the project, then run the following command -

    git clone https://github.com/mohak1283/disease-app

Remote

When a repository is cloned, it has a default remote named origin that points to your fork on GitHub, not the original repository it was forked from. To keep track of the original repository, you should add another remote named upstream. For this project it can be done by running the following command -

git remote add upstream https://github.com/mohak1283/disease-app

You can check that the previous command worked by running git remote -v You should see the following output:

$ git remote -v

origin https://github.com/YOUR_GITHUB_USER_NAME/disease-app (fetch)

origin https://github.com/YOUR_GITHUB_USER_NAME/disease-app (push)

upstream https://github.com/mohak1283/disease-app.git (fetch)

upstream https://github.com/mohak1283/disease-app.git (push)

Clone this wiki locally