maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schaible <Joerg.Schai...@Elsag-Solutions.com>
Subject RE: change POM at runtime
Date Wed, 10 Nov 2004 13:37:10 GMT
Stéphane Nicoll wrote on Wednesday, November 10, 2004 2:23 PM:

> Hello list,
> 
> I have integrated one of my maven project with cruise
> control. I would like to change some properties only when
> cruisecontrol runs, such as: 
> 
> current version -> NIGHTBUILD
> site directory (to generate the web site in
> /nightbuilds/myproject for instance)
> 
> I have a goal which does the following but it does not seem to work:

You have to use the setters of the POM directly to modify it, e.g. (fom one of my rules):

        <util:available file="${basedir}/xdocs/navigation.xml">
            <j:set var="globalSiteDirectory">/home/projects/nanocontainer/public_html/versions/${pom.currentVersion}</j:set>

            ${pom.setSiteDirectory(globalSiteDirectory)}
        </util:available>

But reconsider the Version name. If it does not end with snapshot, it is not downloaded again!
So I suggest you use something like "NIGHTLY-SNAPSHOT".

Regards,
Jörg

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


Mime
View raw message