Creating a Pull Request

Heads up... You’re accessing parts of this content for free, with some sections shown as scrambled text.

Heads up... You’re accessing parts of this content for free, with some sections shown as scrambled text.

Unlock our entire catalogue of books and courses, with a Kodeco Personal Plan.

Unlock now

After you finish your homework, commit all the changes, and push the change to GitHub, you need to create a Pull Request to let your Mentor know you are finished and they can start their review of your work.

Screenshot of GitHub Desktop page Preview Pull Request button
Screenshot of GitHub Desktop page Preview Pull Request button

Back in GitHub Desktop, click the blue Preview Pull Request button.

A dialog will appear showing all the changes. Before clicking the Create Pull Request button, you should always verify that the merge (result of the pull request) is to the correct branch and that Able to merge is green and has a checkmark.

Where the branch will be merged to is detailed at the top left of the dialog. For this bootcamp, all merges should go into the main branch. The Able to merge is found on the bottom left of the dialog. If the branch cannot be automatically merged, that means some changes on GitHub are not in the local repository. This should not occur in this bootcamp if you are following the instructions given here.

Clicking Create Pull Request will open a browser window to GitHub to open a pull request.

Screenshot of GitHub Open a pull request page
Screenshot of GitHub Open a pull request page

On this page, you can provide a title and a description for your pull request. Get into the habit of giving a good title and description for your pull requests. The titles and descriptions provide documentation of the work done in this pull request.

Screenshot of GitHub Open a pull request page reviewer drop down
Screenshot of GitHub Open a pull request page reviewer drop down

Before submitting your pull request, ensure you have added a reviewer. Reviewers are people you have added to your project as collaborators. You can add reviewers by clicking the gear to the right of Reviewers on the right side of the screen. Note: You will only see users in this drop-down if you have invited a mentor as a collaborator and they have accepted the invitation.

After you have added a title, description, and at least one reviewer, click the green Create pull request button.

Screenshot of GitHub PR Status Page
Screenshot of GitHub PR Status Page

When you click the button, an email is sent to your reviewers, and you are taken to the status screen shown above. Once your reviewer completes their review, they will add a message to the PR indicating whether it passed or requires further work. Your reviewers will also leave comments in your code for you to review.

Why Create a Pull Request for Solo Work?

You might wonder why you need to create a pull request when you’re working alone - after all, it’s your code and your repository. However, pull requests serve a crucial purpose beyond just team collaboration: they create a formal review process that mirrors professional development practices and provides valuable learning opportunities.

See forum comments
Download course materials from Github
Previous: Adding a Mentor as a Collaborator to the Repository Next: Merging a Pull Request