Open kdubuc opened 6 years ago
@wkoutre - you suggested enabling 'Native Full Screen', but in your screenshot you have 'Native Tabs' enabled and 'Native Full Screen' is actually disabled. So I think there's a mix-up somewhere there :)
@wkoutre A nice alternative solution! (1.29.1) It just switch from "multiple workspaces in the same window" to "one workspace in the multiple windows".
@shane-smith Good catch! My mistake -- updated the post. Thanks!
Huge desire for this feature. I also with multiple projects and I love the context that VS Code provides for a workspace. The terminal for instance. It's painful to switch workspaces and loose what I've been doing in the terminal. I also have my VS Code window full screen with my Docs beside it. I hate having to switch desktops to get to different projects.
That would be a great feature to switch, for instance, between clients.
+1 Would definitely use this feature. @wkoutre’s suggestion is useful but would be nice to have it baked into the editor!
Aaaand....it doesn't work...you publish an article in 2017 and still it doesn't work https://visualstudiomagazine.com/articles/2017/11/10/vs-code-1-18.aspx
EDIT: In version (November 2018 (version 1.30)) i can't open more then one workspace, but can add to this workspace more than one folder...
Why is this not a thing yet? This is ridiculous
Aaaand....it doesn't work...you publish an article in 2017 and still it doesn't work https://visualstudiomagazine.com/articles/2017/11/10/vs-code-1-18.aspx
EDIT: In version (November 2018 (version 1.30)) i can't open more then one workspace, but can add to this workspace more than one folder...
Your edit is what that article is referring to: multi-root / multi-folder workspaces (still one workspace in the editor at a time). So what Visual Studio Magazine published works as described.
It looks like Visual Studio Magazine isn't affiliated with VS Code or Microsoft, by the way.
While it likely has absolutely no impact, I've withdrawn my own upvote for this as I no longer see the benefit for the feature. I've been able to achieve everything I want to achieve using existing functionality, and I can't see a single compelling reason above.
^ Just an opinion on the Internet. If you disagree, I'm happy to hear why.
EDIT: This request is currently rated 36 when sorting by most thumbs-up reactions, so I'd say that indicates the majority think 35 other features are more important than this one, which lowers the likelihood of the VS Code team considering this any time soon.
Aaaand....it doesn't work...you publish an article in 2017 and still it doesn't work https://visualstudiomagazine.com/articles/2017/11/10/vs-code-1-18.aspx EDIT: In version (November 2018 (version 1.30)) i can't open more then one workspace, but can add to this workspace more than one folder...
Your edit is what that article is referring to: multi-root / multi-folder workspaces (still one workspace in the editor at a time). So what Visual Studio Magazine published works as described.
It looks like Visual Studio Magazine isn't affiliated with VS Code or Microsoft, by the way.
While it likely has absolutely no impact, I've withdrawn my own upvote for this as I no longer see the benefit for the feature. I've been able to achieve everything I want to achieve using existing functionality, and I can't see a single compelling reason above.
- Just open multiple workspaces and switch between them using Cmd+Tab or Window menu (macOS) / Alt+Tab or Taskbar (Windows). It takes a second and would actually be faster than trying to collapse the tree in the side-panel just to find the relevant workspace node.
- Would you really prefer this over every other feature or bug fix that the team could be working on instead? If so, why not submit a pull request?
^ Just an opinion on the Internet. If you disagree, I'm happy to hear why.
EDIT: This request is currently rated 36 when sorting by most thumbs-up reactions, so I'd say that indicates the majority think 35 other features are more important than this one, which lowers the likelihood of the VS Code team considering this any time soon.
Close workspace and open another 2 mouse clicks. Use Alt-Tab to switch between multiple VScode instance about 5-10 moves and you must press 3 buttons. It's ridiculous. Ok, let's do some calculation. I have 5 workspaces and 15 open programs. I switch between them all the time. At this moment i open 5 VScode workspaces and work in workspace#1, then i switch to program#1->3->10 and then i need go back to VScode i press Alt-Tab and see 1 icon VScode, but when i push her all my instances open at the same time and i need to hide them, because i don't need them at this moment....When i need to work in workspace#2 what i must do? Open all windows and search needed workspace? It's ridiculous and not usability way.
@Asgoret You (as are most of us here) are a power user of software.
As such, get some system-wide utility softwares (like Alfred, TotalSpaces, etc) and set up absolutely everything about each keystroke you make to your heart's content.
Everything you've written above, I can personally do on my keyboard in under 3 keystrokes - no mouse involved. Happy to share my setup, but what you're describing in your most recent comment goes far beyond the scope of this GH issue.
@Asgoret You (as are most of us here) are a power user of software.
As such, get some system-wide utility softwares (like Alfred, TotalSpaces, etc) and set up absolutely everything about each keystroke you make to your heart's content.
Everything you've written above, I can personally do on my keyboard in under 3 keystrokes - no mouse involved. Happy to share my setup, but what you're describing in your most recent comment goes far beyond the scope of this GH issue.
Eah.... I can use 3rd party software to solve this problem, but why this feature isn't ready? It's not something complicate. Just open another workspace
It doesn't seem, by your comment, that you've enabled the Window: Native Tabs feature (macOS). One window. Multiple workspaces designated by tabs at the top (same as your browser, Finder, etc.).
Also seems like you're on Windows, which explains that 😄.
If not complicated, I'll play devil's advocate and ask: Why not whip up a solution yourself and share?
Just food for thought... I, myself, haven't worked extensively with Electron and, therefore, don't know the extent to which this feature is/is not complicated.
I want to be able to open the same project in more than one window. This feature is necessary when context switching between branches of the same repo. If I need to jump from a feature branch to a bugfix or hotfix, I don't want to mingle the open files. I want to save (or persist) the open files state of the first branch, go to the *fix branch, do some work, finish it up and pick back up where I left off with the feature branch.
@jstein-ftdi - that won't work, because VS Code is directly modifying the files on the filesystem by checking out the new Git branch. So if you check it out in one place, that same branch will be checked out in all other VS Code instances. You can see this if you add the same folder to multiple workspaces.
To achieve what you want to do, you will need to have two distinct folders on the filesystem:
Then open those two folders as separate workspaces in VS Code (or just as two separate folders, as it sounds like you aren't actually using workspaces).
@jstein-ftdi Since it doens't seem like you're working on multiple branches simultaneously, why not just use... git branching? Or even git stash
?
@shane-smith & @wkoutre when i check out a new branch, files that exist in the first branch, yet do not exist in the second branch remain open, in memory. the act of checking out a new branch may modify the file contents, but it preserves the open state in the window. my current work-around is to make a new local clone of the project, but that requires double the work to make sure my clone is in sync with the remote. git stash
will not keep my open files organized. this is why i want to be able to open a new window of the same project with a different grouping of files open (preserved state remaining in memory).
@jstein-ftdi - just create two workspaces for the same folder, then. Store the actual workspace files outside of the project root.
@shane-smith that works. thanks!
After reading the comments, allow me to provide a clear example as to why I support this idea, maybe offering my perspective will allow people to see the point.
I'm working on a project that has the same folder names in different locations across multiple drives but let's take a very simple example that applies to every single personalisable application in windows. You have a 'program files' folder, this contains the program and all its dependencies, localisations and so on, and an 'App Data' folder, which contains settings, downloaded extensions or addons, logs and so on.
In my case I have much more than just 2 across multiple different drives so it's important to keep track of which directory, (Workspace), I'm in. It would be much cleaner to contain multiple workspaces in a single window,(Project), because they can be renamed and organised based on a need for good 'book keeping' if it's required. They are all a part of the same project as such I believe a feature that supports a tidy workflow, like representing each project as a window and each workspace as a directory, should be supported by the default application. Forcing users to alt-tab between different workspaces is quite disruptive and clunky. @wkoutre Yes, you can use tools and shortcuts to make alt tabbing easier, but wouldn't you rather use those same shortcuts to simply expand or collapse a targetted workspace within your project,(window), rather than having to set up tools outside of your IDE to manage your IDE? Does that not strike you as a bit cumbersome?
Another, similar suggestion, could be to impliment a folder 'nickname' feature. In this example then, using the previous scenario, I could 'nickname' each folder with tags, for example like [P] for 'program' and [S] for 'settings' Like this:
[P] ProgramName [S] ProgramName
As you can see, it is now explicitly clear which folder is which. However! Doing things this way is potentially very dangerous and more confusing than simply alt tabbing for obvious reasons. So that brings us back to the OP's suggestion of allowing for multiple workspaces in a single window which can be given custom names without the danger of confusing 'Nicknames' with actual folder names.
I 100% agree that supporting the addition of multiple workspaces would be highly beneficial.
Final note for developers: To avoid confusion, introduce 'Projects' as a concept such that the structure of each instance of VSCode is: A Project is represented as a VSCode window. A Workspace is represented as a customisable, renamable link to a directory . A Directory is represented as a branch view with itself as the root
@shane-smith Does this explanation offer a decent enough example as to why this is useful? Also, with respect, I'm not sure it's fair to criticise an idea by saying "create an extension yourself" or "I'd rather the devs focus on bug fixing". Especially with that bug comment lol. That's a criticism aimed at developer priority not the idea. You can take that criticism and copy paste it into every single feature request on every single feedback & suggestions section on the internet.
Side note (mini-rant about comment etiquette): This is a quality of life feature request. The correct implementaion of this feature would not affect or disrupt anyone who wouldn't use it. As such, making an arguement against a good idea for a quality of life feature seems quite disrespectful to the OP and those that support it especially if you're going to make flippant and dismissive remarks about using a microsoft application on windows. Non-participation in support of an idea is a statement in and of itself thus does not require an addendum. One should consider if their criticisms are valid and relevant before commenting. For instance, criticisms like: "I think this is a monumental waste of time", "I don't see the point" or "I'd rather devs spend time fixing bugs" are all valid but completely irrelevant criticisms.
Food for thought
There is an extension which somewhat fulfills my needs currently, and might sate people until official multi-workspace is implemented: https://marketplace.visualstudio.com/items?itemName=alefragnani.project-manager
While it's not exactly seamless and requires manual management (adding and removing projects is done by config), it allows quick switching between projects and keeps their state.
@rykarix I hear you, and don't necessarily disagree.
Personally, though, my desired computing experience is so custom that I can't reasonably expect every piece of software i use to accommodate my every expectation and desire. So, I use a few pieces of system tooling add-ons and customize away. Shortcuts for other shortcuts, that kind of thing. Every keystroke matters, and that's really (IMO) the only way I'll every reach my desired experience (which changes weekly, if not daily).
@Rykarix - it sounds like a workspace already fits the definition of what you've termed a project, because we can open multiple folders from all over the operating system that are related in some way.
However, it sounds like you'd still have the pain where each of those folders seems to be named identically (just with different path to get to it), making them indistinguishable from each other in the tree view - other than their contents being different, perhaps.
Not agreeing or disagreeing, just adding to your well-thought-out reply.
I would like to push this request also. The Workspace - should be a set of projects/folders plus with SETTINGS and even different extensions loaded. From this perspective the multi-root workspace does not solve all problems. Developers still need a way to quickly switch workspaces! And even more, I wish the workspace file *.code-workspace and be directly opened by double-click.
This is the one reason why I still use Atom sometimes instead of VSCode.
At work, I typically have seven or eight projects open at once. Some of them are different branches of the same git repo, others are different repos. Putting all eight projects in the same VSCode workspace is way too cumbersome, especially when opening a file by name, since each time I do this I would have to choose between multiple files with the same name (because of different branches).
On Linux, the situation isn't too terrible because I can open a bunch of separate VSCode windows, and as long as I use a window manager such as Cinnamon which allows each window to have a separate tab in the desktop task bar, I can quickly select the window and project I want using muscle memory.
But on OS X (or window manager such as Unity), it's a pain because all windows of the same application are lumped together under a single launcher icon. Trying to bring the window for a specific project to front requires a complex gesture no matter how you do it. And clicking on the windows themselves is tricky when you have eight overlapping windows that all have to fit in one half of the screen (because the other half is taken up by the output of my app).
Right now my OS X desktop has both Atom and VSCode editors open. I have three projects open in VSCode, because three windows is about the maximum I can tolerate in VSCode. The other 5 projects I have open in a single Atom window, and using their project tab-bar I can quickly select the project I want. (Deciding which projects to open in Atom and which to open in VSCode is an interesting optimization problem that depends on a lot of factors which I won't bore you with at this time.)
As far as having different prefs or venvs for different windows, I don't much care either way; I presume that the behavior of each window would be relative to whatever is in the project root directory.
It is obvious this feature is very important. Any other decent IDE has this feature. This is the only reason why I haven't moved 100% on VSCode yet. I upvote this.
I did that for Atom see :)
Bump
Do it
How the fuck is this still not part of VSCode? can somebody tag some of the developers. This was posted on Feb 8, 2018.
@mxmihai
It is obvious this feature is very important. Any other decent IDE has this feature.
PHPStorm doesn't support this either, as far as I understand, and I'd consider it to also be a decent IDE. Each project (i.e. workspace) opens in a separate window.
I think the same applies to other JetBrains products, but not as confident with those as I haven't personally used most of the others.
@shane-smith
PHPStorm doesn't support this either, as far as I understand, and I'd consider it to also be a decent IDE. Each project (i.e. workspace) opens in a separate window.
The fact that this is not in PHPStorm is not an indicator, it is a really necessary feature, when the project consists of modules and jump on modules or open all modules in separate windows... Um, thank you, but no.
In #76904, hierarchical multi-root support is suggested. I believe that such an approach, along with #76902, might fit the needs of many users, without requiring VSC to handle multiple workspaces.
The solution to this issue that I have been using successfully for several months now, is to save a new workspace for each branch/issue/feature I work on. It seemed like a burdensome way to work at first, but I quickly got used to it and quite like it as a way of keeping my work organized. Cheers!
I'm trying to standardize on VSCode, removing Eclipse, NetBeans, NotePad++, maybe even Sublime. I have a few challenges that brought me to this popular ticket. ( "Only" number 36 of over 5000? Yeah, that's popular. )
I'm not Always in one workspace. I jump around, and I don't want to have to manually close one workspace to open a new one.
For WordPress I want to apply a different set of linting/formatting rules when I'm looking at Core code, from when I'm looking at plugins. Core is formatted according to WordPress Coding Standards. Plugins don't need to follow those rules - and most plugin developers don't follow any rules at all. Some use a subset of WPCS or a standard like PSR2. In this case, if multi-root supports different workspace configs it would be OK, but I don't think it does.
Here's the biggie : While I have a workspace open, like a WordPress project, I frequently have need to open other files : INI, .htaccess, Java, Python, logs, XML sent from a client, etc. None of these are a part of the WordPress project or its workspace settings. I don't want extensions, loaded to support a single file, to remain in memory when I dismiss that file.
I'm using the SFTP extension which can be set to auto-sync files when changes are made. This is just one example of many extensions that do something like this. But without the ability to open files into a different workspace, I'm concerned that this extension will try to sync files that don't belong in a remote environment. This just reinforces the idea that different extensions apply to different workspaces.
Now, we can open multiple instances of VSCode to support these use cases. This is what I do now. But that changes usage patterns. If I want to open a random INI file, I need to drag/drop it into the VSCode instance that has no specific workspace settings. I can't just click to open it because I don't know which instance it will open in. In this scenario I'd like the ability to drag/drop into a generic workspace within a single VSCode instance, and direct any files not defined for other workspaces to load into that generic workspace whenever clicking on them in Explorer.
Finally, if using a single instance and a single workspace, any files opened in that instance are saved in the workspace configuration, and re-opened if the instance is closed and re-opened. This is always convenient when we want to preserve our workspace settings, the edit windows, etc. But when we open random files, these become a part of the workspace editor configuration. The next time I open this workspace, I don't want to see those files, so I need to close them. But I may want to see them again if I open a generic workspace, to see the most recent random files that I've needed to open.
Thanks for your indulgence.
I second the multi-workspace idea.
In the months since I posted my comment above, I have switched over to using the Project Manager extension for VSCode. This extension allows me to add a bookmark for each project, and quickly switch between them, restoring all of the editor state (including open tabs).
While I still occasionally need to access multiple projects at once, I find that with this extension I need it much less often. On those occasions where I need to cut and paste code from one project to another, I open multiple VSCode windows; but the vast majority of cases I find that just having the ability to quickly switch is good enough.
+1 This is still relevant at this time and it will be helpful to have a feature to be able to open multiple workspaces in the same window.
+1 I would love this feature
+1. We gotta be able to use multiple workspaces in the same window.
This cannot be done yet right?
@karlolopez > This cannot be done yet right?
Not yet, different workspaces still open in different VSC windows. I'm using a folders-based structure though. So my workspace config file (MyWorkspaceForTwoProjects.code-workspace) code for two different projects/folders would look like below.
{ "folders": [ { "path": "path to the project folder 1 here" }, { "path": "path to the project folder 2 here" } ] }
+1 This would be a great feature and would help quite a lot with separating projects.
My current issue is, that extensions like Intelephense (PHP code completion) suggests classes from any folder within one workspace, which does make sense somehow. If you have opened up all customer projects though, all using the same Framework, you get so many suggestions for the incorrect classes to include. Being able to separate projects into different Workspaces that I could give a name (and maybe a language tag or icon or whatever) would help a lot. Thank you very much in advance!
@bpasero Could this be possible technically?
+1 would be highly useful for my workflow
I agree that to be able to have two entirely separate workspaces open would be very useful, especially for newbies like me. I am trying to learn RL coding by studying examples from the web. For example, with the OpenAI Gym gridworld, the examples often have similar supporting files, etc., and its good to keep my code and the example code entirely separate from each other in writing and executing. Perhaps the ability to work with code in two entirely separate workspaces could be an extension to Visual Studio Code so the the everyday version of Code is still as lite as possible for most people. In the best of all possible worlds, though, for people like me, who would be great to be able to debug both the working example code, often in a somewhat different coding structure, with different variable names, etc., and my own code at the same time and see separate variable lists for each workspace, etc. To see what the example code has done up to a certain breakpoint vs. what my feeble efforts to duplicate algorithms according to my own coding structure requirements have achieved by comparison, etc.
+1 . this would really help me with my workflow as well! Any news or feedback on this being considered?
+1, I'm really hoping for this feature
+1; Make this happen please!
+1
Workspace feature is great because we can grouping projects in a top context (microservices projects in a big API workspace). But, only one workspace can be open. This feature can be powerful if multiple workspaces can be open at the same time (in the same window).
And another request : it will be great if :
name
attribute (to clearly identify the workspace in the left pane in VS Code)