Using Eclipse Working Sets Instead of Workspaces

Published By: Doug Hughes on Oct 29, 2007 at 8:08 AM

Times Viewed: 5405

Categories: None

One of my biggest gripes about Eclipse has always been the use of workspaces to organize projects.  For example, I had a client not too long ago for whom I had several Eclipse projects created.  I had at least three projects for frameworks alone.  Then I had the legacy application and the new application we were building.  I'm sure there was at least one more in there too.

Now, it seems like the most widely known way to separate this from your copious list of other projects was to create a Workspace. The problem with workspaces, however, is that to switch between workspaces you must start a different instance of Eclipse.  That doesn't mean you can't have multiple instances of Eclipse running with different working sets, but it can be a hassle none the less.

So, last time I saw Paul Kenny he, as usual, brought to my attention something which I previously had no idea existed:  Working Sets.  Working sets are really just collections of projects. 

As an example, here's a long, unorganized list of projects:

projectList

As you can see, there's no organization here.  Seeing as I've been doing a lot of work on the Alagad.com site, it would be nice if I could see only the relevant projects.  To do this I first click on the menu arrow and click Select Working Set...

workingSetMenu

This shows me the Select Working Set dialog. 

newButton 

Seeing as I have no working sets I'll create a new one by clicking the new button.  This shows the New Working Set dialog.

resource

For my projects I've been selecting Resource (or Java - I can't see the difference between the two) and clicking next.  In the resulting dialog I can select the projects I want in my working set.

projects

Finally, I click finish and I am returned to the Select Working sets dialog where I now see my new Working Set.

 selectedWorkingset

If I select my working set and click OK my project list will refresh to show only the selected projects.

workingSetFinal

This is a really handy way to have Eclipse show only what I'm most interested in at the moment.  Now that I have my Working Set created I can also quickly deselect it on or off though the same menu we started with.

deselect

13 Comments

Yeah, it always amazes me when I see CFers switching workspaces all the time. It's such a cumbersome way to work!

I've always used Working Sets and have lots of them defined with different combinations of projects in each.

Good to see a blog post on this topic!

Posted By: Sean Corfield on Oct 29, 2007

"One of my biggest gripes about Eclipse has always been the use of working sets to organize projects"

Don't you mean "workspaces" are your gripe?

I love working sets, I don't know how I would work without them.

Posted By: Chris Rockett on Nov 3, 2007

@Chris - You're right. I fixed this. Thanks for pointing it out.

Posted By: Doug Hughes on Nov 6, 2007

It's helpful. Thanks a lot. :)

Posted By: Kevin Wu on Nov 30, 2007

Very nice. I've worked in Eclipse for a while and didn't know about this.

Posted By: Jim on Dec 13, 2007

Not just projects. Package or directory views within projects as well. You can have a working set that just has your test subdirectories, or your docs.
I use working sets as a huge time-saver to limit scope for Search or Open Resources constantly.

Posted By: Will Budreau on Feb 22, 2008

Ver good

Posted By: Sameer on Jul 15, 2008

my god man, thank you! I've been trying to get my head around workspaces and this solves it all! Cheers!

Posted By: plebe on Jan 4, 2009

Eclipse amazes me every day :)=

Posted By: Bac0n on Jan 27, 2009

This was helpful. I've been working with Eclipse for years now, and never bothered to figure out what a working set was. Thanks for the post!

Posted By: Lee on Mar 25, 2009

I'm so glad I found this! It solved all my problems. Thanks!

Posted By: Torre on Mar 30, 2009

This post help me to organize multiple project !!!


Thanks for your explication !!!!

Posted By: fredfloyd on May 28, 2009

Thanks for this info! Useful. Don't like the way Eclipse uses workspaces either, compared to other editors/IDE's like UltraEdit or Visual Studio.

It's not even possible, as far as I know,
to double click on a project-file to open it in the IDE (default workspace or something).

Furthermore, if you use ClearCase, you can't have a project in different views (the same name, just different versions) and open/import them in a single workspace. Weird.

Posted By: Joost on May 29, 2009

Add a Comment

Please provide your email address if you want to subscribe to this blog entry. An unsubscribe link is provided in notification emails. Your email address is never shown on this website.
Processing... Please wait
We are adding your comment.