-
Notifications
You must be signed in to change notification settings - Fork 28.1k
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
Consistency with the use of "workspace" #77718
Comments
I think we have to be careful to call this "multi root workspace" because you can easily have just one (or actually no) folder in a workspace file. The use case is still that it allows you to store workspace settings for this folder without polluting the folder with a |
Yeah, naming this will be tough. Although I do think that consistency across the UI is more important than the naming itself. What about referring to everything as "Projects", and then in the recent list widget, for example, changing the heading to "Projects", and giving those projects a suffix "Workspace" for Same goes for the settings... "Workspace" and "Folder" settings, with "Folder" always being used to refer to settings that exist inside a And then when enabling/disabling extensions, "enable for this project". |
But why would we introduce something new ("Project") that was never used in VSCode so far at all? I do not want to bring in the notion of projects because the next question will be, what kind of project systems we support etc. |
Another option: In the recent list widget, separate them out into two different headings: "Workspace" and "Folder", and remove suffixes all together. Again, "Workspace" and "Folder tabs in the settings, with "Folder" always being used for settings coming from the For enabling/disabling extensions, I suppose it would need to be dynamic. "Enable for this workspace" when a workspace is opened, and "Enable for this folder" otherwise. At this point, I'm starting to confuse myself, lol. |
We decided to call both single folders and workspace file the "workspace" you are in. You could name the one "single-folder workspace" and the other "multi-root workspace", but then again, a multi-root workspace can have 0-1 roots too. |
What about the UI inconsistencies mentioned above?
|
"Open Workspace" and "Open Folder" are still there so that we can filter the dialog. With our custom dialog it would probably be possibly to be smarter here. I refer to @sandy081 for settings. |
Yeah, I definitely understand the need to filter the dialog, but again, this is a UI inconsistency that is going to confuse users. At times, both are being referred to as a workspace. At other times, the UI is using the term workspace to refer only to projects associated with a I think, looking through the forum posts that I linked to, it's clear that this has become a confusing issue. Even the answers to those questions are all over the map. And the UI inconsistencies are the biggest cause of this confusion. |
Expanding on earlier suggestion:
|
I agree it makes sense to call settings from a folder always Folder settings which makes it consistent across single folder and multi root folder workspace. @roblourens FYI |
I think it would make a lot of intuitive sense to explain that VS Code assumes that any opened folders are an implicit workspace and that we have the ability to create an explicit workspace as a Something like this: I suggest we use implicit workspace and explicit workspace to differentiate between the two use-cases. |
I wouldn't mind to see With that in mind, some people may choose to run a single project per workspace. That's up to each person to decide how they want their root. |
I just submitted a PR to address the documentation side of this issue: microsoft/vscode-docs#3154 . Please consider it. |
This feature request is now a candidate for our backlog. The community has 60 days to upvote the issue. If it receives 20 upvotes we will move it to our backlog. If not, we will close it. To learn more about how we handle feature requests, please see our documentation. Happy Coding! |
🙂 This feature request received a sufficient number of community upvotes and we moved it to our backlog. To learn more about how we handle feature requests, please see our documentation. Happy Coding! |
While reading the following, keep in mind that I write this to point out my confusion about VS codes "workspace" concept and the term they are using for it. I just came across this since I opened our project (single folder project) as workspace and my extensions stopped working:
That makes absolutely no sense to me. Why is a single folder project not a workspace? Why are extensions not working in a workspace? If this "workspace" concept is so useless, then why is VS code trying to force users to save a workspace file for projects? Every other IDE I worked with before had such a "workspace" file. But it was always referring to a single folder project. I intuitively expected that this is the same with the VS code workspace, but it is not. It only starts to make sense with multi-root workspaces. Could someone explain to me how such a multi-root workspace is meant to work? Given multiple different Git projects that should all use the same VS code settings, extensions and launch configs.. how to combine this. Does the multi-root workspace with settings get an independent Git repository? Don't forget that extensions stop working as soon as we start using a workspace... What a confusing mess. |
Well, obviously there is a lot of confussion around the concept of Workspace The only thing that would make sense to me is a workspace has its own launch configurations, git configurations and the opened files you are working on in that workspace so you could have different independent projects in the same window. Switching the workspace in that window would switch the files you are viewing and the configurations you have available. It seems obvious, I don't understand all the confussion. What do you think of that? |
Related to microsoft/vscode-docs/issues/3547 |
I agree that something should be done in order to clarify the difference between workspace settings and folder settings. |
As a first step I pushed the following changes:
If you never had a workspace open, you will just see this as a result: In our UX discussion yesterday we feel that separating folders from workspaces in that list is not a good idea because this breaks the support for quickly jumping between the "thing" you had opened most recently. There is still the question wether we should refer to "Folder" for setting related things or keep using "Workspace" even when a folder is opened. I think this needs a bit more discussion. While I find it easy to argue that the settings editor should talk about "Folder" and not "Workspace" when a folder is opened, I wonder if an action such as I have similar problems with renaming "Go to symbol in workspace" to "Go to symbol in folder" depending on what is opened tbh. |
After discussing this more in the team, we feel that simply changing "Workspace" to "Folder" everywhere in our UI depending on wether you have folder or a workspace open is more confusing than helpful. For many users that don't care about multi-root workspaces or are simply new to VSCode and only feel comfortable opening folders, a folder really is their workspace. Also, we cannot control how extensions refer to the workspace depending on context: many extensions already use the term "workspace" for when the user has a folder opened and we would introduce more inconsistency if we changed it in the core of VSCode. In retrospect, I think we should have probably called "multi root workspaces" in VSCode something different that is not "workspace". We discussed calling it "Project" but then were afraid people would expect VSCode to have a full blown project system (which it does not have). If there is still a very obvious issue with the use of "workspace" vs "folder", I am happy to fix that (e.g. as I outlined in #77718 (comment)). Next plan of action:
@jabacchetta as author of this issue, does that make sense? |
Making the best possible decisions based on past bad decisions is the path towards the descent to a bloated and poorly explained VS Code. I urge you to think from first principles and don't treat the symptom, but the cause. If, in retrospect, a "multi root workspace" should have been called something else, please call it something else - even if, for a few moments, users will be confused. This will be better for the future of VS Code. |
I too would like VS Code core and its documentation to use the term "workspace" only for the thing that gets loaded from a .code-workspace file. The File menu (on Windows at least) already distinguishes well between Folder and Workspace. If a user (even a new one) opens a folder, then that's what they're working in - a folder. I don't see any benefit in encouraging them to think of a simple folder as something called a workspace. Reserve that term for what were originally called multi-root workspaces. Yes, there'll be a bit of confusion / pain for some as the terminology evolves, and some extensions might fail to keep up with the change, but I think the end result will be a lot easier to understand for future generations. |
@bpasero How about "multi root workspace"? |
@andrecasal @gjsjohnmurray how do you suggest we fix all the extensions that are out there to call their user facing things "workspace" or "folder" depending on wether the user has opened a folder or a workspace? I think that will not be easily possible. If we change something in VSCode (either call it "Folder" or call workspaces "Projects"), we need extensions to update too, no?
You can have a workspace file opened that has no folder in it, so in theory it is a 0-root workspace, as such "multi root" might be misleading. |
As developers of VS Code you should do your best to help extension developers, but it's our responsibility, as extension developers, to update according to VS Code, not the other way around. |
Our data shows that the majority of people use VSCode with folders and not with What if we pushed for a change that only impacts the minority with the goal to make things clear. I.e. refer to I feel that route would still resolve the confusion and has minimal impact to the majority of users and/or new users. I also feel that the term "Workspace" is an accepted term for something you work on in VSCode. Imho the confusion only started to emerge when we gave |
@bpasero in other words Folder and Xyz would both be types of Workspace. Yes, this makes sense to me. I think Project works. It's a sufficiently generic term to mean we can still push back if people start saying "but a VS Code Project should do A, B and C as well", with the response "that's not in scope for what we're calling a Project - it's a candidate for an extension". |
Personally, I can confirm this. I also understand your objection to the "Multi-root workspace", and I can't stop think about calling the |
One thing to keep in mind is that the file extension |
The current state of affairs is quite complicated and I believe this problem has been dragging for so long because there isn't a clear definition of what the problem actually is. Allow me to try and shed some light. Let's clarify a few definitions. Instance and FolderInstance is the running VS Code instance where folders are opened. Types of settingsUser type settings apply to all running instances of VS Code. Cascade of settingsThe global
VS Code ModesSingle Folder Workspace mode is an instance of VS Code where a folder was opened directly (without adding it through the file explorer). Settings cascade:
Implicit Workspace mode is an instance of VS Code where a folder was added/removed from the file explorer (without having opened it directly). Settings cascade:
Explicit Workspace mode is an instance of VS Code with zero or more referenced folders in a .code-workspace file. Settings cascade:
An Implicit Workspace with a single opened folder and a Single Folder Workspace are essentially the same thing - an instance of VS Code with a single folder opened in the explorer. But they work differently. In the latter, instance type settings in SuggestionThe global Please notice that all this discussion was had without using the concept of "workspace" except to distinguish between VS Code modes - but those could have easily been called mode A, B and C. The reason for not using the concept of workspace is because it isn't a useful concept in this context. I suggest we do away with the concept altogether. |
I think you don't have to explicitly distinguish I am not sure the term Settings are more complicated than that actually, because individual settings can be
|
@bpasero it is very useful to read what you write here. And I never would know this if not subscribing to this topic. I can't find this in the VSC documentation, but I think it would be great to find it also there. Could you consider in the team to explain this also in the documentation? Maybe not all details, but users could get a better understanding about settings, folders, untitled and explicit workspace. |
Yes I was planning to update our docs to make this clear. |
We now have a document explaining the concept of workspaces in VS Code: https://code.visualstudio.com/docs/editor/workspaces If there are no objections, I will go ahead and close this issue. We will link to that document throughout our documentation so that people can easily find it. If you have feedback on the topic, feel free to open a PR for this site at https://github.com/microsoft/vscode-docs/blob/master/docs/editor/workspaces.md Thanks! |
Hello @bpasero thank you so much for this, and in particular for this text:
This text will clear up so much confusion and improve the day one experience of old school Java developers used to IDEs. I am also working on a PR to help those old school folks even more. I'll link it here. |
Problem
Developers don't know what a workspace is. Here's my recent attempt to clear up the confusion.
Confusion
The recent list widget groups folder workspaces along with
.code-workspace
workspaces under a "workspace" heading, indicating that everything in that list is a workspace. Then it gives.code-workspace
workspaces a "Workspace" suffix, contradicting the header, and indicating that only those workspaces that are associated with a.code-workspace
file are true workspaces.The first interaction with the term "workspace" for most developers is going to be the workspace settings. This is setting up users for confusion right off the bat. Because a folder's
.vscode
settings is initially referred to as "Workspace" settings. But when a.code-workspace
file is created,.vscode
settings becomes "Folder" settings, while the.code-workspace
settings becomes the new "Workspace" settings."Open Workspace" is referring to a
.code-workspace
workspace (with the dialog only allowing a.code-workspace
file to be selected). Same goes for "Add Folder to Workspace..." and "Save Workspace As...".An extension's "Disable (Workspace)" option is referring to workspace as defined by my definition in the SO post.
Suggestion
NOTE: Suggestions will be updated as discussion in this thread evolves.
.code-workspace
settings. "Folder" tab for.vscode
settings.The text was updated successfully, but these errors were encountered: