2022-11-01

How to avoid VSCode from overwriting workspace settings while have settings sync on

I have (builtin) settings sync on in VSCode. For various workspaces I use the the workspace settings to give titleBar of each workspace a different color for easy recognition. However everytime I re-open a workspace (for which I set workspace settings for titleBar colorCustomizations) VSCode tries to overwrite the values in workspace settings.json into the ones used in user settings.json.

Example the workspace settings.json I set for the workspace:

{
  "workbench.colorCustomizations": {
    "titleBar.activeBackground": "#f558be",
    "titleBar.activeForeground": "#ffffff",
    "titleBar.inactiveBackground": "#f424ac",
    "titleBar.inactiveForeground": "#cccccc",
    "editorGhostText.border": "#d94e4e",
    "editorGhostText.foreground": "#b95454",
  },
}

Which at re-opening are overwritten and thus changed into:

{
  "workbench.colorCustomizations": {
    "editorGhostText.border": "#d94e4e",
    "editorGhostText.foreground": "#b95454"
  },
}

I tried setting:

  "settingsSync.ignoredSettings": [
    "workbench.colorCustomizations"
  ],

in User settings, but that seems only works on user settings, as it does not solve my issue. The settingsSync.ignoredSettings, which might solve my issue, can not be set on Workspace settings.

How can I avoid VSCode trying to overwrite my workspace settings?



No comments:

Post a Comment