AbdulElahGwaith's picture
Upload folder using huggingface_hub
88df9e4 verified
metadata
title: Enabling {% data variables.product.prodname_code_quality %}
shortTitle: Enable Code Quality
intro: >-
  Use {% data variables.product.prodname_code_quality_short %} to automatically
  catch, fix, and report on code quality issues in pull requests and on your
  default branch.
versions:
  feature: code-quality
product: '{% data reusables.gated-features.code-quality-availability %}'
permissions: '{% data reusables.permissions.code-quality-repo-enable %}'
topics:
  - Code Quality
contentType: how-tos

{% data reusables.code-quality.code-quality-preview-note %}

Prerequisites

  • {% data variables.product.prodname_actions %} must be enabled because {% data variables.product.prodname_code_quality_short %} uses actions to run each {% data variables.product.prodname_codeql %} analysis.
  • To get the full benefit of the feature, your repository should include one of the languages supported for quality analysis by {% data variables.product.prodname_codeql %}. See Supported languages.

Enabling {% data variables.product.prodname_code_quality_short %} for a repository

{% data reusables.repositories.navigate-to-repo %} {% data reusables.repositories.sidebar-settings %}

  1. In the sidebar, under "Security", click {% data variables.code-quality.code_quality_ui_settings %} to display the "{% data variables.code-quality.code_quality_ui %}" page.

  2. Click Enable code quality.

    If Enable code quality is missing from this view, your enterprise owner has disabled the use of {% data variables.product.prodname_code_security %} and {% data variables.product.prodname_code_quality_short %} for your organization. See AUTOTITLE.

  3. Review the information on the Code quality page:

    • Languages: If you want to disable {% data variables.product.prodname_codeql %} analysis for any of the languages, clear the associated check box.
    • Runner type: If you want to use a different runner, choose Labeled runner and define the Runner label. See AUTOTITLE and AUTOTITLE.
  4. Click Save changes to save your configuration for {% data variables.product.prodname_code_quality_short %}.

If your organization has configured caching of private registries, these will be available for code quality analysis to use to resolve dependencies. See AUTOTITLE.

Next steps

  • Learn about the code quality backlog for your repository. See AUTOTITLE.
  • Find and fix code quality issues before they reach your default branch. See AUTOTITLE.