Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 323115

Summary: [StandaloneSetup] Improve population of org.eclipse.emf.ecore.plugin.EcorePlugin.getPlatformResourceMap()
Product: [Modeling] EMFT Reporter: Sven Efftinge <sven.efftinge>
Component: MWEAssignee: Project Inbox <emft-mwe-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3 Flags: sven.efftinge: indigo+
Version: 1.0   
Target Milestone: M2   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:
Attachments:
Description Flags
proposed patch sven.efftinge: iplog+

Description Sven Efftinge CLA 2010-08-19 05:23:41 EDT
Currently the StandaloneSetup assumes that you only have projects that physically reside within the workspace root directly. That is linked projects are not reconsidered.

There are currently two ideas how to improve this:

1) Specify a couple of paths, which are scanned for .project files recursively.

2) Use information provided in .metadata/.plugins/org.eclipse.core.resources/.projects in order to find out which projects are really linked into the workspace.

The former seems to be simpler, while the latter is more accurate.
Comment 1 Michael Clay CLA 2010-08-19 17:42:33 EDT
Created attachment 177053 [details]
proposed patch
Comment 2 Sven Efftinge CLA 2010-08-20 03:14:32 EDT
Cool, thanks! :-)
Comment 3 Sven Efftinge CLA 2010-08-26 16:15:23 EDT
We discussed that option 2) has the problem, that workspace .metadata usually doesn't exist on build servers. Also copying the code from core.resources adds a lot of stuff.

I'ld like to have a simple implementation for 1). Without any added abstractions and factories.

It should just search the directory recursively for .project files and add the information to the EcorePlugin.getPlatformResourceMap().
Comment 4 Sven Efftinge CLA 2010-08-27 04:23:56 EDT
Since we migrated to git, generation of test languages didn't work anymore. Therefore I had to fix this.