On Wed, Mar 12, 2008 at 9:00 PM, Matthew Campbell <[EMAIL PROTECTED]> wrote: > Hey folks: > > I've just started splicing Ivy into our current build and I'm loving it > so far. Thanks so much for the great tool. I've been leaning on some > existing Maven2 repositories to provide dependencies at the moment, and was > wondering if there was a way to grab a multi-module maven project without > explicitly declaring all the modules as dependencies in ivy.xml. For > instance, the Apache UIMA project has a root project called 'uimaj' that > doesn't contain an artifact in the repository but only the POM referencing a > bunch of modules. You can view the uimaj POM at: > > > http://people.apache.org/repo/m2-incubating-repository/org/apache/uima/uimaj/2.2.1-incubating/uimaj-2.2.1-incubating.pom > > My dependency in ivy.xml looks like this: > > <dependency conf="compile->default" org="org.apache.uima" name="uimaj" rev=" > 2.2.1-incubating" /> > > And my ivy-settings has a resolver that looks like the following: > > <url name="apache-incubator-maven2" m2compatible="true"> > <artifact pattern=" > > http://people.apache.org/repo/m2-incubating-repository/[organization]/[module]/[revision]/[module]-[revision].pom" > /> > </url> > > I believe it's getting the dependencies correctly, but is not getting any of > the modules listed in the uimaj POM. I'm forced to define each one as a > separate dependency in ivy.xml, and this scares me a bit since I don't know > if modules will change (added, removed, renamed, etc). Ideally, I would > only have uimaj as my dependency and the rest would fall into place. Is > there an accepted way to handle this kind of thing? Thanks so much for your > time, There is not yet, and I don't think Maven itself behave like you want (but I may be wrong). However, we could add a 'modules' configuration and a dependency for each module in this configuration, so that doing what you want would be as easy as: <dependency conf="compile->default,modules" org="org.apache.uima" name="uimaj" rev=" 2.2.1-incubating" />
If you like this, open an improvement issue in JIRA (except if Maven actually pulls modules as dependencies, in which case this would be a compatibility bug). Xavier > > > -Matt Campbell > -- Xavier Hanin - Independent Java Consultant http://xhab.blogspot.com/ http://ant.apache.org/ivy/ http://www.xoocode.org/
