question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Only update settings when the user explicitly selects a favorite color

See original GitHub issue

The problem

While I fully understand that this extension is intended for workspace specific usage, I have set my colors in the user settings (globally). User settings are stored in the following locations (outside the workspace):

  • Windows %APPDATA%\Code\User\settings.json
  • macOS $HOME/Library/Application Support/Code/User/settings.json
  • Linux $HOME/.config/Code/User/settings.json

Every time I open a new instance of Visual Studio Code, my local (workspace) settings.json file is overwritten by my user (global) settings. Often, I collaborate on projects that source control the settings.json file. This is very frustrating, as I always have to manually discard these changes.

image

Ideally, I could use this extension to colorize my IDE with only needing to set my user settings. Then I could set my workspace settings.json later, individually when I need to.

The solution

The solution is rather simple. I would love for this extension to only write to the workspace settings.json file when the user explicitly selects a new favorite color. This would prevent the need to manually discard implicit changes that occur when opening the IDE with user settings, and the extension overwrites the workspace settings.

Describe alternatives you’ve considered

An alternative, but more complex option would be to calculate deltas on global settings, and let them override workspace settings – taking on an aggregate color scheme for example. In this scenario, if the user has some colors from the user settings that are different than the colors in the workspace, take all colors from the user and remaining colors from the workspace - use that as the theme.

Additional context

Here is a list of related issues, as they exist today. It appears as though there is a misconception around the intent of this extension. Again, I understand it was initially designed for workspace only - but since Visual Studio Code lets developers specify user settings, those should be accounted for.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:6 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
johnpapacommented, Mar 8, 2020

Thanks.

I feel this is out of scope for peacock and not something I’ll be adding to it.

Managing settings (various types exist - default - user - workspace ) is quite complicated. The code reflects this now. Having this new behavior would fundamentally change how parts of peacock work and user expectations.

I recommend that if you want user settings that you grab the colors form peacock that you want, save those in settings, then remove peacock.

1reaction
johnpapacommented, Mar 2, 2020

Thank you @IEvangelist for creating this issue!

Read more comments on GitHub >

github_iconTop Results From Across the Web

User and Workspace Settings - Visual Studio Code
Some settings can only be edited in settings.json such as Workbench: Color Customizations and show a Edit in settings.json link in the Settings...
Read more >
Set user preferences - Azure DevOps - Microsoft Learn
Learn how to change a user's picture, preferred email, and other user preferences from the user's Azure DevOps profile.
Read more >
Dark theme - Android Developers
Your themes and styles should avoid hard-coded colors or icons intended for use under a light theme. You should use theme attributes (preferred)...
Read more >
Applying color to HTML elements using CSS - MDN Web Docs
The background color to use in areas of the element that have no foreground ... Notice that we're not explicitly setting the text...
Read more >
Set Chrome policies for users or browsers - Google Support
Many settings allow you to enforce a policy that users cannot change or set a ... only to either affiliated or unaffiliated users...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found