>-----Original Message-----
>From: Benson Margulies [mailto:[email protected]]
>Apache CXF has several poms that follow this pattern:
>
>   ....
>   <properties>
>     <jetty.version>6.1.24</jetty.version>
>   </properties>
>   ...
>   <dependencies>
>     <dependency>
>       <groupId>g</groupId>
>       <artifactId>a</artifactId>
>       <version>${jetty.version}</version>
>     </dependency>
>   </dependencies>
>
>I was very surprised to learn, recently, that the release publication
>process leaves the property reference in the POM. Then, if some
>project of mine lists one of these projects as a dependency, and then
>sets jetty.version to something else, CXFs dependencies follow along.
>Oops. I somehow expected that the release process would resolve these
>props and replace them with fixed values.

Maven doesn't have the concept of a difference between the pom used to
build the artifact, and the pom used to deploy it.  Many people (myself
included) have run into this problem, and there doesn't seem to be good
solution.
For limited things like the version of your artifact (not dependencies,
as in your example above) you can use the maven-release-plugin to
rewrite your pom(s) every time some version change, but I don't think
that'll replace arbitrary property references.
IMO, maven should probably create a "resolved pom" as part of the build
process and deploy that along with the artifact, but I don't have time
to figure out how to make it do that.

eric



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to