Bug 212503 - Add support for creating example projects.
Summary: Add support for creating example projects.
Status: RESOLVED DUPLICATE of bug 36960
Alias: None
Product: PDE
Classification: Eclipse Project
Component: Incubators (show other bugs)
Version: 3.4   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: platform-ua-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-12-11 01:47 EST by Ketan Padegaonkar CLA
Modified: 2008-01-09 11:08 EST (History)
7 users (show)

See Also:


Attachments
sample plugin that can create sample plugins (28.42 KB, application/zip)
2007-12-11 23:25 EST, Ketan Padegaonkar CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ketan Padegaonkar CLA 2007-12-11 01:47:44 EST
Build ID: (3.4M3) - I20071101-2000 

Steps To Reproduce:
There should be a better/simpler way to create sample projects in eclipse in a way similar to what most eclipse projects have.

Unfortunately the only extension point that I could find was
"org.eclipse.pde.ui.samples", and the API says:

"This extension point is currently provided for internal Eclipse SDK
usage only. It should not be used for anything else except Eclipse SDK
examples."

Would it be possible to move this extension point somewhere where it has lesser dependencies on PDE or JDT ?

This would be a really useful extension point for creating example projects. I'd like to contribute a patch to do this, in case someone could provide on some pointers.

Unfortunately I cant get the extension point "org.eclipse.pde.ui.samples" to work either.
Comment 1 Szymon Brandys CLA 2007-12-11 06:26:00 EST
Moving to the UI team for a comment.
Comment 2 Ketan Padegaonkar CLA 2007-12-11 23:25:10 EST
Created attachment 85030 [details]
sample plugin that can create sample plugins

See file>new>other>Example Category>name

Looking for initial feedback, this still needs some polish.
Comment 3 Brian Bauman CLA 2007-12-13 14:46:01 EST
Ketan, you are asking for a way to contribute a sample project that is not really a PDE project, right?  Currently, PDE has its own custom framework to contribute templates, but if that is what you are asking for, we would need to come up with some more general.

Reassigning to UA for now since this request appears to be more general than PDE's scope.
Comment 4 Ketan Padegaonkar CLA 2007-12-14 00:26:06 EST
(In reply to comment #3)
> Ketan, you are asking for a way to contribute a sample project that is not
> really a PDE project, right?  Currently, PDE has its own custom framework to
> contribute templates, but if that is what you are asking for, we would need to
> come up with some more general.

Yes, I'm talking about creating *any* kind of a sample project, not just Java. The PDE project framework is slightly more complex.

Being able to extract a zip file into a project seems to be a good enough for most Java projects (and a maybe few PDE projects).

> Reassigning to UA for now since this request appears to be more general than
> PDE's scope.
> 

Comment 5 Chris Goldthorpe CLA 2008-01-08 20:02:05 EST
I think this falls under plugin development.
Comment 6 Les Jones CLA 2008-01-09 06:27:01 EST
Seems to me like this is a nice request that would be looking for something similar to the PDE template functionality, but for any type of resource/project, not just for adding extensions (and example resources) to plugin projects.

I dearly hope this doesn't become a 'pass-the-buck' enhancement, but to me, given the generic IDE / resource nature of the request, this should belong with Platform/IDE or Platform/Resources.

Thoughts anyone?
Comment 7 Les Jones CLA 2008-01-09 06:44:46 EST
Ketan,

As regards your sample, I'd recommend dropping the BREE down from 1.6 to 1.5 (or 1.4 if you're not using any 5.0 features). Also, I quite like the technique that the PDE templates use, which uses a directory structure for the resources rather than having an embedded zip. IMHO :-)
Comment 8 Ketan Padegaonkar CLA 2008-01-09 07:32:50 EST
(In reply to comment #7)
> Ketan,
> 
> As regards your sample, I'd recommend dropping the BREE down from 1.6 to 1.5
> (or 1.4 if you're not using any 5.0 features).

Ack on that, I'm using JDK 1.6, and that's probably why the BREE bumped up to 1.6.

> Also, I quite like the technique 
> that the PDE templates use, which uses a directory structure for the resources
> rather than having an embedded zip. IMHO :-)

I did not quite understand that. AFAIK, PDE uses zip files as well.

The existing solution works just fine for me for most practical purposes.

I don't mind cleaning it up a bit in case this makes though into eclipse. Someone needs to let me know if this contribution makes sense in the context of eclipse, so far I've only seen this bug being tossed from one component to the other.
Comment 9 Les Jones CLA 2008-01-09 08:53:03 EST
If you have a look at the PDE template (in the org.eclipse.pde.ui.templates plugin) you'll see the resources that make up the content copied as a result of applying the template are in directories of the format 'template_X.X' (n.b. the alterations to the underlying plugin model are performed by code though rather than by copying files).

For more info you may also want to have a look at the following article:  http://www-128.ibm.com/developerworks/library/os-eclipse-pde/index.html?ca=dgr-eclipse-1 
Comment 10 Chris Aniszczyk CLA 2008-01-09 11:08:32 EST
So this problem is as ancient as Eclipse is. The real issue here is that we can't decide on a standard templating framework to really make it easy to create example projects. Whether it is JET, JET2, XPAND, whatever, there are tons of solutions out within Eclipse land. 

I'm going to dupe this one to the original bug. If you want it, please vote on the bug and raise awareness. A general templating solution and wizards to create them are on my wishlist for Eclipse 4.0

*** This bug has been marked as a duplicate of bug 36960 ***