Hi Brett,
Here's a summary of what I understand:
1/ I'm ok to try replacing the use ${module} by ${pom.artifactId} everywhere
in the cruisecontrol plugin
2/ I need access to the SCM URL from the cruisecontrol plugin. I have 2
options:
a/ Try to compute myself taking into account the fact that the URL could
have a module defined using the ":" notation or not
b/ or rely on the SCM plugin for providing this information to me
I'd rather have the SCM plugin provide this information to consumers. For
the time being and in order to progress I'll do a/ by concatenating
${maven.scm.svn.root}/${maven.scm.svn.module}:
<!-- Compute the SCM URL to use. Note: IMO this should be done by the
SCM plugin who should provide a URL with this information for us
to use -->
<maven:pluginVar var="method" plugin="maven-scm-plugin"
property="maven.scm.method"/>
<j:if test="${method == 'cvs'}">
<maven:pluginVar var="root" plugin="maven-scm-plugin"
property="maven.scm.cvs.root"/>
<maven:pluginVar var="module" plugin="maven-scm-plugin"
property="maven.scm.cvs.module"/>
</j:if>
<j:if test="${method == 'svn'}">
<maven:pluginVar var="root" plugin="maven-scm-plugin"
property="maven.scm.svn.root"/>
<maven:pluginVar var="module" plugin="maven-scm-plugin"
property="maven.scm.svn.module"/>
</j:if>
<j:set var="url" value="${root}/${module}"/>
Do you agree to modify the SCM plugin to provide this information to
consumers?
3/ When are you going to move back the SCM plugin to the SVN trunk? The
problem is that I need to call scm:checkout from the cruisecontrol plugin
and I can't because the cruisecontrol plugin is on SVN trunk whereas the SCM
plugin that supports svn:checkout for SVN is on a branch. I could create a
branch for the cruisecontrol plugin but I'd rather do it the other way
around by bringing back the SCM plugin to the trunk. What's left to do?
4/ The SCM 1.5 beta plugin needs to be fixed so that the scm:validate goal
supports URLs without a module defined. It currently doesn't.
5/ WRT:
> That's not enough - because say you specify the URL as:
> http://svn.apache.org/repos/asf/maven/maven-
> 1/core/trunk:src/test/touchstone-build
>
> what happens when you are on the MAVEN-1_0-BRANCH? How do you translate
> this to
> http://svn.apache.org/repos/asf/maven/maven-1/core/branches/MAVEN-1_0-
> BRANCH:src/test/touchstone-build
>
> And it is different again under svn:externals.
>
> Really, you need to be able to make some substititutions. This will all
> be worked through in time, but beyond the 1.5 release.
I think that we need to do;
http://svn.apache.org/repos/asf:maven/maven-1/core/trunk:
src/test/touchstone-build (i.e.: [root] + [trunk location] + [module]).
And then have a <branch> element that says:
<branch>
<id>MAVEN-1_0-BRANCH</id>
<tag>maven/maven-1/core/branches/MAVEN-1_0-BRANCH</tag>
</branch>
Then we a branch is asked for the full URL is computed by:
[root] + {branch[id].tag} + [module]
I agree that this should be for after the 1.5 version.
What do you think?
Thanks
-Vincent
> -----Original Message-----
> From: Brett Porter [mailto:[EMAIL PROTECTED]
> Sent: dimanche 20 f�vrier 2005 02:44
> To: Maven Developers List
> Subject: Re: [SCM] Question on maven.scm.svn.module property
>
> Vincent Massol wrote:
>
> >>No, the plugin is backwards compat as is. Cruisecontrol can be updated
> >>to use the URL itself.
> >>
> >>
> >
> >How? CruiseControl needs the module name. How can I get it from the SCM
> >plugin or from the URL?
> >
> >
> not according to this:
> http://cruisecontrol.sourceforge.net/main/configxml.html#svn.
>
> Repository location is a full URL, and I'm sure if you put the whole URL
> in there instead of the root it would work as expected.
>
> The SCM plugin still supports the notation of ':' replacing one of the
> '/' to signify a "module" - however this is really arbitrary in
> Subversion, and is only used so the plugins can differentiate the root
> of the project from the subdirectories. To subversion, it's all the
> same. The "Root" of the repository is actually /repos/asf - not the
> value of maven.scm.svn.root, because that really isn't that useful given
> the current property set - the URL is all that is needed.
>
> >
> >
> >>I'm still thinking about this WRT subversion. At the moment, you can use
> >>a colon to specify your "module". However, this really isn't a natural
> >>thing for SVN, and the root is actually http:/.../repos/asf.
> >>
> >>
> >
> >Actually you can't... I've tried running "maven scm:checkout" and I get:
> >
> >Command output:
> >svn: URL 'https://[...]/trunk/code/webapp:webapp' doesn't exist
> >
> >
> So you're saying that .../trunk/code/webapp/webapp does exist, but this
> fails? Ok, then the SCM plugin needs to have a change to remain
> backwards compat.
>
> >So it seems that the scm plugin is not completely backward compatible.
> What
> >do I do:
> >
> >- I need the module specified as otherwise the cruisecontrol plugin will
> not
> >work. I'm happy to modify it but I don't know how to get the module
> name...
> >
> >
> This is what I'm trying to tackle. All we have is pom.artifactId which
> may or may not match up.
>
> >- When I run scm:checkout it says that it shouldn't end with a module
> >
> >
> Can you provide a more specific error message? I'm not sure what you are
> referring to here.
>
> >
> >
> >>What we probably expect the "module" to be is the last directory in the
> >>path of the root project, or last two if the last is "trunk", or the
> >>last 3 if one a branch or tag.
> >>
> >>
> >
> >But we can't assume this. Someone can use a name other than trunk, no?
> Same
> >for tags, branches.
> >
> >My feeling is that we need to split the URL into 2: one for the root and
> one
> >for the module... Sounds familiar?
> >
> >
> That's not enough - because say you specify the URL as:
> http://svn.apache.org/repos/asf/maven/maven-
> 1/core/trunk:src/test/touchstone-build
>
> what happens when you are on the MAVEN-1_0-BRANCH? How do you translate
> this to
> http://svn.apache.org/repos/asf/maven/maven-1/core/branches/MAVEN-1_0-
> BRANCH:src/test/touchstone-build
>
> And it is different again under svn:externals.
>
> Really, you need to be able to make some substititutions. This will all
> be worked through in time, but beyond the 1.5 release.
>
> >
> >
> >>I think we actually need to be able to have the URL specify this, but
> >>really I haven't wrapped my head around best practices here and the
> >>number of people using svn:externals is also confusing it. I'd like
> >>something that works with both svn:externals, and the default layout.
> >>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]