Skip to content

Enable required status checks for pull requests

Enabling required status checks ensures that no pull requests are merged unless they are free of automatically detected issues (detected by the VIP Code Analysis Bot). This enforces a workflow where pull requests require developers to get clearance from the VIP Code Analysis Bot before they can merge the code.

Prerequisite

Users must have access to an application’s GitHub repository with a GitHub admin role for that repository in order to manage branch protection rules.

To enforce VIP Code Analysis Bot review, create a branch protection rule in GitHub and specify the VIP Code Analysis Bot commit status context:

  1. Navigate to an application’s GitHub repository. This URL can be found in the application’s VIP Dashboard.
  2. Under the repository name, select the Settings tab.
  3. In the “Code and automation” section of the sidebar, select Branches.
  4. Next to “Branch protection rules”, select Add rule.
  5. In the field below “Branch name pattern”, type the branch name or pattern to protect.
  6. Under “Protect matching branches”, enable “Require status checks to pass before merging“.
  7. (Optional but recommended) Enable “Require branches to be up to date before merging“. This ensures pull requests targeting a matching branch have been tested with the most recent code.
  8. In the search field, search for “VIP Code Analysis Bot” and select it in the results provided.
  9. Select the “Create” button.
Screen shot of the VIP Code Analysis Bot option in the status checks dropdown

Last updated: March 25, 2022