ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Xavier Hanin" <>
Subject Re: Problems with ivy:install
Date Wed, 29 Aug 2007 12:38:03 GMT
On 8/29/07, Andy Piper <> wrote:
> At 07:40 29/08/2007, Xavier Hanin wrote:
> >No, transitive="true" indicates that not only the module but also its
> >dependencies must be installed (i.e. copied from one repository to
> another).
> >If you're looking for a way to publish one module to a repository
> >(equivalent to maven 2 install goal), use the publish task. This won't
> copy
> >the dependencies of the module though, but the dependencies must already
> be
> >in a repository. In your case, you could publish your module the
> >ce-repository, and then install it and its dependencies from
> ce-repository
> >to shared, if it's really what you want.
> So I'm still not convinced that what is happening in logical.
> I have two repositories A and B. A only contains virtual modules. B
> contains the real artifacts I am interested in. I tell ivy to install
> modules from A and include transitive dependencies (which are all in
> B). I observe the following.

I think there's a problem of vocabulary. In Ivy terminology, you always
install from a repository *to* another one. Here you're talking about
installing from A and B. But to which repository?

1. Without ivy:retrieve, nothing from B gets installed.

If install means copied from one repo to another, this is possible to do
with the install task. But you need to specify a chain of A and B as source
and another repo as destination.

2. With ivy:retrieve everything gets installed from both A and B (but
> A is the repo I specified in the install task)

Retrieve is used to copy artifacts to a loca destination (which can later be
used as a repository, but it's unknown by Ivy at the moment of the retrieve

3. If I specify B as the repo in the install task then the build
> fails and nothing is installed.

Maybe it's because is lacking information about where to find information
about your modules, because B is not enough. The install task is very
similar to an inline resolve using only one repository, followed by a
publish of bunch of modules. If the resolve with only one repository does
not work, the install won't work.

For consistency I would expect either:
> a. For (2) only transitive modules in A to be installed
> or
> b. (3) to succeed and the source repo to be ignored when transitive
> is set to true.
> But, for the record, I don't want (a), I want (b). (2) is close
> enough, except that I would expect there to be an implicit retrieve.

I think you're confusing what install and retrieve are meant for. I don't
say they're obvious, but I think that by combining the resolve, retrieve and
install tasks you have a pretty flexible set of tools, with which you should
be able to do what you want. Maybe if you explained what you want to do, we
could help by explaining which tasks are better suited?


> >Note that usually you use install only when you want to setup an
> enterprise
> >repository that will be accessed by the team(s), and create its content
> from
> >another repository (maybe a public one, or a legacy one) that you don't
> want
> >the team to access. Otherwise you can use the heterogeneous repositories
> >directly from Ivy.
> Notice:  This email message, together with any attachments, may contain
> information  of  BEA Systems,  Inc.,  its subsidiaries  and  affiliated
> entities,  that may be confidential,  proprietary,  copyrighted  and/or
> legally privileged, and is intended solely for the use of the individual or
> entity named in this message. If you are not the intended recipient, and
> have received this message in error, please immediately return this by email
> and then delete it.

Xavier Hanin - Independent Java Consultant

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