ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Tharp <joshua-th...@alumni.calpoly.edu>
Subject Re: Beginner question - Ivy depencency set --> ANT fileset/classpath?
Date Mon, 01 Jun 2009 17:54:03 GMT
Alternatively, you can have your configurations extend one another and then
just use a single directory. For example, you could have the configurations:
<conf name="common" />
<conf name="mod1" extends="common" />
<conf name="mod2" extends="common" />

Then in your dependencies, simply say which configuration they belong to
(common, mod1, mod2, etc.) and on your build you can still use:
<fileset id="mod1.classpath" dir="${lib.d}/mod1" includes="*.jar" />

Josh

On Mon, Jun 1, 2009 at 10:46 AM, Jim Garrison <Jim.Garrison@troux.com>wrote:

>
>
> > -----Original Message-----
> > From: joshua.tharp@gmail.com [mailto:joshua.tharp@gmail.com]
> > On Behalf Of Joshua Tharp
> > Sent: Monday, June 01, 2009 12:20 PM
> > To: ivy-user@ant.apache.org
> > Subject: Re: Beginner question - Ivy depencency set --> ANT
> > fileset/classpath?
> >
> > The way I do it (and I'm not claiming to be either an expert
> > or using the most elegant means) is I create different
> > configurations for the different classpaths I need in a build
> > (compile, test, deploy) and have a ivy pattern that includes
> > the configuration ${lib.d}/[conf]/[artifact].[ext]. Then in
> > my ant scripts I just use separate filesets like:
> > <fileset id="test.classpath" dir="${lib.d}/test" />
> >
> > It works pretty well as I don' t have to adjust my classpaths
> > when I add or remove dependencies, and I can treat more of my
> > build generically.
>
> Hmmm.... I looked at <cachepath> and <cachefileset> and these don't
> seem to do what I want.  I have, conceptually, a set of global
> dependencies across my entire project, and then some additional sets
> of dependencies within various modules I'm building.
>
> Using your approach, it sounds like I would need to build a resolved
> lib structure like
>
> lib/common - dependencies used by all modules
> lib/mod1 - dependencies specific to module 1
> lib/mod2 - dependencies specific to module 2
> etc
>
> and then define
>
> <fileset id="common" dir="lib/common">
>   <include name="*"/>
> </fileset>
>
> Sounds like we need an enhancement giving access to the set of dependencies
> inside a single <ivy-module> as a list or path, instead of the entire
> <resolve/> set.

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message