Hi all, I've used the maven release plugin for a long time, but I have always used it in situations when the room POM was the parent POM at the same time.
Now, I am a project where that's not an option, but they still want to use the maven release plugin. Instead, their structure is as follows: pom.xml --- reactor pom (listing modules) -- bla-parent (pom.xml lists plugins, dependencies,etc.) -- bla-model (regular pom.xml) -- bla-ddl (regular pom.xml) You get the point. Here is the reactor's pom.xml: *************** <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>bla</groupId> <artifactId>bla-reactor</artifactId> <packaging>pom</packaging> <name>Bla Reactor</name> <version>${parent.version}</version> <parent> <groupId>bla</groupId> <artifactId>bla-parent</artifactId> <version>1.0-SNAPSHOT</version> <relativePath>bla-parent</relativePath> </parent> <modules> <module>bla-ddl</module> <module>bla-common</module> <module>bla-model</module> <module>bla-persistence</module> <module>bla-web</module> </modules> </project> *************** Here is how moduleOne's pom.xml looks like: *************** <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <groupId>bla</groupId> <artifactId>bla-model</artifactId> <packaging>jar</packaging> <name>Bla Model</name> <version>${parent.version}</version> <parent> <groupId>bla</groupId> <artifactId>bla-parent</artifactId> <version>1.0-SNAPSHOT</version> <relativePath>../bla-parent</relativePath> </parent> *************** When I run 'mvn release:prepare' from the root directory (the one that hosts the reactor POM), I end up with this: ********************* ... ... [INFO] Checking dependencies and plugins for snapshots ... There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : There are still some remaining snapshot dependencies. : Do you want to resolve them now? (yes/no) no: : yes Dependency type to resolve,: specify the selection number ( 0:All 1:Project Dependencies 2:Plugins 3:Reports 4:Extensions ): (0/1/2/3) 1: : 1 Dependency 'bla:bla-parent' is a snapshot (1.0-SNAPSHOT) : Which release version should it be set to? 1.0: : What version should the dependency be reset to for development? 1.0: : What is the release version for "Bla Reactor"? (bla:bla-reactor) 1.0: : What is SCM release tag or label for "Bla Reactor"? (bla:bla-reactor) bla-reactor-1.0: : What is the new development version for "Bla Reactor"? (bla:bla-reactor) 1.1-SNAPSHOT: : [INFO] Transforming 'Bla Database scripts'... [INFO] Transforming 'Bla Common'... [INFO] Transforming 'Bla Model'... [INFO] Transforming 'Bla Persistence'... [INFO] Updating bla-common to 1.0 [INFO] ------------------------------------------------------------------------ [ERROR] BUILD FAILURE [INFO] ------------------------------------------------------------------------ [INFO] The version could not be updated: ${parent.version} [INFO] ------------------------------------------------------------------------ [INFO] For more information, run Maven with the -e switch [INFO] ------------------------------------------------------------------------ [INFO] Total time: 1 minute 25 seconds [INFO] Finished at: Mon May 02 13:20:09 EDT 2011 [INFO] Final Memory: 15M/37M [INFO] ------------------------------------------------------------------------ ********************* How do I fix this that it works? Thanks! -Yaakov. --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
