-
-
Notifications
You must be signed in to change notification settings - Fork 120
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Peacock writes colors on open or reload when no peacock color is chosen #480
Comments
Thank you @talamaska for creating this issue! |
Fantastic ! Thank you for the great information on this. I was able to repro this in the video below. It seems that when starting VS Code (or reloading) that Peacock is checking if there is a color, and if so, it activates its logic. I will dig into this to find out why. I would expect that if no color is set that it would not activate its logic, as you mentioned. But I suspect there is more to this ... so let me circle back and see what I can find. |
I found why this is happening.
As peacock is installed 1.4 million instances of vscode, I did not want to have a breaking change to existing users. This logic was put in place to help automatically migrate users from older versions to newer ones. I will remove this when we go to version 4, which may be about time. Why does it exist?
The idea here was to help users migrate, without them needing to do anything. Thus, after time, most users would already be migrated. This plan seems to have worked very well as this is the first issue in more than a year on this topic. Is it needed anymore?I could remove this logic and shift to version 4 now, as it would be a breaking change. And my gut says it is time (almost 2 years since v3). This is the only change driving a new version at this time, so that Is something to consider. I could also modify the logic to not check for the existing derived colors, which is what you are running into. This logic exists as a reasonable way for Peacock to determine if it should apply a color. But w/o this logic, it would be difficult to make a reasonable color choice. So I am leaning to deprecating the code. But before I do this, I want to keep checking to make sure it doesnt affect anything else. |
fixed in #481 |
Re-opening as this solved one part of a problem, but the logic still exists for good reasons to clear the settings. For now, it is unavoidable that Peacock when enabled will clear all workspace customizations in the local settings.json file. I will add this to the documentation. If you wish to set your own colors, you will need to disable Peacock. staying open til I set the docs. |
Seems reasonable. This is what I did actually. Disabled Peacock. The problem with peacock is that I'm unable to create such the as the previous screenshot. Anyways looking for the future version. I did not encounter this problem before, because I never tried to set my own colors to create such theme. If I use peacock only to set the theme color everything is fine. I wonder if it is a better solution for peacock to store 2-3 colors instead of just one. Sure that might be overwhelming and will make it difficult to set via the vs code menu. |
Appreciate the feedback on this. Closing this as given the explanations above. |
@johnpapa - Sorry to comment on a closed issue, but was wondering if there is any possibility of an alternative here? But for all my other projects/workspaces, I do want to continue using peacock. Ideally there would be some way to opt-out of this extension in |
I tried out Peacock and immediately came across this issue. I wanted to modify some of the color values created by Peacock but it kept restoring them. I removed the {
,
} The file didn't exist before but apparently, Peacock always leaves the comma in. While I tried to understand the reasoning above, to me, this "all or nothing" approach is a non-starter. I suggest a mandatory setting for Peacock to operate in the first place: "peacock.enable": true For those reasons, unfortunately, I will not continue to use this extension. I will now create a configuration for each of my workspaces and then uninstall Peacock. After it is no longer active, I will remove any Peacock related setting from the workspaces, leaving nothing but the color configurations. I'd be willing to support you in creating issues if you were to modify the behavior and also test it afterwards. |
I would like to call out that is is still super annoying. I have an open source repository where I like to set very specific editor colors to match the branding of the project. It is mostly just me that works on the repo, but there are a few others - but I do work on multiple computers. I try to disable the extension for this repo, but over time as I change computers etc.. this annoyance keeps creeping up. Here is all I would like: Here is the change made every time the extension loads and I have to revert that change over and over. (which I am expert at now! 🥷 ) "workbench.colorCustomizations": {
- "activityBar.activeBackground": "#111827",
- "activityBar.activeBorder": "#3FD9EC",
- "activityBar.background": "#111827",
- "activityBar.foreground": "#e7e7e7",
- "activityBar.inactiveForeground": "#e7e7e799",
- "activityBarBadge.background": "#3FD9EC",
- "activityBarBadge.foreground": "#111827",
- "statusBar.background": "#111827",
- "statusBar.foreground": "#e7e7e7",
- "statusBarItem.hoverBackground": "#626d86",
- "titleBar.activeBackground": "#111827",
- "titleBar.activeForeground": "#e7e7e7",
- "titleBar.inactiveBackground": "#11182799",
- "titleBar.inactiveForeground": "#e7e7e799",
- "sash.hoverBorder": "#111827",
- "statusBarItem.remoteBackground": "#111827",
- "statusBarItem.remoteForeground": "#e7e7e7",
- "commandCenter.border": "#e7e7e799"
+ "activityBar.activeBorder": "#3FD9EC"
} |
Versions (please complete the following information):
Describe the bug
I have edited manually colors to this
I don't have peacock.color setting.
After i close and then start the VS code again, colors are reset to something different and the peacock.color is set to something that I have not choose.
To Reproduce
Copy the setting I have placed there
Expected behavior
I don't expect peacock to invent some color and change the look of my editor even if the plugin is enabled.
Screenshots
![image](https://user-images.githubusercontent.com/299973/142068048-cfa8f9b2-3ace-41d5-a68a-a564a50cd464.png)
![image](https://user-images.githubusercontent.com/299973/142068223-fe4a18ea-a87a-4f79-82a6-defe177227db.png)
The text was updated successfully, but these errors were encountered: