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

Bug 209369

Summary: Allow IProjects to be created in ws reading from alternate FileSystem (zip/plugin)
Product: [Eclipse Project] Platform Reporter: Francis Upton IV <francisu>
Component: ResourcesAssignee: Platform-Resources-Inbox <platform-resources-inbox>
Status: RESOLVED WORKSFORME QA Contact:
Severity: enhancement    
Priority: P3    
Version: 3.3.1   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:

Description Francis Upton IV CLA 2007-11-09 14:12:04 EST
Build ID: M20071023-1652

My use case is distributing the contents of a project as a plugin or zip file and using the project read only directly from that plugin or zip file without copying it into the local file system (I have a Zip and plugin implementation of EFS for this purpose)

It is not possible to create the project in the workspace and have it refer to an existing read-only filesystem (it tries to write the .project file into the filesystem) upon creation.

I propose the addition of a new option, called IResource.USE_EXISTING_PROJECT_CONTENT for the IProject.create() method.  This would cause the project description to be *read* from the project file system (the initial location of the file system would be the only thing used from the passed in IProjectDescription), and the project to be created in the workspace.

More background can be found in this discussion:

http://www.eclipse.org/newsportal/article.php?id=70033&group=eclipse.platform#70033
Comment 1 John Arthorne CLA 2007-11-21 15:50:26 EST
I haven't tested this lately, but it worked in the past. Project#create first checks if there is an existing .project file, and doesn't try to write the description if there is a description already available.
Comment 2 Francis Upton IV CLA 2007-11-28 12:07:49 EST
@John - you are right.  I will close this bug, sorry about that.

There is a bigger issue, which is being able to use the contents of a plugin/zip file as the project contents and to refresh them in the workspace to make sure you get the current project contents, but I will raise that elsewhere.