Use GitHub Copilot with VS Code

This document describes how to enhance your coding by using the GitHub Copilot VS Code extension in a Domino Environment.

Prerequisites

Make sure that GitHub Copilot and VS Code are installed and configured according to the Use GitHub Copilot via a VS Code extension documentation in the Admin guide.

Start VS Code

Here is how to start coding with VS Code:

  1. Create a new VS Code Workspace in a project of your choice.

  2. Choose the Environment you created that had Copilot installed.

  3. Click Launch.

Authenticate with GitHub

Once your Workspace starts, you should see a pop-up in the bottom right corner prompting you to authenticate with GitHub to activate Copilot.

  1. Click Sign in to GitHub.

  2. Click Allow on the prompt that follows.

    Allow GitHub Copilot Sign in

    A new prompt will appear with a code to copy and a button that will open a new tab and navigate to the correct GitHub login page.

  3. Click Copy & Continue to GitHub.

    Copy and continue to GitHub
  4. Click Open on the new prompt asking for permission to open the login page.

    A new tab will open and prompt you to log in to GitHub.

  5. Log in to a GitHub account that has an active Copilot subscription.

  6. Paste the code you copied from the earlier prompt and click Continue.

    Device Activation
  7. Click Authorize Visual-Studio-Code on the new page asking for authorization to use Copilot.

    Authorize Visual Studio Code

    A page will appear indicating that your device was authenticated successfully.

Confirm that Copilot is ready

After authenticating, a small GitHub logo should appear in the bottom right corner of your VS Code Workspace UI.

  1. Click the logo to see the Copilot status menu.

  2. The command bar should pop down and show Status: Ready.

You can also use this menu to open the Copilot extensions or logs.

Start writing code with Copilot

Open a code file and start writing code. While doing so, prompts from Copilot will appear that you can automatically add by pressing Tab.