You are viewing a plain text version of this content. The canonical link for it is here.
Posted to ivy-user@ant.apache.org by Keith Johnston <ke...@gmail.com> on 2007/01/02 03:12:13 UTC

Retrieving a single file from a module configuration

I cannot seem to find a way to retrieve a single file from a module.
I want to retrieve a single published file from a module without its
dependencies.  I've tried using various combinations of ivy:retrieve
and ivy:resolve with no luck.

What is the proper way to do this?

Keith

Re: Retrieving a single file from a module configuration

Posted by John Gill <ll...@gmail.com>.
Have you tried specifying the artifact you want in the dependencies within
the ivy.xml file?

Something like this:
<dependency org="mycompany" name="mypackage" rev="1.2.3" >
            <artifact name="theartifactiwant" type="jar" />
            <artifact name="theotherartifactiwant" type="jar" />
</dependency>


On 1/2/07, Keith Johnston <ke...@gmail.com> wrote:
>
> I cannot seem to find a way to retrieve a single file from a module.
> I want to retrieve a single published file from a module without its
> dependencies.  I've tried using various combinations of ivy:retrieve
> and ivy:resolve with no luck.
>
> What is the proper way to do this?
>
> Keith
>



-- 
Regards,
John Gill

Re: Retrieving a single file from a module configuration

Posted by Xavier Hanin <xa...@gmail.com>.
On 1/2/07, Keith Johnston <ke...@gmail.com> wrote:
>
> I cannot seem to find a way to retrieve a single file from a module.
> I want to retrieve a single published file from a module without its
> dependencies.  I've tried using various combinations of ivy:retrieve
> and ivy:resolve with no luck.
>
> What is the proper way to do this?


Using transitive="false" with resolve you will get only the module you want.
To get only one artifact, it depends on how the module is declared and on
the type of artifact. If the artifact you want is isolated in one
configuration, you can use conf="XXX". If the artifact you want is the only
one of one type, you can use the type filtering with type="jar" for
instance. If none of these solutions work, you won't be able to get what you
want except by declaring a dependency and naming the artifact you want as
John suggests.

Xavier

Keith
>