You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-dev@portals.apache.org by Ate Douma <at...@douma.nu> on 2008/01/24 17:53:01 UTC

svn:ignore Eclipse metadata files

As I'm primarily use Eclipse for Java development, I'd like to add svn:ignore properties to Pluto trunk for all the Eclipse metadata generated by both Eclipse 
(plugins) and the maven eclipse plugin.

If nobody objects, I intend to do so later this evening or sometime tomorrow.

Regards,

Ate

Re: svn:ignore Eclipse metadata files

Posted by Elliot Metsger <em...@jhu.edu>.
+1

Ate Douma wrote:
> As I'm primarily use Eclipse for Java development, I'd like to add 
> svn:ignore properties to Pluto trunk for all the Eclipse metadata 
> generated by both Eclipse (plugins) and the maven eclipse plugin.
> 
> If nobody objects, I intend to do so later this evening or sometime 
> tomorrow.
> 
> Regards,
> 
> Ate

Re: svn:ignore Eclipse metadata files

Posted by Dettborn <de...@minet.uni-jena.de>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
 
+1
Ate Douma schrieb:
| As I'm primarily use Eclipse for Java development, I'd like to add 
svn:ignore properties to Pluto trunk for all the Eclipse metadata 
generated by both Eclipse (plugins) and the maven eclipse plugin.
|
| If nobody objects, I intend to do so later this evening or sometime 
tomorrow.
|
| Regards,
|
| Ate
|

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
 
iD8DBQFHmdSk0Ji0BqEIlIURAqg3AJwLJvHi67/rApkDJLl6E57+lD8rfQCeLALr
/QWKAXY9N6MnEP+sNNDRDSU=
=viMf
-----END PGP SIGNATURE-----


Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Ate Douma <at...@douma.nu>.
Ate Douma wrote:
> CDoremus@hannaford.com wrote:
>>
>> +1 to svn:ignore
> 
> Thanks Graig and the others for agreeing on this and I will proceed 
> doing this shortly.
Done.

AFAIK this has been my very first commit to the pluto svn tree but definitely not my planning to be the last :)
As a result though, my commit message now most likely is stuck in the moderator queue for pluto-scm@.
Hopefully it will be moderated through soon.

Regards,

Ate

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Elliot Metsger <em...@jhu.edu>.

CDoremus@hannaford.com wrote:
> BTW, I have m2eclipse, but it is slow as molasses (in January). I have the
> latest 'stable' version installed (0.0.10).

Craig see my earlier message.

Unless i misunderstand what you guys mean by "sub projects", m2eclipse 
will do all this automatically with no yoga or magic incantations, no 
Subversive, etc.

0.0.10 is not the latest version -

Make sure you have the correct m2eclipse update site:
http://m2eclipse.codehaus.org/update/

If you look at the site.xml file you'll see later versions
<feature 	 
url="features/org.maven.ide.eclipse.feature_0.0.12.20071107-2300.jar" 
id="org.maven.ide.eclipse.feature" version="0.0.12.20071107-2300">
<category name="Maven Integration"/>
</feature>


HTH,
Elliot

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by CD...@hannaford.com.


Ate Douma <at...@douma.nu> wrote on 01/25/2008 09:35:43 AM:

> CDoremus@hannaford.com wrote:
> >
> > +1 to svn:ignore
>
> Thanks Graig and the others for agreeing on this and I will proceed
> doing this shortly.
>
> >
> > I'd also like to see .classpath in the Pluto root and would not object
to
> > analagous files for IDEA and Netbeans IDEs. I cannot get the maven 2
> > eclipse plugin to create a single .classpath in my Eclipse project's
root
> > dir. I have to run 'mvn eclipse:eclipse' in the root dir, and then in
all
> > the module subdirs and then manually combine the resulting .classpath
> > entries into the root one. That is a pain.
> > /Craig
> Well, that is not how you are supposed to do it or use Eclipse in my
view.
> Although Eclipse still doesn't support nested projects (see long
> standing issue:
>    https://bugs.eclipse.org/bugs/show_bug.cgi?id=35973
> and please cast your vote), but there is a simple "trick" to handle
> maven-2 kind nested projects in Eclipse (3.2+ AFAIK).

I just voted for this. Thanks for the info.

>
> Note: for this to work I had to switch from the subclipse plugin to
> the subversive plugin:
>    http://www.polarion.org/index.php?page=overview&project=subversive
>
> But as subversive actually is a very good svn plugin and its core
> component now even an official Eclipse project, I never had a need
> to look back.
>

I've had good luck with subeclipse, but I'll give subversive a try.


> What I normally do is the following:
> - Check out the root of the project using Eclipse and call it
> <project-name>-trunk, so pluto-trunk)
>    This will create a default, non-java .project Eclipse project
> file and thus also without .classpath.
> - Then run mvn eclipse:eclipse to generate the Eclipse .project and
> .classpath files
> - now comes the trick:
>    - while having Eclipse running, delete its auto generated .
> project file from the file system
>      and don't touch or refresh your trunk project while doing the
> following step
>    - open the File..., Import..., Existing Projects into Workspace dialog
>    - select as root directory for import your checked out project
> root folder and import the now displayed nested projects
>    - press finish
>    - Eclipse will automatically recreate the deleted ,project file
> for your project trunk project
>
> Now you have both the full project tree (under project
> <projectname>-trunk) as well as the all the nested java projects and
> you are ready to go.

So this is a way to fool eclipse into creating nested subprojects? How did
you figure this one out?!?

I'll see how it works, but I wish there was another way. Maybe you should
put this info on the Wiki?

>
> As this works quite neatly now with Eclipse (3.2+) I honestly don't
> think we should check in hand created (or one time generated) .classpath
files
> as these are a pain to keep properly in sync, especially when using
> nested projects.
>

I'll see how your subversive incantation and subproject yoga works (BTW,
what are those magic words again?).

At any rate, I think that Eclipse developers would update the .classpath
file as a matter of course when dependancies change,
but if there is no sentiment for this idea, I'm willing to drop it.

BTW, I have m2eclipse, but it is slow as molasses (in January). I have the
latest 'stable' version installed (0.0.10).

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Ate Douma <at...@douma.nu>.
CDoremus@hannaford.com wrote:
> 
> +1 to svn:ignore

Thanks Graig and the others for agreeing on this and I will proceed doing this shortly.

> 
> I'd also like to see .classpath in the Pluto root and would not object to
> analagous files for IDEA and Netbeans IDEs. I cannot get the maven 2
> eclipse plugin to create a single .classpath in my Eclipse project's root
> dir. I have to run 'mvn eclipse:eclipse' in the root dir, and then in all
> the module subdirs and then manually combine the resulting .classpath
> entries into the root one. That is a pain.
> /Craig
Well, that is not how you are supposed to do it or use Eclipse in my view.
Although Eclipse still doesn't support nested projects (see long standing issue:
   https://bugs.eclipse.org/bugs/show_bug.cgi?id=35973
and please cast your vote), but there is a simple "trick" to handle maven-2 kind nested projects in Eclipse (3.2+ AFAIK).

Note: for this to work I had to switch from the subclipse plugin to the subversive plugin:
   http://www.polarion.org/index.php?page=overview&project=subversive

But as subversive actually is a very good svn plugin and its core component now even an official Eclipse project, I never had a need to look back.

What I normally do is the following:
- Check out the root of the project using Eclipse and call it <project-name>-trunk, so pluto-trunk)
   This will create a default, non-java .project Eclipse project file and thus also without .classpath.
- Then run mvn eclipse:eclipse to generate the Eclipse .project and .classpath files
- now comes the trick:
   - while having Eclipse running, delete its auto generated .project file from the file system
     and don't touch or refresh your trunk project while doing the following step
   - open the File..., Import..., Existing Projects into Workspace dialog
   - select as root directory for import your checked out project root folder and import the now displayed nested projects
   - press finish
   - Eclipse will automatically recreate the deleted ,project file for your project trunk project

Now you have both the full project tree (under project <projectname>-trunk) as well as the all the nested java projects and you are ready to go.

As this works quite neatly now with Eclipse (3.2+) I honestly don't think we should check in hand created (or one time generated) .classpath files
as these are a pain to keep properly in sync, especially when using nested projects.

Regards,

Ate


> 
> 
> 
> 
>                                                                            
>              Ate Douma                                                     
>              <at...@douma.nu>                                                
>                                                                         To 
>              01/24/2008 11:53          pluto-dev@portals.apache.org        
>              AM                                                         cc 
>                                                                            
>                                                                    Subject 
>              Please respond to         svn:ignore Eclipse metadata files   
>              pluto-dev@portals                                             
>                 .apache.org                                                
>                                                                            
>                                                                            
>                                                                            
>                                                                            
> 
> 
> 
> 
> As I'm primarily use Eclipse for Java development, I'd like to add
> svn:ignore properties to Pluto trunk for all the Eclipse metadata generated
> by both Eclipse
> (plugins) and the maven eclipse plugin.
> 
> If nobody objects, I intend to do so later this evening or sometime
> tomorrow.
> 
> Regards,
> 
> Ate
> 
> 


Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Ate Douma <at...@douma.nu>.
Elliot Metsger wrote:
> I use m2eclipse version 0.0.12.20071107-2300.  I believe the update site 
> is http://m2eclipse.codehaus.org/update/  Works pretty good.
Thanks for the info Elliot.

I've tried m2eclipse quite some time ago and at that time found it unreliable and buggy.
Maybe things have improved now so I'll try it out again one of of these days.

Regards,

Ate

> 
> If you install it correctly you should see an "m2" option when right 
> clicking on a project in the navigator.
> 
> So install the m2 eclipse plugin.  Get a fresh checkout of Pluto.  Don't 
> configure the source folders or the library paths.
> 
> Then - this is ugly (maven does get confused about a nested resource in 
> the pluto-container POM) - edit pluto-container/pom.xml:
> 
>     <resources>
>       <resource>
>         <directory>src/main/resources</directory>
>         <filtering>true</filtering>
>       </resource>
>       <resource>
>         <directory>src/main/resources/META-INF</directory>
>         <targetPath>/META-INF</targetPath>
>       </resource>
>     </resources>
> 
> You have to comment out the second <resource>.  Save the change.
> 
> In the Navigator right click on the root of the project, you should see 
> an m2 menu.  Select "Enable dependency management"
> 
> Then right click again -> m2 menu -> enabled nested modules
> 
> Eclipse shoudl chug for a while
> 
> Then right click again -> m2 menu -> update source
> 
> Then switch to Package Explorer.
> 
> You should see something like the attached screen shot.  All the source 
> folders configured, with a "Maven Dependency" thing with all the deps 
> from maven.
> 
> HTH,
> E
> 
> 
> 
> CDoremus@hannaford.com wrote:
>>
>> +1 to svn:ignore
>>
>> I'd also like to see .classpath in the Pluto root and would not object to
>> analagous files for IDEA and Netbeans IDEs. I cannot get the maven 2
>> eclipse plugin to create a single .classpath in my Eclipse project's root
>> dir. I have to run 'mvn eclipse:eclipse' in the root dir, and then in all
>> the module subdirs and then manually combine the resulting .classpath
>> entries into the root one. That is a pain.
>> /Craig
>>
>>
>>
>>
>>                                                                            
>>              Ate 
>> Douma                                                                  
>> <at...@douma.nu>                                                
>>                                                                         
>> To              01/24/2008 11:53          
>> pluto-dev@portals.apache.org                     
>> AM                                                         cc 
>>                                                                            
>>                                                                    
>> Subject              Please respond to         svn:ignore Eclipse 
>> metadata files                
>> pluto-dev@portals                                             
>>                 
>> .apache.org                                                
>>                                                                            
>>                                                                            
>>                                                                            
>>                                                                            
>>
>>
>>
>>
>> As I'm primarily use Eclipse for Java development, I'd like to add
>> svn:ignore properties to Pluto trunk for all the Eclipse metadata 
>> generated
>> by both Eclipse
>> (plugins) and the maven eclipse plugin.
>>
>> If nobody objects, I intend to do so later this evening or sometime
>> tomorrow.
>>
>> Regards,
>>
>> Ate
> 
> ------------------------------------------------------------------------
> 
> 
> ------------------------------------------------------------------------
> 


Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Elliot Metsger <em...@jhu.edu>.
  I had assumed that it was need which is why i never committed it; so 
if isn't needed cool, it should just be deleted.



Ate Douma wrote:
> I beat you to it :)
> 
> It's already fixed in svn but my commit message(s) are still stuck in 
> the moderator queue.
> 
> 
> Elliot Metsger wrote:
>>
>>
>> Elliot Metsger wrote:
>>> Then - this is ugly (maven does get confused about a nested resource 
>>> in the pluto-container POM) - edit pluto-container/pom.xml:
>>>
>>>     <resources>
>>>       <resource>
>>>         <directory>src/main/resources</directory>
>>>         <filtering>true</filtering>
>>>       </resource>
>>>       <resource>
>>>         <directory>src/main/resources/META-INF</directory>
>>>         <targetPath>/META-INF</targetPath>
>>>       </resource>
>>>     </resources>
>>>
>>> You have to comment out the second <resource>.  Save the change.
>>
>> Someone (me?) should figure out why maven complains about the nested 
>> resource and either work around it by updating the POM or report the 
>> bug... I'll try to get to it.
>>

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Ate Douma <at...@douma.nu>.
I beat you to it :)

It's already fixed in svn but my commit message(s) are still stuck in the moderator queue.


Elliot Metsger wrote:
> 
> 
> Elliot Metsger wrote:
>> Then - this is ugly (maven does get confused about a nested resource 
>> in the pluto-container POM) - edit pluto-container/pom.xml:
>>
>>     <resources>
>>       <resource>
>>         <directory>src/main/resources</directory>
>>         <filtering>true</filtering>
>>       </resource>
>>       <resource>
>>         <directory>src/main/resources/META-INF</directory>
>>         <targetPath>/META-INF</targetPath>
>>       </resource>
>>     </resources>
>>
>> You have to comment out the second <resource>.  Save the change.
> 
> Someone (me?) should figure out why maven complains about the nested 
> resource and either work around it by updating the POM or report the 
> bug... I'll try to get to it.
> 


Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Elliot Metsger <em...@jhu.edu>.

Elliot Metsger wrote:
> Then - this is ugly (maven does get confused about a nested resource in 
> the pluto-container POM) - edit pluto-container/pom.xml:
> 
>     <resources>
>       <resource>
>         <directory>src/main/resources</directory>
>         <filtering>true</filtering>
>       </resource>
>       <resource>
>         <directory>src/main/resources/META-INF</directory>
>         <targetPath>/META-INF</targetPath>
>       </resource>
>     </resources>
> 
> You have to comment out the second <resource>.  Save the change.

Someone (me?) should figure out why maven complains about the nested 
resource and either work around it by updating the POM or report the 
bug... I'll try to get to it.

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by Elliot Metsger <em...@jhu.edu>.
I use m2eclipse version 0.0.12.20071107-2300.  I believe the update site 
is http://m2eclipse.codehaus.org/update/  Works pretty good.

If you install it correctly you should see an "m2" option when right 
clicking on a project in the navigator.

So install the m2 eclipse plugin.  Get a fresh checkout of Pluto.  Don't 
configure the source folders or the library paths.

Then - this is ugly (maven does get confused about a nested resource in 
the pluto-container POM) - edit pluto-container/pom.xml:

     <resources>
       <resource>
         <directory>src/main/resources</directory>
         <filtering>true</filtering>
       </resource>
       <resource>
         <directory>src/main/resources/META-INF</directory>
         <targetPath>/META-INF</targetPath>
       </resource>
     </resources>

You have to comment out the second <resource>.  Save the change.

In the Navigator right click on the root of the project, you should see 
an m2 menu.  Select "Enable dependency management"

Then right click again -> m2 menu -> enabled nested modules

Eclipse shoudl chug for a while

Then right click again -> m2 menu -> update source

Then switch to Package Explorer.

You should see something like the attached screen shot.  All the source 
folders configured, with a "Maven Dependency" thing with all the deps 
from maven.

HTH,
E



CDoremus@hannaford.com wrote:
> 
> +1 to svn:ignore
> 
> I'd also like to see .classpath in the Pluto root and would not object to
> analagous files for IDEA and Netbeans IDEs. I cannot get the maven 2
> eclipse plugin to create a single .classpath in my Eclipse project's root
> dir. I have to run 'mvn eclipse:eclipse' in the root dir, and then in all
> the module subdirs and then manually combine the resulting .classpath
> entries into the root one. That is a pain.
> /Craig
> 
> 
> 
> 
>                                                                            
>              Ate Douma                                                     
>              <at...@douma.nu>                                                
>                                                                         To 
>              01/24/2008 11:53          pluto-dev@portals.apache.org        
>              AM                                                         cc 
>                                                                            
>                                                                    Subject 
>              Please respond to         svn:ignore Eclipse metadata files   
>              pluto-dev@portals                                             
>                 .apache.org                                                
>                                                                            
>                                                                            
>                                                                            
>                                                                            
> 
> 
> 
> 
> As I'm primarily use Eclipse for Java development, I'd like to add
> svn:ignore properties to Pluto trunk for all the Eclipse metadata generated
> by both Eclipse
> (plugins) and the maven eclipse plugin.
> 
> If nobody objects, I intend to do so later this evening or sometime
> tomorrow.
> 
> Regards,
> 
> Ate

Re: svn:ignore Eclipse metadata files ( .classpath too)

Posted by CD...@hannaford.com.

+1 to svn:ignore

I'd also like to see .classpath in the Pluto root and would not object to
analagous files for IDEA and Netbeans IDEs. I cannot get the maven 2
eclipse plugin to create a single .classpath in my Eclipse project's root
dir. I have to run 'mvn eclipse:eclipse' in the root dir, and then in all
the module subdirs and then manually combine the resulting .classpath
entries into the root one. That is a pain.
/Craig




                                                                           
             Ate Douma                                                     
             <at...@douma.nu>                                                
                                                                        To 
             01/24/2008 11:53          pluto-dev@portals.apache.org        
             AM                                                         cc 
                                                                           
                                                                   Subject 
             Please respond to         svn:ignore Eclipse metadata files   
             pluto-dev@portals                                             
                .apache.org                                                
                                                                           
                                                                           
                                                                           
                                                                           




As I'm primarily use Eclipse for Java development, I'd like to add
svn:ignore properties to Pluto trunk for all the Eclipse metadata generated
by both Eclipse
(plugins) and the maven eclipse plugin.

If nobody objects, I intend to do so later this evening or sometime
tomorrow.

Regards,

Ate