Home » Category » Java Programming

Java Programming: ZQ: Overide project and dependency versions using command line attribute

116| Mon, 05 May 2008 21:34:00 GMT| rahamim_zvi_zvi| Comments (0)
Thank you both,
Suppose I use the Maven using a java code (MavenEmbedder~).
How can I leverage this in order to change the parameter values (my-app and my-app2 versions)?
Thanks

Message
From: Arnaud Bailly [mailto:abailly (AT) oqube (DOT) com]
Sent: Monday, November 06, 2006 11:39 AM
To: Maven Users List
Subject: Re: ZQ: project and dependency versions using command line attribute

franz see <franz.see (AT) gmail (DOT) comwrites:

Good day to you, Rahamim,

I don't think that is possible. IIRC, Dependencies are resolved before
any filtering can take place :-)

+1

>
>Hi,
>I have a project my-app that depends on my-app-2.
>The version that is specified in that file is version 1.0.0 for
>my-app and 2.0.0 for my-app2.
>I want, without modifying the pom.xml file, to build deploy my-app
>but with version 1.0.1 that uses my-app2's version 2.0.1 Can you tell
>me how to do it using command line property parameters?
>Thanks!
>


But may be this objective can be reached using profiles and dependencyManagement. Set one profile with 1.0.0 dependency and another with 2.0.0 and choose which profile to run on command line with -P <profilename>. Note that these profiles must be defined in the PM, not settings.xml.

HTH
regards

Keywords & Tags: zq, overide, project, dependency, versions, command, line, attribute, java, programming

URL: http://java.itags.org/java-programming/332353/
 
«« Prev - Next »» 0 helpful answers below.

Java Programming Hot Answers

Java Programming New questions

Java Programming Related Categories