continuum-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Simon Kitching" <skitch...@gfg-group.com>
Subject RE: SVN paths when adding an m2 pom with module declarations
Date Thu, 20 Apr 2006 20:32:10 GMT
Hi Emmanuel,


  _____  

From: Emmanuel Venisse [mailto:emmanuel@venisse.net] 
Sent: Thursday, April 20, 2006 7:57 PM
To: continuum-users@maven.apache.org
Subject: Re: SVN paths when adding an m2 pom with module declarations




Simon Kitching a écrit :
> Hi,
> 
> I've got a pom with this:
> 
> scm:svn:http://.../trunk
> 
> 
> 
> common/core
> common/business
> transactions/transaction-server
> transactions/payment-server
> transactions/billing-server
> transactions/im_handset_sim
> management
> 
> 
> I specified the URL to this pom in continuum 20040414. Continuum correctly
> added each of the child modules as a separate "project". However the SVN
> urls are not set right. For example, the "core" module thinks its svn path
> is:
> http://.../trunk/common-core
> when it should be using
> http://.../trunk/common/core

It's a problem in maven api.
maven use artifactId and not module name for path resolution. 
 
Do you have set the parent relativePath in your modules if it isn't
../pom.xml (the default value) 
 
Yes, each of the modules has:
<parent> 

 <artifactId>system</artifactId>

<groupId>com.gfggroup.mobile</groupId>

<version>1.0-SNAPSHOT</version>

<relativePath>../../pom.xml</relativePath>

</parent >  

And yes, it makes sense that given the scm url of a parent pom, and the
relative path from project X to its parent, the scm url of project X can be
determined. But unfortunately it definitely isn't working that way for
continuum at the moment.

I tried your suggestion of "mvn help:effective-pom", and maven is definitely
not getting it right:

  <scm>
 
<connection>scm:svn:http://gfgdev4/svn/peregrine/trunk/transactions-txcore</
connection>
    <url>http://gfgdev4/svn/peregrine/transactions-txcore</url>
  </scm>

I will therefore file a bug against maven. 

However it seems to me that the safest option for Continuum would be to
calculate the scm url based on the scm url of the originally imported
module, and the module path to each project. After all, a pom can have
module declarations pointing to projects that have no parent. In this
situation, continuum has enough information to compute the scm urls (because
it's walking from the original pom down to the declared modules) even though
it's not possible to deduce the scm url by looking at each individual
project.


> 
> In other words, it's appending the child pom artifactId to the base scm
url,
> when it should be using the module path that led to that pom.
> 
> Is there any way to tell it what the correct URL is? I noticed that in
> continuum 1.0.2, I could click on the project name then use the "edit"
> button to modify the project details. I can't find how to do this in
> 20040414...any hints?

If the relativePath doesn't solve your pb, you should define the in your
modules. 

Yes, I guess I could put an <scm> block in every pom in the tree, and will
do so now. 

Many thanks for your reply.

Regards,

Simon


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message