Install and set up the GitLab plugin for JetBrains IDEs

Download the plugin from the JetBrains Plugin Marketplace and install it.

Prerequisites:

  • JetBrains IDEs: 2023.2.X and later.
  • GitLab version 16.8 or later.

If you use an older version of a JetBrains IDE, check the version compatibility list on the marketplace listing. It contains a table of plugin versions and their supported IDE versions.

Enable the plugin

To enable the plugin:

  1. In your IDE, on the top bar, select your IDE’s name, then select Settings.
  2. On the left sidebar, select Plugins.
  3. Select the GitLab Duo plugin, and select Install.
  4. Select OK or Save.

Connect to GitLab

After you install the extension, connect it to your GitLab account.

Create a personal access token

If you are on a self-managed GitLab instance, create a personal access token.

  1. In GitLab, on the left sidebar, select your avatar.
  2. Select Edit profile.
  3. On the left sidebar, select Access tokens.
  4. Select Add new token.
  5. Enter a name, description, and expiration date.
  6. Select the api scope.
  7. Select Create personal access token.

Authenticate with GitLab

After you configure the plugin in your IDE, connect it to your GitLab account:

  1. Go to your IDE’s top menu bar and select Settings.
  2. On the left sidebar, expand Tools, then select GitLab Duo.
  3. Select an authentication method:
    • For GitLab.com, use OAuth.
    • For self-managed and GitLab Dedicated, use Personal access token.
  4. Provide the URL to GitLab instance. For GitLab.com, use https://gitlab.com.
  5. For GitLab Personal Access Token, paste in the personal access token you created. The token is not displayed, nor is it accessible to others.
  6. Select Verify setup.
  7. Select OK or Save.

Install alpha versions of the plugin

GitLab publishes pre-release (alpha) builds of the plugin to the Alpha release channel in the JetBrains Marketplace.

To install a pre-release build, either:

For a video tutorial of this process, see Install alpha releases of the GitLab Duo plugin for JetBrains.