Prerequisites
If you get access to Copilot through an organization or enterprise, your organization or enterprise owner needs to enable preview features for Copilot code review. See Managing policies and features for GitHub Copilot in your organization and Managing policies and features for GitHub Copilot in your enterprise.
Managing static analysis tools for your repository
-
On GitHub, navigate to the main page of the repository.
-
Under your repository name, click Settings. If you cannot see the "Settings" tab, select the dropdown menu, then click Settings.

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

-
Edit or create a ruleset for Copilot code review:
- If you have configured a ruleset for automatic reviews from Copilot code review, click the name of that ruleset.
- If you do not have an existing ruleset for Copilot code review, select the New ruleset dropdown menu, then click New branch ruleset and give your ruleset a name.
-
In the "Rules" section, select Manage static analysis tools in Copilot code review.
-
To update the tools that Copilot code review will use, select the Select tools dropdown menu, then select or deselect the available tools.
-
To apply your selections, at the bottom of the page, click Create or Save changes.
Configuring static analysis tools for your organization
-
On GitHub, navigate to the main page of the organization.
-
Under your organization name, click Settings. If you cannot see the "Settings" tab, select the dropdown menu, then click Settings.

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

-
Edit or create a ruleset for Copilot code review:
- If you have configured a ruleset for automatic reviews from Copilot code review, click the name of that ruleset.
- If you do not have an existing ruleset for Copilot code review, select the New ruleset dropdown menu, then click New branch ruleset and give your ruleset a name.
-
In the "Rules" section, select Manage static analysis tools in Copilot code review.
-
To update the tools that Copilot code review will use, select the Select tools dropdown menu, then select or deselect the available tools.
-
To apply your selections, at the bottom of the page, click Create or Save changes.