- This topic has 7 replies, 2 voices, and was last updated 17 years, 2 months ago by Riyad Kalla.
-
AuthorPosts
-
Marty HallMemberI prefer MyEclipse to regular Eclipse, especially for JSF development. However, I need to distribute my projects to a variety of developers. Some of them use MyEclipse, and some of them use Regular Eclipse.
What do I need to do to make the exported archive files compatible? Is using “WebContent” instead of “WebRoot” sufficient? Regular Eclipse and WSAD use “WebContent”, whereas MyEclipse uses “WebRoot”.
Along the same lines, is there a way to change existing projects to use WebContent without manually editing .mymetadata? If I do Refactor –> Raname to change WebRoot to WebContent, it renames the folder but still thinks WebRoot is the folder for Web content, and I couldn’t find a place to fix it except by manually editing .mymetadata. I already know how to use WebContent from the beginning for new projects.
Any others here that have used MyEclipse to generate projects that will be then be used by both MyEclipse and Regular Eclipse users?
Riyad KallaMemberWhat do I need to do to make the exported archive files compatible? Is using “WebContent” instead of “WebRoot” sufficient? Regular Eclipse and WSAD use “WebContent”, whereas MyEclipse uses “WebRoot”.
I believe these are just defaults. You can change this setting in MyEclipse under Window > Prefs > MyEclipse > Java Enterprise Project > Web Project to make the WSAD/WTP folks feel more at home.
Along the same lines, is there a way to change existing projects to use WebContent without manually editing .mymetadata? If I do Refactor –> Raname to change WebRoot to WebContent, it renames the folder but still thinks WebRoot is the folder for Web content, and I couldn’t find a place to fix it except by manually editing .mymetadata. I already know how to use WebContent from the beginning for new projects.
Unfortunately no, you need to do it manually right now.
Any others here that have used MyEclipse to generate projects that will be then be used by both MyEclipse and Regular Eclipse users?
WTP, and likely WSAD, use the “Facet” model, so you will likely want to make sure you add the Web Facets (not sure of the name) to the project so WSAD/WTP can detect the “webiness” of the projects.
Marty HallMember@support-rkalla wrote:
I believe these [WebRoot for MyEclipse, WebContent for regular Eclipse and WSAD] are just defaults. You can change this setting in MyEclipse under Window > Prefs > MyEclipse > Java Enterprise Project > Web Project to make the WSAD/WTP folks feel more at home.
Yes, I know how to set this for new projects, but I didn’t know how to change it for existing projects other than by manually editing .mymetadata. I will keep editing that file for my existing projects; thanks!
@support-rkalla wrote:
WTP, and likely WSAD, use the “Facet” model, so you will likely want to make sure you add the Web Facets (not sure of the name) to the project so WSAD/WTP can detect the “webiness” of the projects.
I am not familiar with Web Facets. Does anyone know how to add Web Facets in MyEclipse? Has anyone already successfully exported MyEclipse Java Web projects to regular Eclipse users? I really prefer to keep using MyEclipse, but it is important that regular Eclipse users be able to import my archive files (or import my projects somehow).
Riyad KallaMemberMarty,
I’m not familiar with how WTP works, but since MyEclipse is built ontop of WTP, it’s actually already in there and that is what your “Eclipse” folks are likely using.If you want to dabble with WTP, you can re-enable some of it’s functions under Window > Prefs > General > Capabilities > Advanced. Once those are turned back on, you should be able to add the WTP Facets to your project so the IDE understands it as both a MyEclipse Web Project and a WTP “Dyanmic Web Project”… atleast I think so.
Marty HallMemberHmm. I have not been completely successful in changing WebRoot to WebContent for existing projects. I did this:
- R-clicked on WebRoot, did Refactor –> Rename to WebContent.
- Edited .mymetadata and changed attribute name=”webrootdir” value=”WebRoot” to attribute name=”webrootdir” value=”WebContent”
- R-clicked on WebRoot and selected “Delete”.
But, whenever I did this, MyEclipse immediately re-created the WebRoot folder. This happened regardless of whether:
- The default folder name for web content was WebRoot or WebContent
- I stopped and restarted MyEclipse after editing .mymetadata.
- I did Refresh on the project
Now, the project still deploys fine. Still, it is annoying to have a spurious “WebRoot” folder lying around: it is sure to confuse later developers.
Any suggestions?
Riyad KallaMemberDoh, the problem is that the old output dir is still set, I forgot about that. You need to move it to point to WebContent/WEB-INF/classes, otherwise the old dir keeps getting re-created.
Marty HallMember@support-rkalla wrote:
Doh, the problem is that the old output dir is still set, I forgot about that. You need to move it to point to WebContent/WEB-INF/classes, otherwise the old dir keeps getting re-created.
Where is that set? I looked in .mymetadata and .project and didn’t find it. I also did a file search for “WebRoot” with no luck.
Thanks!
Riyad KallaMemberAhh pop open the project properties, go to Java Build Path, and it’s on the bottom of the first Source screen (output dir)
-
AuthorPosts