Admin controls for GitHub Copilot
Visual Studio 2022 introduces new features for administrators to configure and manage GitHub Copilot for their enterprise effectively. These features provide administrators greater control over the use of Copilot within their organization. Admins can disable Copilot for individual accounts or disable it altogether, and configure content exclusion to prevent certain files from being available to Copilot in Visual Studio.
In this article, you learn how to:
With Visual Studio version 17.10, project administrators can disable Copilot for individual accounts or disable Copilot altogether via the Visual Studio Administrative Templates (ADMX/ADML), ensuring that your repository is protected.
To configure and deploy these policies, you can use Microsoft Intune or the Local Group Policy Editor directly on the client machine.
Head over to the Microsoft Download Center and grab the Visual Studio Group Policy Administrative Template files (ADMX/ADML). It asks you where you want the files to be downloaded, ensure the location is
C:\Windows\PolicyDefinitions
.Open the Windows Local Group Policy Editor, Navigate to Computer Configuration > Administrative Templates > Visual Studio > Copilot Settings and select a group policy.
Once you select your group policy, configure the policy to enable or disable.
Restart your Visual Studio instance to pick up the new policy changes
Content exclusion for GitHub Copilot enables administrators to prevent certain files from being available to Copilot and keep sensitive content secure from Copilot use. You can use content exclusions to configure GitHub Copilot to ignore specific files in a repository or organization. Content exclusion is only available with a GitHub Copilot Business or a GitHub Copilot Enterprise subscription.
With Visual Studio 2022 version 17.11, GitHub Copilot for Visual Studio will ignore excluded content. When you exclude content from Copilot, completions and chat aren't available on the affected files.
Note that Visual Studio 2022 version 17.11 only respects rules in the root repository where your solution lives, and doesn't apply rules from git submodules or for files not under a git repo.
Code completions aren't available on excluded files.
Excluded content isn't included in code completion suggestions in other files.