You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by David Ojeda <do...@integra.la> on 2008/11/26 21:38:50 UTC

Remote resources and version

Hello,

I am looking for an approach or plugin for the following:
I have a multi module project, where it is very likely that different modules 
need the same resources (specifically, xsd files and some configuration 
files). I do not want to copy each file on every module, so I though that I 
should have an independent module that includes this files.

I have researched about this and found the remote-resources plugin. It seems 
this is possible, and one must declare the resources like this:
<configuration>
 <resourceBundles>
   <resourceBundle>org.apache:apache-jar-resource-bundle:1.0</resourceBundle>
 </resourceBundles>
</configuration>

I would like to know if anyone has experience with this plugin. Also, I am 
worried that I would have to declare the resource version, which could be a 
pain. Is it possible to declare the snapshot version?

Does anyone manage this with another plugin or different approach?

Thanks for your help.



-- 
David Ojeda


Re: Remote resources and version

Posted by David Ojeda <do...@integra.la>.
Thank you Stephen, that plugin was the one I was looking for.

On Wednesday 26 November 2008 18:36:51 Stephen Connolly wrote:
> trye the maven-dependency-plugin specifically either the
> unpack-dependencies or unpack
>
> 2008/11/26 David Ojeda <do...@integra.la>
>
> > Sorry to bother, but It seems that the remote resources plugin will not
> > fit my
> > needs. What I need is to extract some files from a dependency into the
> > resources of a maven module. Or extract them into the target/classes
> > directory.
> >
> > A more specific example, what would you do if you want N projects to use
> > the
> > same log4j.properties and the same "other files" (xml schemas). This
> > files are
> > used in the generate-sources phase.
> >
> > Thank you,
> > David
> >
> > On Wednesday 26 November 2008 16:08:50 David Ojeda wrote:
> > > Hello,
> > >
> > > I am looking for an approach or plugin for the following:
> > > I have a multi module project, where it is very likely that different
> > > modules need the same resources (specifically, xsd files and some
> > > configuration files). I do not want to copy each file on every module,
> > > so
> >
> > I
> >
> > > though that I should have an independent module that includes this
> > > files.
> > >
> > > I have researched about this and found the remote-resources plugin. It
> > > seems this is possible, and one must declare the resources like this:
> > > <configuration>
> > >  <resourceBundles>
> >
> > <resourceBundle>org.apache:apache-jar-resource-bundle:1.0</resourceBundle
> >>
> >
> > > </resourceBundles>
> > > </configuration>
> > >
> > > I would like to know if anyone has experience with this plugin. Also, I
> >
> > am
> >
> > > worried that I would have to declare the resource version, which could
> > > be
> >
> > a
> >
> > > pain. Is it possible to declare the snapshot version?
> > >
> > > Does anyone manage this with another plugin or different approach?
> > >
> > > Thanks for your help.
> >
> > --
> > David Ojeda

-- 
David Ojeda


Re: Remote resources and version

Posted by Stephen Connolly <st...@gmail.com>.
trye the maven-dependency-plugin specifically either the unpack-dependencies
or unpack

2008/11/26 David Ojeda <do...@integra.la>

> Sorry to bother, but It seems that the remote resources plugin will not fit
> my
> needs. What I need is to extract some files from a dependency into the
> resources of a maven module. Or extract them into the target/classes
> directory.
>
> A more specific example, what would you do if you want N projects to use
> the
> same log4j.properties and the same "other files" (xml schemas). This files
> are
> used in the generate-sources phase.
>
> Thank you,
> David
>
> On Wednesday 26 November 2008 16:08:50 David Ojeda wrote:
> > Hello,
> >
> > I am looking for an approach or plugin for the following:
> > I have a multi module project, where it is very likely that different
> > modules need the same resources (specifically, xsd files and some
> > configuration files). I do not want to copy each file on every module, so
> I
> > though that I should have an independent module that includes this files.
> >
> > I have researched about this and found the remote-resources plugin. It
> > seems this is possible, and one must declare the resources like this:
> > <configuration>
> >  <resourceBundles>
> >
> >
> <resourceBundle>org.apache:apache-jar-resource-bundle:1.0</resourceBundle>
> > </resourceBundles>
> > </configuration>
> >
> > I would like to know if anyone has experience with this plugin. Also, I
> am
> > worried that I would have to declare the resource version, which could be
> a
> > pain. Is it possible to declare the snapshot version?
> >
> > Does anyone manage this with another plugin or different approach?
> >
> > Thanks for your help.
>
> --
> David Ojeda
>
>

Re: Remote resources and version

Posted by David Ojeda <do...@integra.la>.
Sorry to bother, but It seems that the remote resources plugin will not fit my 
needs. What I need is to extract some files from a dependency into the 
resources of a maven module. Or extract them into the target/classes 
directory.

A more specific example, what would you do if you want N projects to use the 
same log4j.properties and the same "other files" (xml schemas). This files are 
used in the generate-sources phase.

Thank you,
David

On Wednesday 26 November 2008 16:08:50 David Ojeda wrote:
> Hello,
>
> I am looking for an approach or plugin for the following:
> I have a multi module project, where it is very likely that different
> modules need the same resources (specifically, xsd files and some
> configuration files). I do not want to copy each file on every module, so I
> though that I should have an independent module that includes this files.
>
> I have researched about this and found the remote-resources plugin. It
> seems this is possible, and one must declare the resources like this:
> <configuration>
>  <resourceBundles>
>   
> <resourceBundle>org.apache:apache-jar-resource-bundle:1.0</resourceBundle>
> </resourceBundles>
> </configuration>
>
> I would like to know if anyone has experience with this plugin. Also, I am
> worried that I would have to declare the resource version, which could be a
> pain. Is it possible to declare the snapshot version?
>
> Does anyone manage this with another plugin or different approach?
>
> Thanks for your help.

-- 
David Ojeda