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 Carlton Brown <cb...@gmail.com> on 2011/05/19 16:19:30 UTC

Resolving Maven source jars to distinct folders

All,

My users are requesting that source jars be retrieved into their own
distinct folder.   We already use the config as part of the retrieve
pattern, so I thought it would be as adding a 'sources' configuration in my
ivy.xml, then declaring the appropriate conf mapping:

<configurations defaultconfmapping="sources->sources">

But this failed, because so many dependencies have no 'sources'
configuration.    Is there any way to define this opportunistically, so it
will work if the dependency has a 'sources' configuration, but not fail if
it doesn't?

Thanks,
Carlton

Re: Resolving Maven source jars to distinct folders

Posted by Carlton Brown <cb...@gmail.com>.
*facepalm*  That's exactly it, of course.  Should have remembered it myself.
  Thanks.

On Thu, May 19, 2011 at 10:47 AM, Archie Cobbs <ar...@dellroad.org> wrote:

> Just include a [type]s directory in your retrieval pattern... all source
> JARs should have type "source".
>
> -Archie
>
> On Thu, May 19, 2011 at 9:19 AM, Carlton Brown <cb...@gmail.com>
> wrote:
>
> > All,
> >
> > My users are requesting that source jars be retrieved into their own
> > distinct folder.   We already use the config as part of the retrieve
> > pattern, so I thought it would be as adding a 'sources' configuration in
> my
> > ivy.xml, then declaring the appropriate conf mapping:
> >
> > <configurations defaultconfmapping="sources->sources">
> >
> > But this failed, because so many dependencies have no 'sources'
> > configuration.    Is there any way to define this opportunistically, so
> it
> > will work if the dependency has a 'sources' configuration, but not fail
> if
> > it doesn't?
> >
> > Thanks,
> > Carlton
> >
>
>
>
> --
> Archie L. Cobbs
>

Re: Resolving Maven source jars to distinct folders

Posted by Archie Cobbs <ar...@dellroad.org>.
Just include a [type]s directory in your retrieval pattern... all source
JARs should have type "source".

-Archie

On Thu, May 19, 2011 at 9:19 AM, Carlton Brown <cb...@gmail.com> wrote:

> All,
>
> My users are requesting that source jars be retrieved into their own
> distinct folder.   We already use the config as part of the retrieve
> pattern, so I thought it would be as adding a 'sources' configuration in my
> ivy.xml, then declaring the appropriate conf mapping:
>
> <configurations defaultconfmapping="sources->sources">
>
> But this failed, because so many dependencies have no 'sources'
> configuration.    Is there any way to define this opportunistically, so it
> will work if the dependency has a 'sources' configuration, but not fail if
> it doesn't?
>
> Thanks,
> Carlton
>



-- 
Archie L. Cobbs