Forking in GitHub is a handy feature when you don’t have the necessary permissions to access the repository in which you wish to suggest changes and you don’t want to waste your valuable time waiting for it.
Once you’ve made changes to your forked repository, you can suggest to push them into the original repository using the following steps:
-
Open the main page of the original repository that you created a fork for.
-
Navigate to the Pull requests tab above the files displayed.
-
Now, click on compare across forks on the page that appears.
-
Using the respective drop-down menus, select the base repository and base branch to select the destination repo and branch you want the changes to be merged to.
-
Also, select the forked repo using the head repository drop-down menu and the correct branch with the suggested changes using the compare branch drop-down.
-
Click on
Create pull request
and give your pull request an apt title and description. -
Now, your changes are ready to be reviewed and approved by your colleagues