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 Lutz Behnke <lu...@informatik.haw-hamburg.de> on 2010/09/08 16:26:58 UTC

how to suppress artifacts with extra classifiers

Hi there,

I need some help to _not_ get stuff from a maven2 Repository. Any hints 
would be greatly appreciated.

I have read any (I hope) entry on classifiers in the mailing list 
archive but nothing seems to apply to my problem.

My ivy config you will find below.

I am using an Artifactory server as a proxy-repo to a number of Maven2 
compatible repos, searching the POMs for dependency information. These 
POMs contain dependencies for artefacts with classifiers (namely javadoc 
and sources).

Example:
asm-3.0.jar -> asm-3.0-javadoc.jar

These artefacts are not contained in the remote repositories and I don't 
need them neither.

So here is my qustion: How do I tell ivy to ignore those dependencies.

Everything else was resolved like a beauty, retreived and installed. It 
would be sufficient for me to have ivy give a warning and simply ignore 
the fact that it could not find the

Because this is a somewhat large project (50+ artifacts including 
transient and only beginning), I would rather not add dummy artifacts to 
my enterprise repo in order to shut ivy up in a brute force way.

<ivysettings>
   <properties file="${ivy.settings.dir}/ivysettings-file.properties" />
   <property name="org.repo.url" 
value="http://timadorus-hudson.informatik.haw-hamburg.de:8081/artifactory" 
/>

   <settings defaultResolver="ivy-and-maven" />
   <caches defaultCacheDir="${ivy.cache.dir}" />
   <resolvers>
     <chain name="ivy-and-maven" returnFirst="true">

       <ibiblio name="timadorus-repo-maven"
                root="${org.repo.url}/remote-repos"
                m2compatible="true" />

       <url name="timadorus-repo" m2compatible="true">
         <ivy 
pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/ivy.xml" />
         <artifact 
pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" 
/>
       </url>
     </chain>
   </resolvers>
</ivysettings>


Thanks for any pointers

mfg lutz

-- 
Lutz Behnke
Hochschule für Angewandte Wissenschaften Hamburg,
Labor für Allgemeine Informatik,

phone: +49 40 42875-8156    mailto:lutz.behnke@informatik.haw-hamburg.de
fax  : +49 40 2803770       http://users.informatik.haw-hamburg.de/~sage
Berliner Tor 7, 20099 Hamburg, Germany


Re: how to suppress artifacts with extra classifiers

Posted by Lutz Behnke <lu...@informatik.haw-hamburg.de>.
Hi Steve,

thanks for the quick answer. I had not used configurations at all up to 
now.

Will do the research and get back. ;-)

mfg lutz

Am 08.09.2010 16:33, schrieb Steve Miller:
> Which configurations are you asking for in your ivy.xml file?
>
> Here's what I have used, and it only asks for the compile and runtime
> jars, which normally excludes sources and javadocs. Does this help or
> am I missing something?
>
> Steve
>
> <dependency org="asm" name="asm" rev="3.0"
> conf="compile->compile,master;runtime->runtime"/>
>
> On Wed, Sep 8, 2010 at 10:26 AM, Lutz Behnke
> <lu...@informatik.haw-hamburg.de>  wrote:
>> Hi there,
>>
>> I need some help to _not_ get stuff from a maven2 Repository. Any hints
>> would be greatly appreciated.
>>
>> I have read any (I hope) entry on classifiers in the mailing list archive
>> but nothing seems to apply to my problem.
>>
>> My ivy config you will find below.
>>
>> I am using an Artifactory server as a proxy-repo to a number of Maven2
>> compatible repos, searching the POMs for dependency information. These POMs
>> contain dependencies for artefacts with classifiers (namely javadoc and
>> sources).
>>
>> Example:
>> asm-3.0.jar ->  asm-3.0-javadoc.jar
>>
>> These artefacts are not contained in the remote repositories and I don't
>> need them neither.
>>
>> So here is my qustion: How do I tell ivy to ignore those dependencies.
>>
>> Everything else was resolved like a beauty, retreived and installed. It
>> would be sufficient for me to have ivy give a warning and simply ignore the
>> fact that it could not find the
>>
>> Because this is a somewhat large project (50+ artifacts including transient
>> and only beginning), I would rather not add dummy artifacts to my enterprise
>> repo in order to shut ivy up in a brute force way.
>>
>> <ivysettings>
>>   <properties file="${ivy.settings.dir}/ivysettings-file.properties" />
>>   <property name="org.repo.url"
>> value="http://timadorus-hudson.informatik.haw-hamburg.de:8081/artifactory"
>> />
>>
>>   <settings defaultResolver="ivy-and-maven" />
>>   <caches defaultCacheDir="${ivy.cache.dir}" />
>>   <resolvers>
>>     <chain name="ivy-and-maven" returnFirst="true">
>>
>>       <ibiblio name="timadorus-repo-maven"
>>                root="${org.repo.url}/remote-repos"
>>                m2compatible="true" />
>>
>>       <url name="timadorus-repo" m2compatible="true">
>>         <ivy
>> pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/ivy.xml" />
>>         <artifact
>> pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"
>> />
>>       </url>
>>     </chain>
>>   </resolvers>
>> </ivysettings>
>>
>>
>> Thanks for any pointers
>>
>> mfg lutz
>>
>> --
>> Lutz Behnke
>> Hochschule für Angewandte Wissenschaften Hamburg,
>> Labor für Allgemeine Informatik,
>>
>> phone: +49 40 42875-8156    mailto:lutz.behnke@informatik.haw-hamburg.de
>> fax  : +49 40 2803770       http://users.informatik.haw-hamburg.de/~sage
>> Berliner Tor 7, 20099 Hamburg, Germany
>>
>>

-- 
Lutz Behnke
Hochschule für Angewandte Wissenschaften Hamburg,
Labor für Allgemeine Informatik,

phone: +49 40 42875-8156    mailto:lutz.behnke@informatik.haw-hamburg.de
fax  : +49 40 2803770       http://users.informatik.haw-hamburg.de/~sage
Berliner Tor 7, 20099 Hamburg, Germany


Re: how to suppress artifacts with extra classifiers

Posted by Steve Miller <th...@gmail.com>.
Which configurations are you asking for in your ivy.xml file?

Here's what I have used, and it only asks for the compile and runtime
jars, which normally excludes sources and javadocs. Does this help or
am I missing something?

Steve

<dependency org="asm" name="asm" rev="3.0"
conf="compile->compile,master;runtime->runtime"/>

On Wed, Sep 8, 2010 at 10:26 AM, Lutz Behnke
<lu...@informatik.haw-hamburg.de> wrote:
> Hi there,
>
> I need some help to _not_ get stuff from a maven2 Repository. Any hints
> would be greatly appreciated.
>
> I have read any (I hope) entry on classifiers in the mailing list archive
> but nothing seems to apply to my problem.
>
> My ivy config you will find below.
>
> I am using an Artifactory server as a proxy-repo to a number of Maven2
> compatible repos, searching the POMs for dependency information. These POMs
> contain dependencies for artefacts with classifiers (namely javadoc and
> sources).
>
> Example:
> asm-3.0.jar -> asm-3.0-javadoc.jar
>
> These artefacts are not contained in the remote repositories and I don't
> need them neither.
>
> So here is my qustion: How do I tell ivy to ignore those dependencies.
>
> Everything else was resolved like a beauty, retreived and installed. It
> would be sufficient for me to have ivy give a warning and simply ignore the
> fact that it could not find the
>
> Because this is a somewhat large project (50+ artifacts including transient
> and only beginning), I would rather not add dummy artifacts to my enterprise
> repo in order to shut ivy up in a brute force way.
>
> <ivysettings>
>  <properties file="${ivy.settings.dir}/ivysettings-file.properties" />
>  <property name="org.repo.url"
> value="http://timadorus-hudson.informatik.haw-hamburg.de:8081/artifactory"
> />
>
>  <settings defaultResolver="ivy-and-maven" />
>  <caches defaultCacheDir="${ivy.cache.dir}" />
>  <resolvers>
>    <chain name="ivy-and-maven" returnFirst="true">
>
>      <ibiblio name="timadorus-repo-maven"
>               root="${org.repo.url}/remote-repos"
>               m2compatible="true" />
>
>      <url name="timadorus-repo" m2compatible="true">
>        <ivy
> pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/ivy.xml" />
>        <artifact
> pattern="${org.repo.url}/repo/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]"
> />
>      </url>
>    </chain>
>  </resolvers>
> </ivysettings>
>
>
> Thanks for any pointers
>
> mfg lutz
>
> --
> Lutz Behnke
> Hochschule für Angewandte Wissenschaften Hamburg,
> Labor für Allgemeine Informatik,
>
> phone: +49 40 42875-8156    mailto:lutz.behnke@informatik.haw-hamburg.de
> fax  : +49 40 2803770       http://users.informatik.haw-hamburg.de/~sage
> Berliner Tor 7, 20099 Hamburg, Germany
>
>