Let’s walk through and discuss the pull request workflow. This process is your workflow for submitting your contribution for consideration to be added (merged) to the project.
- It starts on your local machine where you are building and validating your work in a branch.
- Then you push your branch to your forked copy of the project, i.e. in your GitHub project (which is the remote origin).
- Open a Pull Request and fill out relevant and informative information to tell the review team what your contribution is.
- If the project has a Continuous Integration (CI) server, your contribution is built and validated. The tasks that a CI can run could include running:
- test suites to make sure your contribution did not break anything.
- validators to check your contribution’s compliance to the coding standards.
- code quality inspectors to sniff for potential issues.
- performance profilers to check if your contribution negatively impacts the project.
- Then the review team manually reviews your contribution. They can approve it. Or request changes.
- If changes are requested, you make those on your local machine, push the changes, and then your new commits are automatically re-entered in the PRs pipeline for consideration.
- When approved, your contribution is merged into the project.
- Finally, you’ll have some clean up work to remove the branch locally and in your forked copy. Plus, you’ll want to update your local and remote copies for the new version of the project. (We’ll cover this workflow later in this lab.)
You get WET when you swim. Stay DRY when you code.
Total Lab Runtime: 02:46:31
- 1 Contributor's Workflow Big Picturefree 10:49
- 2 The Wiring - Fork. Clone. Upstream.free 08:51
- 3 Fork a Remote Copypro 02:13
- 4 Clone It to Your Local Machinepro 05:02
- 5 Add Upstream Remotepro 04:34
- 6 Branch Workflowfree 10:30
- 7 Naming Branchespro 05:38
- 8 Create a New Branchpro 03:56
- 9 Switch to a Different Branch (Checkout)pro 05:34
- 10 Do Our Workpro 04:40
- 11 Explore How Work is Isolated in Branchpro 03:19
- 12 Pull Request Workflowfree 06:00
- 13 Push Your Contribution to GitHubpro 04:01
- 14 Open a Pull Requestpro 09:36
- 15 Code Review & Change Requestspro 07:28
- 16 Your Contribution is Approved & Mergedpro 05:19
- 17 Clean up & Pull Down Updatespro 16:08
- 18 Keep Your Branch Up-to-Datepro 06:49
- 19 Update Branch with Mergepro 13:30
- 20 Update Branch with Rebasepro 11:38
- 21 Dealing with Merge Conflictspro 12:23
- 22 Wrap it Upfree 08:33