Skip to content

feat: Prompt user to enable code suggestions on GitLab login

Sri Rang requested to merge feat-code-suggestions-commands into main

Description

  • Hooks into the GitLab authenticate flow
  • Triggers the CodeSuggestions OnboardingService
  • OnboardingService   - Checks if valid GitLab account exists   - Quits if user already has code suggestions enabled in userpreference   - Quits if user has chosen not to be prompted again   - Shows the prompt:     - If user select enable:       - Calls the API to save user preference     - If user selects skip:       - Saves the user preference not to be prompted
  • Added methods in GitLabService to manage relevant API calls
  • Added setting to save user's choice not to be prompted again
  • Resolves:   - #1115 (closed)   - #1116   - #1117

Related Issues

How has this been tested?

  • Tested by human eyes 👨 👀 manually
  • Unit tests

Steps

  1. In VS Code, log out of the GitLab plugin
  2. Perform the GitLab oauth
  3. After login, you will see the "you are logged in prompt", close this prompt, and you should see the enable/disable prompt if you have code suggestions disabled
  4. If you already have code suggestions enabled, you will see the "code suggestions enabled" confirmation

Screenshots (if appropriate):

New setting to save user's choice whether to be prompted or not

image

Prompt

image

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation
  • Chore (Related to CI or Packaging to platforms)
  • Test gap
Edited by Sri Rang

Merge request reports

Loading