You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Martin Höller <ma...@xss.co.at> on 2008/02/20 17:29:26 UTC

maven-eclipse-plugin writes to src/main/webapp

Hi all!

I just noticed that the maven-eclipse-plugin (2.5-SNAPHSOT) writes a 
MANIFEST.MF output to src/main/webapp/META-INF when mvn eclipse:eclipse is 
called for a web-application.

Is this behaviour intentional? I wouldn't expect maven or any plugin to 
write something into src/main.

If the MANIFEST.MF is needed by eclipse, couldn't it be written to target/ 
and eclipse be configured to use that instead, just as it happens for EARs?

Any comments?
- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by amit kumar <am...@gmail.com>.
On synchronizing a pde plugin with maven-eclipse-plugin, it looks to me that
Manifest.mf file do get synchronized even though it is in META-INF folder.
Does maven-eclipse-plugin synchronizes it with .classpath or how?


Regards,
Amit

On Fri, Feb 22, 2008 at 1:13 PM, Martin Höller <ma...@xss.co.at> wrote:

> On Thursday 21 February 2008 wrote Arnaud HERITIER:
> > I prefer to have a new issue and a link between them.
>
> Created: http://jira.codehaus.org/browse/MECLIPSE-392
>
> > You can wait to have it fixed OR you can propose a patch (code+test+doc)
> > to be sure it will be.
>
> Currently I'm too busy but maybe I'll have a look at it later...
>
> thx,
> - martin
> --
> Martin Höller                   | martin.hoeller@xss.co.at
> *x Software + Systeme           | http://www.xss.co.at/
> Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
> A-1100 Vienna, Austria          | Fax: +43-1-6060114-71
>

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Martin Höller <ma...@xss.co.at>.
On Thursday 21 February 2008 wrote Arnaud HERITIER:
> I prefer to have a new issue and a link between them.

Created: http://jira.codehaus.org/browse/MECLIPSE-392

> You can wait to have it fixed OR you can propose a patch (code+test+doc)
> to be sure it will be.

Currently I'm too busy but maybe I'll have a look at it later...

thx,
- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

Re: putting context.xml into META-INF

Posted by Martin Hoeller <ma...@xss.co.at>.
Hi!

First, if you start a new topic, please do this by writing a new mail and
not by replying to some other mail. This can be really annoying if you
use a proper MUA that sorts by thread!

On 25 Feb 2008, Dooing@gmx.de wrote:

> i am using "mvn package" to create a war file of my project.
> However, I found out that my context.xml file, located under
> "src/context/context.xml", is missing in the META-INF directory
> of the war file! Therefore, running my application fails! :-(

Try putting it in src/main/webapp/META-INF.

> I know there is a tomcat plugin that builds the war AND deploys
> the war to a tomcat server, but I would like to do this step by
> step - as a first step, I want to manually move the war file into
> my tomcat webapps directory, if that works, I want to try to
> automatically do this with the tomcat plugin.

I don't know the tomcat plugin, I use cargo to deploy to servlet
containers. But if you don't want to use the tomcat plugin, just do not
configure it in your pom. Nothing will get deployed by default.

> However, I found out that the tomcat plugin can be configured like that:
> <groupId>org.codehaus.mojo</groupId>			<artifactId>tomcat-maven-plugin</artifactId>
> <configuration>
> <mode>both</mode>				<contextFile>src/context/context.xml</contextFile>
> 
> However, I didn't find anything similar for the maven war plugin.

Documentation for the m-war-p is here:
http://maven.apache.org/plugins/maven-war-plugin/

hth,
- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

putting context.xml into META-INF

Posted by Do...@gmx.de.
Hi,

i am using "mvn package" to create a war file of my project.
However, I found out that my context.xml file, located under
"src/context/context.xml", is missing in the META-INF directory of the war file! Therefore, running my application fails! :-(

I know there is a tomcat plugin that builds the war AND deploys the war to a tomcat server, but I would like to do this step by step - as a first step, I want to manually move the war file into my tomcat webapps directory, if that works, I want to try to automatically do this with the tomcat plugin.

However, I found out that the tomcat plugin can be configured like that:
<groupId>org.codehaus.mojo</groupId>			<artifactId>tomcat-maven-plugin</artifactId>
<configuration>
<mode>both</mode>				<contextFile>src/context/context.xml</contextFile>

However, I didn't find anything similar for the maven war plugin.

Any idea how this can be done?

Thanks in advance,

Stefanie
-- 
Psst! Geheimtipp: Online Games kostenlos spielen bei den GMX Free Games! 
http://games.entertainment.web.de/de/entertainment/games/free

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Migrating from Maven 1 to Maven 2

Posted by Dennis Lundberg <de...@apache.org>.
Dooing@gmx.de wrote:
> Hi,
> 
> I am currently migrating a big legacy project from Maven 1.02 to Maven 2.08. The project has lots of dependencies, many of which are not even used anymore, which are just transitive dependencies, or are just outdated.
> 
> Are there any tools, or best practices, that could help me in
> getting this tedious job done?

The Maven One Plugin [1] can be used to convert your project.xml and 
project.properties files into pom.xml files.


[1] http://maven.apache.org/plugins/maven-one-plugin/

> 
> Thanks in advance,
> 
> Stefanie


-- 
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by "simon.kitching@chello.at" <si...@chello.at>.
I'm pretty sure that dependencyManagement settings cannot be imported
from a "dependency" though. They can only be inherited from a parent
pom. So if the original question is really about dependencyManagement,
then the only solution is to use a common parent pom with those settings.

Well, another solution for dependencyManagement is of course to use a
repository that has only the versions that you want to be used. This is
a Frequently Asked Question; search the email archives for "mirrorOf"
for details, and see the maven docs on repositories if this is what is
actually wanted.

Regards,
Simon

Nicole Lacoste schrieb:
> Hi,
>
> Yes sorry I didn't catch that - the other pom should have a dependency
> management not a dependency section!  You want to enforce versions not
> dependencies.
>
> Nicole
>
> On 25/02/2008, simon.kitching@chello.at <si...@chello.at> wrote:
>   
>> Does your setup work when maven is run from the command-line?
>> If so, then that is a bug in the maven-eclipse-plugin, not in maven
>> itself.
>>
>> I'm not entirely convinced that the whole idea of having a block of
>> dependencies that multiple projects depend on is useful. Why would you
>> want such a thing? A project should normally declare exactly the
>> dependencies it needs, no more and no less. It would be odd for several
>> projects to have exactly the same dependencies.
>>
>> Anyway, the obvious way of managing "shared" dependencies (assuming you
>> really want to) would be to have a common parent pom, not by separating
>> out dependencies into a separate pom-project that is used as a dependency.
>>
>> However I cannot see why a pom-only dependency wouldn't work. If it
>> works in maven from the command-line, but the maven-eclipse-plugin
>> cannot handle it, then I suggest you file a bug against the
>> maven-eclipse-plugin.
>>
>> Are you perhaps trying to force specific versions of transient
>> dependencies to be used, eg you are depending on external projects and
>> want to be sure that *if* library Foo is pulled in transiently then a
>> specific version is used? That is handled via dependencyManagement, not
>> dependency declarations...
>>
>> Regards,
>> Simon
>>
>> Wolfgang.Schrecker@atosorigin.com schrieb:
>>     
>>> Hi Nicole,
>>>
>>> Thanks for the prompt reply.
>>> Yes the packaging is POM and it works (therefor) now.
>>> BUT:
>>>       only
>>>              mvn eclipse:eclipse
>>> now just wants to download the jar.
>>>
>>> mit freundlichen Grüßen/best regards
>>>
>>> Wolfgang Schrecker
>>>
>>>
>>>
>>>              "Nicole Lacoste"
>>>              <niki.lacoste@gma
>>>              il.com
>>>                                                    An
>>>                                         "Maven Users List"
>>>              25.02.2008 14:09           <us...@maven.apache.org>
>>>       
>>>                                                                      Kopie
>>>
>>>               Bitte
>>>       
>> antworten                                        Thema
>>     
>>>                     an                  Re: simple question concerning
>>>                "Maven Users             transitive dependencies [Virus
>>>                    List"                checked]
>>>              <users@maven.apac
>>>                   he.org>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>> Hi Wolfgang,
>>>
>>> Make sure that in the pom that contains the dependencies has right
>>> <packaging>.  It should be pom, if you don't mention packaging the
>>>       
>> default
>>     
>>> is jar.  When you depend on this artifact you need to mention type, I am
>>> not
>>> sure what you put here? Maybe pom too?  We have the same sort of thing,
>>>       
>> but
>>     
>>> we define this artifact as the parent of all our projects.
>>>
>>> Viel Gluck,
>>>
>>> Nicole
>>>
>>> On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
>>> Wolfgang.Schrecker@atosorigin.com> wrote:
>>>
>>>       
>>>> Hi All,
>>>>
>>>> in some projects, we need the same dependencies.
>>>> Although there must be a better way, I create a pom by hand containing
>>>> those dependencies in my local repository
>>>> and declared one dependency in the project to pull in that list.
>>>> Unfortunately, it does not work and MAVEN complains, there is no jar
>>>>         
>> file
>>     
>>>> for this dependency (and there isn't, of cause).
>>>>
>>>> Can someone point me to some docs explaining how to set up these
>>>> transitive
>>>> dependencies ?
>>>>
>>>> And how do I install those into a repository (like archiva) ?
>>>>
>>>> mit freundlichen Grüßen/best regards
>>>>
>>>> Wolfgang Schrecker
>>>>
>>>>         
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>>     
>
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by Nicole Lacoste <ni...@gmail.com>.
Hi,

Yes sorry I didn't catch that - the other pom should have a dependency
management not a dependency section!  You want to enforce versions not
dependencies.

Nicole

On 25/02/2008, simon.kitching@chello.at <si...@chello.at> wrote:
>
> Does your setup work when maven is run from the command-line?
> If so, then that is a bug in the maven-eclipse-plugin, not in maven
> itself.
>
> I'm not entirely convinced that the whole idea of having a block of
> dependencies that multiple projects depend on is useful. Why would you
> want such a thing? A project should normally declare exactly the
> dependencies it needs, no more and no less. It would be odd for several
> projects to have exactly the same dependencies.
>
> Anyway, the obvious way of managing "shared" dependencies (assuming you
> really want to) would be to have a common parent pom, not by separating
> out dependencies into a separate pom-project that is used as a dependency.
>
> However I cannot see why a pom-only dependency wouldn't work. If it
> works in maven from the command-line, but the maven-eclipse-plugin
> cannot handle it, then I suggest you file a bug against the
> maven-eclipse-plugin.
>
> Are you perhaps trying to force specific versions of transient
> dependencies to be used, eg you are depending on external projects and
> want to be sure that *if* library Foo is pulled in transiently then a
> specific version is used? That is handled via dependencyManagement, not
> dependency declarations...
>
> Regards,
> Simon
>
> Wolfgang.Schrecker@atosorigin.com schrieb:
> > Hi Nicole,
> >
> > Thanks for the prompt reply.
> > Yes the packaging is POM and it works (therefor) now.
> > BUT:
> >       only
> >              mvn eclipse:eclipse
> > now just wants to download the jar.
> >
> > mit freundlichen Grüßen/best regards
> >
> > Wolfgang Schrecker
> >
> >
> >
> >              "Nicole Lacoste"
> >              <niki.lacoste@gma
> >              il.com
> >                                                    An
> >                                         "Maven Users List"
> >              25.02.2008 14:09           <us...@maven.apache.org>
>
> >                                                                      Kopie
> >
> >               Bitte
> antworten                                        Thema
> >                     an                  Re: simple question concerning
> >                "Maven Users             transitive dependencies [Virus
> >                    List"                checked]
> >              <users@maven.apac
> >                   he.org>
> >
> >
> >
> >
> >
> >
> >
> >
> > Hi Wolfgang,
> >
> > Make sure that in the pom that contains the dependencies has right
> > <packaging>.  It should be pom, if you don't mention packaging the
> default
> > is jar.  When you depend on this artifact you need to mention type, I am
> > not
> > sure what you put here? Maybe pom too?  We have the same sort of thing,
> but
> > we define this artifact as the parent of all our projects.
> >
> > Viel Gluck,
> >
> > Nicole
> >
> > On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
> > Wolfgang.Schrecker@atosorigin.com> wrote:
> >
> >> Hi All,
> >>
> >> in some projects, we need the same dependencies.
> >> Although there must be a better way, I create a pom by hand containing
> >> those dependencies in my local repository
> >> and declared one dependency in the project to pull in that list.
> >> Unfortunately, it does not work and MAVEN complains, there is no jar
> file
> >> for this dependency (and there isn't, of cause).
> >>
> >> Can someone point me to some docs explaining how to set up these
> >> transitive
> >> dependencies ?
> >>
> >> And how do I install those into a repository (like archiva) ?
> >>
> >> mit freundlichen Grüßen/best regards
> >>
> >> Wolfgang Schrecker
> >>
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Antwort: Re: Antwort: Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by Wo...@atosorigin.com.
Hi Simon,

somewhere in the company there is a group creating something, let's say for
batch import/export.
not all projects need this, but most do.
this [application,component,set of libraries] may be used in at least two
ways:

1.) you include the 15 dependencies from this [application,component,set of
libraries] and you are set.
2.) you include one dependency, which is nothing but a pom in the local
repository, referencing all those 15 dependencies.

when this [application,component,set of libraries] gets updated in just 2
components with two new version numbers,
all from 1.) have to change in their respectice projects the version
numbers accordingly, if they want the changes.
all from 2.) have to change their one component (if they want the changes)
and couldn't care less what exactly in which components have changed.

And it does work, if you set it up by copy/paste/edit in your local
repository.


mit freundlichen Grüßen/best regards

Wolfgang Schrecker

"MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
implementation, but it allows freedom to choose any implementation that
faithfully captures the meaning of the model"
from Eric Evans: Domain-Driven Design p. 230



 --
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstrasse 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
mailto:Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417
 
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstraße 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
Fax :
mailto: Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
This e-mail is destined for the above mentioned recipient. In case you
received this e-mail by accident, we would appreciate it if you could
contact the sender and delete all copies stored on your computer.
Please be aware that the security and confidentiality of electronic data
transmitted by e-mail is not completely guaranteed and that data may be seen,
copied, downloaded or changed by third persons during transmission.
Atos Origin accepts no liability for the security and confidentiality of
data and documents sent by e-mail. Please make sure that all important
messages will be confirmed in writing by means of a telefax or a letter.
* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *

Re: Antwort: Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by simon <si...@chello.at>.
On Mon, 2008-02-25 at 18:09 +0100, Wolfgang.Schrecker@atosorigin.com
wrote:
> Hi Simon,
> 
>  yes, I think it does make sense, just as transitive dependencies make
> sense.
> 
>   if you publish a component containing another set of jars and their
> various versions, you may want it to be known as a single version e.g. 3.5
>   and if update your bundle only advance the components version (say to
> 3.5.1)
>   with no need for every deveoper to change the version of every component
> but just the main version (here 3.5->3.5.1).

Sorry Wolfgang bug I still have no idea what you are trying to say here.

There are two types of things that get published:
  * applications
  * libraries

When publishing an application, there is no need to worry about
transitive dependencies; everything the user needs is bundled with the
application and the user really doesn't care what libs are used
internally.

When publishing a library, you publish *just* your code, plus
information about what libs your code needs, and the version-ranges that
are acceptable for it (ie a pom file). The application that uses your
library may well then override your recommended dependency versions if
they prefer to use other versions for any reason.

What exactly is the use-case you are trying to support?

Regards,
Simon


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Antwort: Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by Wo...@atosorigin.com.
Hi Simon,

 yes, I think it does make sense, just as transitive dependencies make
sense.

  if you publish a component containing another set of jars and their
various versions, you may want it to be known as a single version e.g. 3.5
  and if update your bundle only advance the components version (say to
3.5.1)
  with no need for every deveoper to change the version of every component
but just the main version (here 3.5->3.5.1).

  And of cause you are right, why should a pom only version not work.

 I agree, if it is a bug it is maven-eclipse-plugin ' bug.

mit freundlichen Grüßen/best regards

Wolfgang Schrecker

"MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
implementation, but it allows freedom to choose any implementation that
faithfully captures the meaning of the model"
from Eric Evans: Domain-Driven Design p. 230



 --
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstrasse 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
mailto:Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


                                                                           
             "simon.kitching@c                                             
             hello.at"                                                     
             <simon.kitching@c                                          An 
             hello.at>                  Maven Users List                   
                                        <us...@maven.apache.org>           
             25.02.2008 15:58                                        Kopie 
                                                                           
                                                                     Thema 
              Bitte antworten           Re: Antwort: Re: simple question   
                    an                  concerning transitive dependencies 
               "Maven Users             [Virus checked]                    
                   List"                                                   
             <users@maven.apac                                             
                  he.org>                                                  
                                                                           
                                                                           
                                                                           




Does your setup work when maven is run from the command-line?
If so, then that is a bug in the maven-eclipse-plugin, not in maven itself.

I'm not entirely convinced that the whole idea of having a block of
dependencies that multiple projects depend on is useful. Why would you
want such a thing? A project should normally declare exactly the
dependencies it needs, no more and no less. It would be odd for several
projects to have exactly the same dependencies.

Anyway, the obvious way of managing "shared" dependencies (assuming you
really want to) would be to have a common parent pom, not by separating
out dependencies into a separate pom-project that is used as a dependency.

However I cannot see why a pom-only dependency wouldn't work. If it
works in maven from the command-line, but the maven-eclipse-plugin
cannot handle it, then I suggest you file a bug against the
maven-eclipse-plugin.

Are you perhaps trying to force specific versions of transient
dependencies to be used, eg you are depending on external projects and
want to be sure that *if* library Foo is pulled in transiently then a
specific version is used? That is handled via dependencyManagement, not
dependency declarations...

Regards,
Simon

Wolfgang.Schrecker@atosorigin.com schrieb:
> Hi Nicole,
>
> Thanks for the prompt reply.
> Yes the packaging is POM and it works (therefor) now.
> BUT:
>       only
>              mvn eclipse:eclipse
> now just wants to download the jar.
>
> mit freundlichen Grüßen/best regards
>
> Wolfgang Schrecker
>
>
>

>              "Nicole Lacoste"

>              <niki.lacoste@gma

>              il.com>
An
>                                         "Maven Users List"

>              25.02.2008 14:09           <us...@maven.apache.org>

>
Kopie
>

>               Bitte antworten
Thema
>                     an                  Re: simple question concerning

>                "Maven Users             transitive dependencies [Virus

>                    List"                checked]

>              <users@maven.apac

>                   he.org>

>

>

>

>

>
>
>
>
> Hi Wolfgang,
>
> Make sure that in the pom that contains the dependencies has right
> <packaging>.  It should be pom, if you don't mention packaging the
default
> is jar.  When you depend on this artifact you need to mention type, I am
> not
> sure what you put here? Maybe pom too?  We have the same sort of thing,
but
> we define this artifact as the parent of all our projects.
>
> Viel Gluck,
>
> Nicole
>
> On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
> Wolfgang.Schrecker@atosorigin.com> wrote:
>
>> Hi All,
>>
>> in some projects, we need the same dependencies.
>> Although there must be a better way, I create a pom by hand containing
>> those dependencies in my local repository
>> and declared one dependency in the project to pull in that list.
>> Unfortunately, it does not work and MAVEN complains, there is no jar
file
>> for this dependency (and there isn't, of cause).
>>
>> Can someone point me to some docs explaining how to set up these
>> transitive
>> dependencies ?
>>
>> And how do I install those into a repository (like archiva) ?
>>
>> mit freundlichen Grüßen/best regards
>>
>> Wolfgang Schrecker
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org



 
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstraße 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
Fax :
mailto: Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
This e-mail is destined for the above mentioned recipient. In case you
received this e-mail by accident, we would appreciate it if you could
contact the sender and delete all copies stored on your computer.
Please be aware that the security and confidentiality of electronic data
transmitted by e-mail is not completely guaranteed and that data may be seen,
copied, downloaded or changed by third persons during transmission.
Atos Origin accepts no liability for the security and confidentiality of
data and documents sent by e-mail. Please make sure that all important
messages will be confirmed in writing by means of a telefax or a letter.
* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *

Re: Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by "simon.kitching@chello.at" <si...@chello.at>.
Does your setup work when maven is run from the command-line?
If so, then that is a bug in the maven-eclipse-plugin, not in maven itself.

I'm not entirely convinced that the whole idea of having a block of
dependencies that multiple projects depend on is useful. Why would you
want such a thing? A project should normally declare exactly the
dependencies it needs, no more and no less. It would be odd for several
projects to have exactly the same dependencies.

Anyway, the obvious way of managing "shared" dependencies (assuming you
really want to) would be to have a common parent pom, not by separating
out dependencies into a separate pom-project that is used as a dependency.

However I cannot see why a pom-only dependency wouldn't work. If it
works in maven from the command-line, but the maven-eclipse-plugin
cannot handle it, then I suggest you file a bug against the
maven-eclipse-plugin.

Are you perhaps trying to force specific versions of transient
dependencies to be used, eg you are depending on external projects and
want to be sure that *if* library Foo is pulled in transiently then a
specific version is used? That is handled via dependencyManagement, not
dependency declarations...

Regards,
Simon

Wolfgang.Schrecker@atosorigin.com schrieb:
> Hi Nicole,
>
> Thanks for the prompt reply.
> Yes the packaging is POM and it works (therefor) now.
> BUT:
>       only
>              mvn eclipse:eclipse
> now just wants to download the jar.
>
> mit freundlichen Grüßen/best regards
>
> Wolfgang Schrecker
>
>
>                                                                            
>              "Nicole Lacoste"                                              
>              <niki.lacoste@gma                                             
>              il.com>                                                    An 
>                                         "Maven Users List"                 
>              25.02.2008 14:09           <us...@maven.apache.org>           
>                                                                      Kopie 
>                                                                            
>               Bitte antworten                                        Thema 
>                     an                  Re: simple question concerning     
>                "Maven Users             transitive dependencies [Virus     
>                    List"                checked]                           
>              <users@maven.apac                                             
>                   he.org>                                                  
>                                                                            
>                                                                            
>                                                                            
>                                                                            
>
>
>
>
> Hi Wolfgang,
>
> Make sure that in the pom that contains the dependencies has right
> <packaging>.  It should be pom, if you don't mention packaging the default
> is jar.  When you depend on this artifact you need to mention type, I am
> not
> sure what you put here? Maybe pom too?  We have the same sort of thing, but
> we define this artifact as the parent of all our projects.
>
> Viel Gluck,
>
> Nicole
>
> On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
> Wolfgang.Schrecker@atosorigin.com> wrote:
>   
>> Hi All,
>>
>> in some projects, we need the same dependencies.
>> Although there must be a better way, I create a pom by hand containing
>> those dependencies in my local repository
>> and declared one dependency in the project to pull in that list.
>> Unfortunately, it does not work and MAVEN complains, there is no jar file
>> for this dependency (and there isn't, of cause).
>>
>> Can someone point me to some docs explaining how to set up these
>> transitive
>> dependencies ?
>>
>> And how do I install those into a repository (like archiva) ?
>>
>> mit freundlichen Grüßen/best regards
>>
>> Wolfgang Schrecker
>>     
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Antwort: Re: simple question concerning transitive dependencies [Virus checked]

Posted by Wo...@atosorigin.com.
Hi Nicole,

Thanks for the prompt reply.
Yes the packaging is POM and it works (therefor) now.
BUT:
      only
             mvn eclipse:eclipse
now just wants to download the jar.

mit freundlichen Grüßen/best regards

Wolfgang Schrecker

"MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
implementation, but it allows freedom to choose any implementation that
faithfully captures the meaning of the model"
from Eric Evans: Domain-Driven Design p. 230



 --
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstrasse 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
mailto:Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


                                                                           
             "Nicole Lacoste"                                              
             <niki.lacoste@gma                                             
             il.com>                                                    An 
                                        "Maven Users List"                 
             25.02.2008 14:09           <us...@maven.apache.org>           
                                                                     Kopie 
                                                                           
              Bitte antworten                                        Thema 
                    an                  Re: simple question concerning     
               "Maven Users             transitive dependencies [Virus     
                   List"                checked]                           
             <users@maven.apac                                             
                  he.org>                                                  
                                                                           
                                                                           
                                                                           
                                                                           




Hi Wolfgang,

Make sure that in the pom that contains the dependencies has right
<packaging>.  It should be pom, if you don't mention packaging the default
is jar.  When you depend on this artifact you need to mention type, I am
not
sure what you put here? Maybe pom too?  We have the same sort of thing, but
we define this artifact as the parent of all our projects.

Viel Gluck,

Nicole

On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
Wolfgang.Schrecker@atosorigin.com> wrote:
>
> Hi All,
>
> in some projects, we need the same dependencies.
> Although there must be a better way, I create a pom by hand containing
> those dependencies in my local repository
> and declared one dependency in the project to pull in that list.
> Unfortunately, it does not work and MAVEN complains, there is no jar file
> for this dependency (and there isn't, of cause).
>
> Can someone point me to some docs explaining how to set up these
> transitive
> dependencies ?
>
> And how do I install those into a repository (like archiva) ?
>
> mit freundlichen Grüßen/best regards
>
> Wolfgang Schrecker
>
> "MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
> implementation, but it allows freedom to choose any implementation that
> faithfully captures the meaning of the model"
> from Eric Evans: Domain-Driven Design p. 230
>
>
>
>   --
> --------------------------------------------------
>
> Atos Worldline Processing GmbH
> Hahnstrasse 25
> 60528 Frankfurt/Main
> Germany
> Phone: +49 69/6657-1176
> mailto:Wolfgang.Schrecker@atosorigin.com
> http://www.atosworldline.com
>
> Geschäftsführer: Erik Munk Koefoed
> Aufsichtsratsvorsitzender: Didier Dhennin
> Sitz der Gesellschaft: Frankfurt/Main
> Handelsregister: Frankfurt/Main HRB 40 417
>
> PS: Besuchen Sie am 21.02.2008 das Achte Kartenforum von Atos Worldline
> und B+S Card Service.
> Infos und Anmeldung unter http://www.kartenforum.de
> --------------------------------------------------
>
> Atos Worldline Processing GmbH
> Hahnstraße 25
> 60528 Frankfurt/Main
> Germany
> Phone: +49 69/6657-1176
> Fax :
> mailto: Wolfgang.Schrecker@atosorigin.com
> http://www.atosworldline.com
>
> Geschäftsführer: Erik Munk Koefoed
> Aufsichtsratsvorsitzender: Didier Dhennin
> Sitz der Gesellschaft: Frankfurt/Main
> Handelsregister: Frankfurt/Main HRB 40 417
>
>
> * * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
> This e-mail is destined for the above mentioned recipient. In case you
> received this e-mail by accident, we would appreciate it if you could
> contact the sender and delete all copies stored on your computer.
> Please be aware that the security and confidentiality of electronic data
> transmitted by e-mail is not completely guaranteed and that data may be
> seen,
> copied, downloaded or changed by third persons during transmission.
> Atos Origin accepts no liability for the security and confidentiality of
> data and documents sent by e-mail. Please make sure that all important
> messages will be confirmed in writing by means of a telefax or a letter.
> * * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
>

 
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstraße 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
Fax :
mailto: Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
This e-mail is destined for the above mentioned recipient. In case you
received this e-mail by accident, we would appreciate it if you could
contact the sender and delete all copies stored on your computer.
Please be aware that the security and confidentiality of electronic data
transmitted by e-mail is not completely guaranteed and that data may be seen,
copied, downloaded or changed by third persons during transmission.
Atos Origin accepts no liability for the security and confidentiality of
data and documents sent by e-mail. Please make sure that all important
messages will be confirmed in writing by means of a telefax or a letter.
* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *

Re: simple question concerning transitive dependencies [Virus checked]

Posted by Nicole Lacoste <ni...@gmail.com>.
Hi Wolfgang,

Make sure that in the pom that contains the dependencies has right
<packaging>.  It should be pom, if you don't mention packaging the default
is jar.  When you depend on this artifact you need to mention type, I am not
sure what you put here? Maybe pom too?  We have the same sort of thing, but
we define this artifact as the parent of all our projects.

Viel Gluck,

Nicole

On 25/02/2008, Wolfgang.Schrecker@atosorigin.com <
Wolfgang.Schrecker@atosorigin.com> wrote:
>
> Hi All,
>
> in some projects, we need the same dependencies.
> Although there must be a better way, I create a pom by hand containing
> those dependencies in my local repository
> and declared one dependency in the project to pull in that list.
> Unfortunately, it does not work and MAVEN complains, there is no jar file
> for this dependency (and there isn't, of cause).
>
> Can someone point me to some docs explaining how to set up these
> transitive
> dependencies ?
>
> And how do I install those into a repository (like archiva) ?
>
> mit freundlichen Grüßen/best regards
>
> Wolfgang Schrecker
>
> "MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
> implementation, but it allows freedom to choose any implementation that
> faithfully captures the meaning of the model"
> from Eric Evans: Domain-Driven Design p. 230
>
>
>
>   --
> --------------------------------------------------
>
> Atos Worldline Processing GmbH
> Hahnstrasse 25
> 60528 Frankfurt/Main
> Germany
> Phone: +49 69/6657-1176
> mailto:Wolfgang.Schrecker@atosorigin.com
> http://www.atosworldline.com
>
> Geschäftsführer: Erik Munk Koefoed
> Aufsichtsratsvorsitzender: Didier Dhennin
> Sitz der Gesellschaft: Frankfurt/Main
> Handelsregister: Frankfurt/Main HRB 40 417
>
> PS: Besuchen Sie am 21.02.2008 das Achte Kartenforum von Atos Worldline
> und B+S Card Service.
> Infos und Anmeldung unter http://www.kartenforum.de
> --------------------------------------------------
>
> Atos Worldline Processing GmbH
> Hahnstraße 25
> 60528 Frankfurt/Main
> Germany
> Phone: +49 69/6657-1176
> Fax :
> mailto: Wolfgang.Schrecker@atosorigin.com
> http://www.atosworldline.com
>
> Geschäftsführer: Erik Munk Koefoed
> Aufsichtsratsvorsitzender: Didier Dhennin
> Sitz der Gesellschaft: Frankfurt/Main
> Handelsregister: Frankfurt/Main HRB 40 417
>
>
> * * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
> This e-mail is destined for the above mentioned recipient. In case you
> received this e-mail by accident, we would appreciate it if you could
> contact the sender and delete all copies stored on your computer.
> Please be aware that the security and confidentiality of electronic data
> transmitted by e-mail is not completely guaranteed and that data may be
> seen,
> copied, downloaded or changed by third persons during transmission.
> Atos Origin accepts no liability for the security and confidentiality of
> data and documents sent by e-mail. Please make sure that all important
> messages will be confirmed in writing by means of a telefax or a letter.
> * * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
>

simple question concerning transitive dependencies [Virus checked]

Posted by Wo...@atosorigin.com.
Hi All,

in some projects, we need the same dependencies.
Although there must be a better way, I create a pom by hand containing
those dependencies in my local repository
and declared one dependency in the project to pull in that list.
Unfortunately, it does not work and MAVEN complains, there is no jar file
for this dependency (and there isn't, of cause).

Can someone point me to some docs explaining how to set up these transitive
dependencies ?

And how do I install those into a repository (like archiva) ?

mit freundlichen Grüßen/best regards

Wolfgang Schrecker

"MODEL-DRIVEN DESIGN demands that the model stay in lockstep with the
implementation, but it allows freedom to choose any implementation that
faithfully captures the meaning of the model"
from Eric Evans: Domain-Driven Design p. 230



 --
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstrasse 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
mailto:Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417
 
PS: Besuchen Sie am 21.02.2008 das Achte Kartenforum von Atos Worldline und B+S Card Service.
Infos und Anmeldung unter http://www.kartenforum.de
--------------------------------------------------

Atos Worldline Processing GmbH
Hahnstraße 25
60528 Frankfurt/Main
Germany
Phone: +49 69/6657-1176
Fax :
mailto: Wolfgang.Schrecker@atosorigin.com
http://www.atosworldline.com

Geschäftsführer: Erik Munk Koefoed
Aufsichtsratsvorsitzender: Didier Dhennin
Sitz der Gesellschaft: Frankfurt/Main
Handelsregister: Frankfurt/Main HRB 40 417


* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *
This e-mail is destined for the above mentioned recipient. In case you
received this e-mail by accident, we would appreciate it if you could
contact the sender and delete all copies stored on your computer.
Please be aware that the security and confidentiality of electronic data
transmitted by e-mail is not completely guaranteed and that data may be seen,
copied, downloaded or changed by third persons during transmission.
Atos Origin accepts no liability for the security and confidentiality of
data and documents sent by e-mail. Please make sure that all important
messages will be confirmed in writing by means of a telefax or a letter.
* * * * * * * * L E G A L    D I S C L A I M E R * * * * * * * *

Re: Migrating from Maven 1 to Maven 2

Posted by Dennis Lundberg <de...@apache.org>.
Dooing@gmx.de wrote:
>> What exactly are you looking for help with?
>>
>> Converting the project.xml into pom.xml?
>> Analyzing your dependencies to see what is actually needed?
>> Something else entirely?
>>
>> Wayne
> 
> Well, a converter from project.xml to pom.xml would be a first start,
> then, yes, something to analyze the depependencies, to tell me which
> dependencies are simply transitive dependencies -
> example - if I had a maven 1project with dependencies a, b, c, and this analyzer tells me that b needs c, I could realize that a needs be and b needs c -> transitive.
> But how could I find out which dependencies are not used at all anymore?

You can use the dependency-plugin for this. The following command will 
analyze the dependencies for your Maven 2 project and tell you what 
dependencies can be removed and what dependencies should be added.

mvn dependency:analyze

> And is there a way to tell maven to just retrieve the newest version from the repo? I know there is dependencymanagement, which I am using at great extend, is there a way / shouldn't it be possible to just leave the version number, so that maven retrieves the newest version of this dependeny?
> As I am doing a big step anyway - moving to maven 2 - I think I could just as well do a big clean up and also update all dependencies were possible.
> 
> Thanks,
> 
> Stefanie


-- 
Dennis Lundberg

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Migrating from Maven 1 to Maven 2

Posted by Do...@gmx.de.
> What exactly are you looking for help with?
> 
> Converting the project.xml into pom.xml?
> Analyzing your dependencies to see what is actually needed?
> Something else entirely?
> 
> Wayne

Well, a converter from project.xml to pom.xml would be a first start,
then, yes, something to analyze the depependencies, to tell me which
dependencies are simply transitive dependencies -
example - if I had a maven 1project with dependencies a, b, c, and this analyzer tells me that b needs c, I could realize that a needs be and b needs c -> transitive.
But how could I find out which dependencies are not used at all anymore?
And is there a way to tell maven to just retrieve the newest version from the repo? I know there is dependencymanagement, which I am using at great extend, is there a way / shouldn't it be possible to just leave the version number, so that maven retrieves the newest version of this dependeny?
As I am doing a big step anyway - moving to maven 2 - I think I could just as well do a big clean up and also update all dependencies were possible.

Thanks,

Stefanie
-- 
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen! 
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Migrating from Maven 1 to Maven 2

Posted by Wayne Fay <wa...@gmail.com>.
What exactly are you looking for help with?

Converting the project.xml into pom.xml?
Analyzing your dependencies to see what is actually needed?
Something else entirely?

Wayne

On 2/21/08, Dooing@gmx.de <Do...@gmx.de> wrote:
> Hi,
>
> I am currently migrating a big legacy project from Maven 1.02 to Maven 2.08. The project has lots of dependencies, many of which are not even used anymore, which are just transitive dependencies, or are just outdated.
>
> Are there any tools, or best practices, that could help me in
> getting this tedious job done?
>
> Thanks in advance,
>
> Stefanie
> --
> Psssst! Schon vom neuen GMX MultiMessenger gehört?
> Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Migrating from Maven 1 to Maven 2

Posted by Do...@gmx.de.
Hi,

I am currently migrating a big legacy project from Maven 1.02 to Maven 2.08. The project has lots of dependencies, many of which are not even used anymore, which are just transitive dependencies, or are just outdated.

Are there any tools, or best practices, that could help me in
getting this tedious job done?

Thanks in advance,

Stefanie
-- 
Psssst! Schon vom neuen GMX MultiMessenger gehört?
Der kann`s mit allen: http://www.gmx.net/de/go/multimessenger

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Arnaud HERITIER <ah...@gmail.com>.
I prefer to have a new issue and a link between them.
You can wait to have it fixed OR you can propose a patch (code+test+doc) to
be sure it will be.

Arnaud

On Thu, Feb 21, 2008 at 10:24 AM, Martin Höller <ma...@xss.co.at> wrote:

> On Thursday 21 February 2008 wrote Arnaud HERITIER:
> > I think we have several problems with manifest in 2.5-SNAPSHOT :-(
> > wtpmanifest = true creates several problems.
> > We noticed this one :
> > http://jira.codehaus.org/browse/MECLIPSE-389
> > It can be (or not) related
>
> It is (at least somehow) related.
>
> Should I file an extra issue for this one or just add a comment to
> MECLIPSE-389 and wait till it's eventually fixed?
>
> thanks,
> - martin
> --
> Martin Höller                   | martin.hoeller@xss.co.at
> *x Software + Systeme           | http://www.xss.co.at/
> Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
> A-1100 Vienna, Austria          | Fax: +43-1-6060114-71
>



-- 
..........................................................
Arnaud HERITIER
..........................................................
OCTO Technology - aheritier AT octo DOT com
www.octo.com | blog.octo.com
..........................................................
ASF - aheritier AT apache DOT org
www.apache.org | maven.apache.org
...........................................................

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Martin Höller <ma...@xss.co.at>.
On Thursday 21 February 2008 wrote Arnaud HERITIER:
> I think we have several problems with manifest in 2.5-SNAPSHOT :-(
> wtpmanifest = true creates several problems.
> We noticed this one :
> http://jira.codehaus.org/browse/MECLIPSE-389
> It can be (or not) related

It is (at least somehow) related.

Should I file an extra issue for this one or just add a comment to 
MECLIPSE-389 and wait till it's eventually fixed?

thanks,
- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Arnaud HERITIER <ah...@gmail.com>.
I think we have several problems with manifest in 2.5-SNAPSHOT :-(
wtpmanifest = true creates several problems.
We noticed this one :
http://jira.codehaus.org/browse/MECLIPSE-389
It can be (or not) related

Arnaud

On Thu, Feb 21, 2008 at 8:20 AM, Martin Höller <ma...@xss.co.at> wrote:

> On Wednesday 20 February 2008 wrote Graham Leggett:
> > Martin Höller wrote:
> > > I just noticed that the maven-eclipse-plugin (2.5-SNAPHSOT) writes a
> > > MANIFEST.MF output to src/main/webapp/META-INF when mvn
> eclipse:eclipse
> > > is called for a web-application.
> > >
> > > Is this behaviour intentional? I wouldn't expect maven or any plugin
> to
> > > write something into src/main.
> >
> > Is your project marked as a pde project?
>
> No, it's not, it's a WTP 2.0 project. My plugin configuration is as
> follows:
>
>        <plugin>
>          <groupId>org.apache.maven.plugins</groupId>
>          <artifactId>maven-eclipse-plugin</artifactId>
>          <version>2.5-SNAPSHOT</version>
>          <configuration>
>            <downloadSources>false</downloadSources>
>            <downloadJavadocs>false</downloadJavadocs>
>            <wtpversion>2.0</wtpversion>
>            <wtpmanifest>true</wtpmanifest>
>          </configuration>
>        </plugin>
>
> > > If the MANIFEST.MF is needed by eclipse, couldn't it be written to
> > > target/ and eclipse be configured to use that instead, just as it
> > > happens for EARs?
> >
> > Not practically, no. Eclipse does not have a clear distinction between
> > "source" directories and "target" directories, so you need to modify the
> > files where they lie, which can be annoying, particularly for Eclipse
> > plugin builds.
>
> Well, this file is not created by eclipse but by the m-eclipse-p. And I
> would say this plugin shouldn't write to src/main/...
>
> What I want is already done for EARs: an application.xml is required for a
> valid EAR, so m-eclipse-p creates one in target/eclipseEar/META-INF/ and
> points eclipse to this file as the application descriptor.
>
> I think this should also be possible for WARs, shouldn't it?
>
> - martin
> --
> Martin Höller                   | martin.hoeller@xss.co.at
> *x Software + Systeme           | http://www.xss.co.at/
> Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
> A-1100 Vienna, Austria          | Fax: +43-1-6060114-71
>



-- 
..........................................................
Arnaud HERITIER
..........................................................
OCTO Technology - aheritier AT octo DOT com
www.octo.com | blog.octo.com
..........................................................
ASF - aheritier AT apache DOT org
www.apache.org | maven.apache.org
...........................................................

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Martin Höller <ma...@xss.co.at>.
On Thursday 21 February 2008 wrote Graham Leggett:
> Martin Höller wrote:
> > No, it's not, it's a WTP 2.0 project. My plugin configuration is as
> > follows:
> >
> >         <plugin>
> >           <groupId>org.apache.maven.plugins</groupId>
> >           <artifactId>maven-eclipse-plugin</artifactId>
> >           <version>2.5-SNAPSHOT</version>
> >           <configuration>
> >             <downloadSources>false</downloadSources>
> >             <downloadJavadocs>false</downloadJavadocs>
> >             <wtpversion>2.0</wtpversion>
> >             <wtpmanifest>true</wtpmanifest>
>
>                             ^^^^
>
> >           </configuration>
> >         </plugin>
>
> What purpose does this serve?

I need a MANIFEST.MF for the classpath (it's a skinny war as it is part of 
an EAR)

> > Well, this file is not created by eclipse but by the m-eclipse-p. And I
> > would say this plugin shouldn't write to src/main/...
>
> The way Eclipse deals with manifest files is they are considered part of
> the source code, not a generated artifact.

Yeah, that's why I want maven to generate it for eclipse as maven has all 
the information that belongs into the MANIFEST.MF

> As a result, if you want to synchronise Eclipse with anything in maven,
> you have to edit the existing files where Eclipse put them.

Eclipse didn't and wouldn't put MANIFEST.MF anywhere if it didn't exist, so 
either I create it by hand (what is not what I want) or let maven create it 
for me, which the m-eclipse-p obviously is designed for. It's just the 
location of the file that isn't configurable and has IMHO a bad default.

thanks for you answer anyway,
- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Graham Leggett <mi...@sharp.fm>.
Martin Höller wrote:

> No, it's not, it's a WTP 2.0 project. My plugin configuration is as follows:
> 
>         <plugin>
>           <groupId>org.apache.maven.plugins</groupId>
>           <artifactId>maven-eclipse-plugin</artifactId>
>           <version>2.5-SNAPSHOT</version>
>           <configuration>
>             <downloadSources>false</downloadSources>
>             <downloadJavadocs>false</downloadJavadocs>
>             <wtpversion>2.0</wtpversion>
>             <wtpmanifest>true</wtpmanifest>
                            ^^^^
>           </configuration>
>         </plugin>

What purpose does this serve?

> Well, this file is not created by eclipse but by the m-eclipse-p. And I 
> would say this plugin shouldn't write to src/main/...

The way Eclipse deals with manifest files is they are considered part of 
the source code, not a generated artifact.

As a result, if you want to synchronise Eclipse with anything in maven, 
you have to edit the existing files where Eclipse put them.

Remember that unlike in the maven world, where absolutely everything is 
in the pom, and all other files are generated from scratch, in the 
Eclipse world information is scattered across the various files in the 
source tree. Maven can only edit a subset of the information in these 
files, as maven doesn't have enough knowledge to regenerate the file 
from scratch.

Regards,
Graham
--


Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Martin Höller <ma...@xss.co.at>.
On Wednesday 20 February 2008 wrote Graham Leggett:
> Martin Höller wrote:
> > I just noticed that the maven-eclipse-plugin (2.5-SNAPHSOT) writes a
> > MANIFEST.MF output to src/main/webapp/META-INF when mvn eclipse:eclipse
> > is called for a web-application.
> >
> > Is this behaviour intentional? I wouldn't expect maven or any plugin to
> > write something into src/main.
>
> Is your project marked as a pde project?

No, it's not, it's a WTP 2.0 project. My plugin configuration is as follows:

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-eclipse-plugin</artifactId>
          <version>2.5-SNAPSHOT</version>
          <configuration>
            <downloadSources>false</downloadSources>
            <downloadJavadocs>false</downloadJavadocs>
            <wtpversion>2.0</wtpversion>
            <wtpmanifest>true</wtpmanifest>
          </configuration>
        </plugin>

> > If the MANIFEST.MF is needed by eclipse, couldn't it be written to
> > target/ and eclipse be configured to use that instead, just as it
> > happens for EARs?
>
> Not practically, no. Eclipse does not have a clear distinction between
> "source" directories and "target" directories, so you need to modify the
> files where they lie, which can be annoying, particularly for Eclipse
> plugin builds.

Well, this file is not created by eclipse but by the m-eclipse-p. And I 
would say this plugin shouldn't write to src/main/...

What I want is already done for EARs: an application.xml is required for a 
valid EAR, so m-eclipse-p creates one in target/eclipseEar/META-INF/ and 
points eclipse to this file as the application descriptor.

I think this should also be possible for WARs, shouldn't it?

- martin
-- 
Martin Höller                   | martin.hoeller@xss.co.at
*x Software + Systeme           | http://www.xss.co.at/
Karmarschgasse 51/2/20          | Tel: +43-1-6060114-30
A-1100 Vienna, Austria          | Fax: +43-1-6060114-71

Re: maven-eclipse-plugin writes to src/main/webapp

Posted by Graham Leggett <mi...@sharp.fm>.
Martin Höller wrote:

> I just noticed that the maven-eclipse-plugin (2.5-SNAPHSOT) writes a 
> MANIFEST.MF output to src/main/webapp/META-INF when mvn eclipse:eclipse is 
> called for a web-application.
> 
> Is this behaviour intentional? I wouldn't expect maven or any plugin to 
> write something into src/main.

Is your project marked as a pde project?

> If the MANIFEST.MF is needed by eclipse, couldn't it be written to target/ 
> and eclipse be configured to use that instead, just as it happens for EARs?

Not practically, no. Eclipse does not have a clear distinction between 
"source" directories and "target" directories, so you need to modify the 
files where they lie, which can be annoying, particularly for Eclipse 
plugin builds.

Regards,
Graham
--