A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://docs.github.com/en/copilot/how-tos/agents/copilot-code-review/automatic-code-review below:

Configuring automatic code review by GitHub Copilot

Learn how to configure Copilot to automatically review pull requests.

Introduction

This article tells you how to set up Copilot code review to review pull requests automatically. For an overview of automatic pull request reviews, see About GitHub Copilot code review.

The three sections in this article tell you how to configure automatic code review for:

Configuring automatic code review for all pull requests you create

Note

This is only available if you are on the Copilot Pro or Copilot Pro+ plan.

  1. In the upper-right corner of any page, click your profile picture, then click Your Copilot.

  2. Locate the Automatic Copilot code review option and click the dropdown button.

  3. In the dropdown menu, select Enabled.

Configuring automatic code review for a single repository
  1. On GitHub, navigate to the main page of the repository.

  2. Under your repository name, click Settings. If you cannot see the "Settings" tab, select the dropdown menu, then click Settings.

  3. In the left sidebar, under "Code and automation," click Rules, then click Rulesets.

  4. Click New ruleset.

  5. Click New branch ruleset.

  6. Under "Ruleset name," type a name for the ruleset.

  7. To activate the ruleset, under "Enforcement Status", select Active.

  8. Under "Target branches," click Add target and choose one of the options—for example, Include default branch or Include all branches.

  9. Under "Branch rules," select the Require a pull request before merging checkbox.

    This expands a set of subsidiary options.

  10. Select the Request pull request review from Copilot checkbox.

  11. At the bottom of the page, click Create.

Configuring automatic code review for repositories in an organization
  1. In the upper-right corner of GitHub, click your profile picture, then click Your organizations.

  2. Next to the organization, click Settings.

  3. In the left sidebar, in the "Code, planning, and automation" section, click Repository, then click Rulesets.

  4. Click New ruleset.

  5. Click New branch ruleset.

  6. Under "Ruleset name," type a name for the ruleset.

  7. To activate the ruleset, under "Enforcement Status", select Active.

  8. Under "Target repositories," click Add target and choose either Include by pattern or Exclude by pattern.

  9. In the dialog box that's displayed, type a pattern that will match the names of repositories in your organization—for example, *feature to match all repositories with names that end in feature.

    For information about pattern-matching syntax, see Creating rulesets for repositories in your organization.

  10. In the dialog box, click Add inclusion pattern or Add exclusion pattern.

  11. Repeat the process for any additional patterns you want to add.

    Note

    You can add multiple targeting criteria to the same ruleset. Exclusion patterns are applied after inclusion patterns. For example, you could include any repositories matching the pattern *cat*, and specifically exclude a repository matching the pattern not-a-cat.

  12. Under "Target branches," click Add target and choose one of the target options.

  13. Under "Branch rules," select the Require a pull request before merging checkbox.

    This expands a set of subsidiary options.

  14. Select the Request pull request review from Copilot checkbox.

  15. At the bottom of the page, click Create.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4