Skip to content

fix: Update AI enable setting with correct config target

Paul Slaughter requested to merge 1030-fix-ai-enable-setting-config-target into main

Description

This MR fixes a problem where the gitlab.aiAssistedCodeSuggestions.enabled will get written to the workspace settings upon toggling the status bar. This can sully the git status.

To fix this problem, we introduce a helper getConfigurationTargetForKey, which can detect the best place to override a settings value.

Screenshots

  • When there's a .vscode/settings.json present, it will update that value.
  • Otherwise, it will update the user setting.

20230914_demo

References

#1030 (closed)

Edited by Paul Slaughter

Merge request reports