microsoft / vscode

Visual Studio Code
https://code.visualstudio.com
MIT License
164.53k stars 29.4k forks source link

Support workspace projects / folders under different colors in sidebar and tabs #31308

Open RobertoMalatesta opened 7 years ago

RobertoMalatesta commented 7 years ago

Workspace feature is really useful as it is today, but could themes API be extended so to display different projects with different colors/nuances?

See:

projects_with_colors_in_vsc_workspace

It would be even better if tabs could have different colors, to resemble the project they belong to:

projects_and_tabs_with_colors_in_vsc_workspace

Thanks for all the beautiful code and the effort you put in this superb project.

Roberto.

johnbrett commented 7 years ago

I think this would be an awesome addition - one additional request I would have on this is that we could set colours, or underline to highlight a project's root, as when you have many they are hard to distinguish which is root at a glance, something like:

image

If this would be possible, I would be happy to work on a PR for this if someone could give me pointers!

jpike88 commented 6 years ago

+1 on this. juggling projects in multi-root workspaces needs more distinction between the projects.

spersico commented 6 years ago

+1. This would be great!

jpike88 commented 6 years ago

This is actually starting drive me insane, I think this should be given way more importance. I also think this color coding should show up in quick search results.

malutanpetronel commented 6 years ago

+1 Found this very important ! See Netbeans to find more details on how it works

infoflocrm commented 6 years ago

Yes really need this feature. .vscode setting should picked up in this case but its only works when you open as a folder not as workspace.

Tab color should be adjustable via .vscode settings in each project in workspace and one that does not have that settings should use default theme color settings, like same time with workspace folders we open files from ftp. Ftp files should use default settings. Thanks.

logicbomb421 commented 6 years ago

Yeah this would make a huge difference for me as well. Would love to see this in an upcoming build!

rjzheng commented 6 years ago

+9001 this would be provide a much better dev experience!!

RuiffCardoso commented 6 years ago

I was looking for this as well, would be great for my multi-workspace setup.

nhuesmann commented 6 years ago

I could really use this for an app I'm currently working on, please make it happen MS!

hdd113 commented 5 years ago

+1

schwab commented 5 years ago

Found this while searching the same feature.

For a little context as to why this is so important... when debugging installed python packages with the launch setting "debugStdLib": true, the debugger automatically opens up files from your lib directory even though the breakpoint is set on your local file. This means you end up with files like ~.local/lib/python3.6/site-packages/... opened in what used to be just your local project. This allows debugging and stepping through the installed code which is probably good since it's possible the running files are different from your local dev project files, BUT when you decide to make a change to the code, you have remember to change over to the local files in the current project director, not the lib files. This Texas Two-Step (debugging one file, but having to change to the other file for editing) has made many a developer loose code changes since the next build/install overwrites the lib packages with local files you thought were edited.. Naturally, we want to edit the same file we found the bug in, right?

Well, if there was a way to set warning color on all ~.local/lib... files, then you'd at least have a visual indicator you're doing something bad.

So, here's my +1, though I wonder if this could be done through an extension. Continuing to search...

lamnguyenx commented 5 years ago

Hi there,

It'd be really wonderful if VSCode supports this feature! I've switched from Atom and planned to stay with VSCode in next 3 - 5 years ;)

invasionofsmallcubes commented 5 years ago

Absolutely agree, I'm having the same issue. I have some configuration files that are the same for different projects, it would be awesome to distinguish them in some way. (you can go with the mouse over the tab to see the path, but it's not really a direct approach).

nicolashardy commented 5 years ago

That would be awesome. Does anyone know a workaround in order to get this result?

oreporan commented 5 years ago

I've built a vscode extension that does exactly this (and a bit more) Built for people who have monorepos or large projects and want to distinguish files/folders easily.

its called ColorTabs

It can color the tab/title-bar and add a label based on a regex that you provide

https://marketplace.visualstudio.com/items?itemName=orepor.color-tabs-vscode-ext

schwab commented 5 years ago

thank you @oreporan. Installed it and it's working great. In my case I set it up thusly: "colorTabs.titleBackground": true, "colorTabs.config": [ { "regex": ".*/site-packages/.*", "color": "#dd3333", "label": "SITE-PACKAGES" } ]

Which turns my title bar Red when I'm editing a python site-packages files. Since those are overwritten by a build, this is a good way to prevent code loss. Have already shared with others on my team, they are all :+1:

oreporan commented 5 years ago

Glad it works for you - didn't even think about that use-case! makes sense to add some label for build/, dir/ out/ etc!

Feel free to ⭐️ it in the marketplace if it helped you out :)

malutanpetronel commented 5 years ago

... "colorTabs.config": [ { "regex": "./site/app/.", "color": "#dd3333", "label": "app" }, { "regex": "./site/src/.", "color": "#991111", "label": "src" } ]

for some reason, this config does not apply anymore... However, somehow the site/app/* have all a red background at the top when opened which cannot be changed

oreporan commented 5 years ago

@malutanpetronel It would be better to post this under https://github.com/oreporan/color-tabs-vscode/issues/ But in your case, its probably that the regex is wrong, did you mean to do ".*/site/app/.*" ?

malutanpetronel commented 5 years ago

yes

oreporan commented 5 years ago

@malutanpetronel so did changing the regex work for you? if not you can open an issue and I'll take a look, though its pretty straight forward, if the file/folder matches the regex, it will work

malutanpetronel commented 5 years ago

something not ok... now even if I uninstall colortabs extension, the title bar remains red

oreporan commented 5 years ago

the extension changes the color by modifying the titleBar Go to workspace settings and look for workbench.colorCustomizations You can delete that line completely

eine commented 5 years ago

I think this would be an awesome addition - one additional request I would have on this is that we could set colours, or underline to highlight a project's root, as when you have many they are hard to distinguish which is root at a glance, something like:

Ref #74229.

I've built a vscode extension that does exactly this (and a bit more) Built for people who have monorepos or large projects and want to distinguish files/folders easily.

It can color the tab/title-bar and add a label based on a regex that you provide

Ref #76399.

LucaGabi commented 4 years ago

please also read this feature request here: #95182 in my opinion it is similar request with less clutter

SDAdham commented 1 year ago

Hello team, any news about this coming to vscode?

We tried the colortabs extension but it's not working for us. The colors only changes when switching tabs which still defeats the purpose of having colorful tabs to easily determine which tab belongs to what before selecting the tab.

We have #167205 which received high votes as well.

jdreina7 commented 1 year ago

Hi! There's any news about this feature??? We really need it pls @VSCodeTriageBot

MattyMags commented 1 year ago

Why is this still not a thing yet? Its been 5 years. So aggravating. There are so many issues asking for this feature and nothing ever gets done. About to abandon Microsoft once and for all.

dilirity commented 1 year ago

Hey! Just found this thread. Sad to see it's been 6 years and this hasn't shipped.

There are a few extensions, but they are limited.

Any ETA on this?

muditdev commented 1 year ago

well i am using this extension working well for me

https://marketplace.visualstudio.com/items?itemName=orepor.color-tabs-vscode-ext

dgtvan commented 10 months ago

The extension ColorTabs is great, however, what it provides differs from what is described in this thread.

Still looking for a way to color project files using different colours.

McDusty commented 9 months ago

I would like to upvote this feature request. ColorTabs looks like a cool extension but it only works on windows. Mac users are are out luck. I would very much like to color my tabs to denote important files I want to reference.

neilyoung commented 6 months ago

well i am using this extension working well for me

https://marketplace.visualstudio.com/items?itemName=orepor.color-tabs-vscode-ext

Seems to not work on Mac

neilyoung commented 6 months ago

My two cent here: It is rediculous to see that such a useful feature request remains unresolved for that long, while I'm getting updates every month, I will never ever use in my life.

nullbio commented 6 months ago

Just for record, #213003 is not a duplicate of this issue and is referring to filename colors based on a regexp match (for example, applying text color to all hidden files via \.+, not projects.

dimateos commented 5 months ago

Wanted to summarize a bit the status of this long-pending issue. Best regards!

Coloring tabs: existing extensions

This solution is very nice for a visual reference when you are inside potentially dangerous sources etc. But does nothing to inactive tabs nor file tree text area. I guess it resorts to editing local config files dynamically based on current active file path.

This one can edit the style of inactive tabs image

Both extensions are a nice start and one could contribute to it, but it would be much preferable if they were built-in. For example, the second one is severely lacking:

Coloring filenames in file explorer: an example

I guess there is no API for this, I could not find any extension.

See the following example. IntelliJ has a limited predefined set of groups, nonetheless I would implement a general solution for any file/folder. image

Conclusion

Overall it seems like vscode is lacking the required API / settings:

In both cases, I would expect at least customizable text and bg color, but there could be more style properties like font family, size, etc. Moreover, there could also be many feature around them (e.g. context menu to set tmp color), but I think a static setting should be first.