Hi all,

I am using values of properties defined in my settings.xml file into my
pom.xml. For instance, I have parameterized the version for m project
dependencies in the settings.xml with a property called
"project.version". I am using this property in my pom.xml as follows:

                      <dependency>

                             <groupId>Group1</groupId>

                             <artifactId>Artifact1</artifactId>

                             <version>${project.version}</version>

                      </dependency>

 

This works fine when I build my current project where in the appropriate
version of the dependencies gets downloaded. However, when I
install/deploy my project into the repository, the installed pom file
for the project still has the version parameterized in it and does not
have the original property value replaced in it. Hence when other
projects use my project as a dependency, it is not able to resolve the
version of the dependencies. 

 

When my project is used as a dependency in other projects, maven fails
the build saying it is not able to download
Artifact1-${project.version}. 

 

Can anybody please let me know how do I resolve this?

 

Regards,

Ravi.

"Tough times never last, but tough men do..."

 

Reply via email to