You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Adam Crain <ac...@greenenergycorp.com> on 2011/01/19 18:33:41 UTC
downloading resources
Hi,
There are several external shared libraries available via http in tar.gz
files that I want to include in a jar.
I do not want to check these files into my scm.
How do I get maven to
1) Check if they are already present, and if not
2) Download the tarball
3) Uncompress it to my projects src/main/resources folder
(I'm distributing shared libraries this way because it's an OSGi bundle that
uses JNI libraries)
Any advice on combinations of plugins to use?
-Adam
Re: downloading resources
Posted by Stephen Connolly <st...@gmail.com>.
any phase before the phase in which you create the bundle...
probably generate-resources
On 20 January 2011 07:56, Adam Crain <ac...@greenenergycorp.com> wrote:
> What phase should I be doing this in to insure that they make it into the
> bundle?
>
> On Wed, Jan 19, 2011 at 9:52 PM, Wayne Fay <wa...@gmail.com> wrote:
>
>> >> 3) Uncompress it to my projects src/main/resources folder
>>
>> Oh and btw you should probably not be uncompressing to
>> src/main/resources but rather to /target.
>>
>> Wayne
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>
>>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: downloading resources
Posted by Adam Crain <ac...@greenenergycorp.com>.
What phase should I be doing this in to insure that they make it into the
bundle?
On Wed, Jan 19, 2011 at 9:52 PM, Wayne Fay <wa...@gmail.com> wrote:
> >> 3) Uncompress it to my projects src/main/resources folder
>
> Oh and btw you should probably not be uncompressing to
> src/main/resources but rather to /target.
>
> Wayne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>
Re: downloading resources
Posted by Wayne Fay <wa...@gmail.com>.
>> 3) Uncompress it to my projects src/main/resources folder
Oh and btw you should probably not be uncompressing to
src/main/resources but rather to /target.
Wayne
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org
Re: downloading resources
Posted by Wayne Fay <wa...@gmail.com>.
> 1) Check if they are already present, and if not
> 2) Download the tarball
> 3) Uncompress it to my projects src/main/resources folder
Some plugins you should take a look at:
m-dependency-p (probably can do it all)
m-assembly-p
m-remote-resources-p (probably not an option)
m-antrun-p (if you really can't find a good way to do this any other way)
make-maven-plugin (part of the codehaus cbuild plugin) [1]
[1] http://mojo.codehaus.org/cbuild-parent/cbuild-plugin-parent/make-maven-plugin/unpack-mojo.html
Wayne
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org