Stupid question but is the profile activated? What is the result of: 'mvn
help:active-profiles'
and 'mvn help:effective-pom'? In the output of 'mvn help:effective-pom' your
properties should be replaced with the version number.
Cheers, michael
Aaron Morand schrieb:
Good day all,
I am having an issue with a project failing, because a dependant project
isn't using properties defined in my settings.xml file.
I have my settings.xml file in ~/.m2/setttings.xml and also symlinked it
to /usr/local/maven/conf/settings.xml just so the default locations are
covered with the same information.
I am upgrading to Maven2 from Maven1 and am dealing with 50+ projects,
with various interdependencies on each other and 3rd party projects.
To keep the future of managing builds "easy", I have defined all the
dependency versions under profile properties in my settings.xml file.
So, for example, project1 depends on project2, project2 depends on
project3 and all have dependency version #'s defined in the settings.xml
file. What I'm finding is that project2 doesn't appear to use the
properties defined in the settings.xml file. Syntactically everything
appears correct and doesn't cause an error, but the project1 build fails
based on not finding project2's dependencies. It is looking for
${dependency.project2} which has a value of say, 2.1. So in
settings.xml I have :
<properties>
...
<dependency.project2>2.1</dependency.project2>
<dependency.project3>3.1</dependency.project3>
...
</properties>
in project1's pom.xml I have :
<dependency>
<groupId>my_project</groupId>
<artifactId>project2</artifactId>
<version>${dependency.project2}</version>
</dependency>
and in project2's pom.xml I have :
<dependency>
<groupId>my_project</groupId>
<artifactId>project3</artifactId>
<version>${dependency.project3}</version>
</dependency>
So it's complaining because it can't find project2's dependency of
project3. But it's looking for version ${dependency.project3} not
version 3.1 that ${dependency.project3} is defined as in the
settings.xml file.
Why doesn't this work?
Aaron
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]