I think Steve's asking for the same setting in Ivy. If that's the question, the answer is no, we don't have support for profiles so far in Ivy.
IMO a good way to implement this kind of thing would be to implement conditionnal configurations and/or conditionnal dependencies. Something like: <dependency name="..." rev="..." if="myvariable" /> I remember this has already been discussed, but I don't remember if someone opened an issue for that. With conditional dependencies/confs, we could map each profile to a simple variable (for instance profile.<profile name>) then activating the profile would be as simple as: ant -Dprofile.<profile name> resolve Implementing conditional dependencies/confs shouldn't be too hard, we just have to ignore them when the condition is not matched. Parsing poms to support this shouldn't be too hard either. If we want to go further, we could deal with jdk enabled profiles (which is one of the most common use case behind m2 profiles AFAIK) and set the corresponding variables automatically depending on the jdk, to more closely mimic m2. Xavier On Nov 19, 2007 3:14 PM, Gilles Scokart <[EMAIL PROTECTED]> wrote: > Yes : > > mvn -P profile1[,profilen]* > > But you can also set profile automatically from your maven settings files. > > Gilles > > > -----Original Message----- > > From: Steve Loughran [mailto:[EMAIL PROTECTED] > > Sent: lundi 19 novembre 2007 15:09 > > To: [email protected] > > Subject: retrieving 'profiled' m2 artifacts > > > > > > There's now a POM file for TestNG 5.7 up on the repository > > http://repo1.maven.org/maven2/org/testng/testng/5.7/testng-5.7.pom > > > > however, it is 'profiled'; different artifacts and dependencies for > > java1.5 and java1.4. > > > > I don't think trying to chase all of M2's logic about profile selection > > and the like is worthwhile, but Ivy does need some way of requesting a > > specific profile. I didnt see anything in the online documentation -is > > there a profile attribute that I've missed? > > > > -steve > > > > -- > > Steve Loughran http://www.1060.org/blogxter/publish/5 > > Author: Ant in Action http://antbook.org/ > > -- Xavier Hanin - Independent Java Consultant http://xhab.blogspot.com/ http://ant.apache.org/ivy/ http://www.xoocode.org/
