Skip to main content

允许在企业中使用 GitHub Code Quality。

定义 Advanced Security 的策略,允许存储库所有者启用 GitHub Code Quality。

谁可以使用此功能?

Enterprise owners

上的组织拥有的存储库

注意

GitHub Code Quality is currently in public preview and subject to change. During public preview, Code Quality will not be billed, although Code Quality scans will consume GitHub Actions minutes.

Policy control during the public preview

During the public preview, the Advanced Security policies have been extended to control access to GitHub Code Quality. If you create a new enterprise, GitHub Secret Protection, GitHub Code Security, and GitHub Code Quality are initially available for repository owners to use across all organizations.

For an existing enterprise, GitHub Code Quality is available to repository owners if the Advanced Security policy already allows the use of GitHub Code Security.

Allowing repository owners to enable Code Quality

  1. Navigate to your enterprise. For example, from https://github.com/settings/enterprises.
  2. At the top of the page, click Policies.
  3. Under "Policies", click Advanced Security.
  4. Under "General", select Allow for all organizations, or Allow for selected organizations.
  5. If you choose "Allow for selected organizations", for each organization of interest ensure that the policy is All plans or Code Security and Code Quality only.
  6. In the "Code Security and Code Quality" section, set the "Repository administrators can enable or disable Code Security and Code Quality" option to All repositories: Allowed.

For more information about policies for Advanced Security, see Enforcing policies for code security and analysis for your enterprise.

Next steps

To see Code Quality in action, turn the feature on for one or more repositories, Enabling GitHub Code Quality.