Easy Way to Create a Pull Request

Easy Way to Create a Pull Request

The following are the few steps i follow when making pull requests;-

  • Fork a repository from GitHub that you would like to contribute to.

  • Clone the repository using git clone [https address].

  • change directory into the cloned repo on your local machine i.e cd [name of repo].

  • create a new branch (if it is a small project) using git checkout -b [new branch name].

(optional), if it is quite a large project with many branches you can use an existing branch using git checkout [branch name].

  • Make changes to the code and commit your changes, execute git status to see the changes made then git add . to add those changes to the branch.

  • You can now commit your changes using git commit -m “descriptive message”. Identify the remote’s name using git remote and then push the changes to GitHub using git push origin [branch name].

  • There After go to your forked project repo on the github website and create a new pull request.