You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Saloucious <sa...@gmail.com> on 2007/10/26 17:42:25 UTC

Properties files exclude from jar artifact

Hi,

Acutally, i'm working on a migration from Ant to Maven.
The old Ant script creates for each project a  jar and  copy properties
files in a deploy dir.
So these properties file are not embeded in jar.

Now i'm on Maven, 
If I excludes files from jar, they will not be in repository
I don't find the way to be able to not embed properties file from jar and
install them in repo.
-- 
View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Properties files exclude from jar artifact

Posted by Saloucious <sa...@gmail.com>.
Sure assembly will unpack properites in conf dir.

But in my assembly, i would like to define a dependency to this module
So finally, i will have my jar artifact with my properties files embded (for
eg in a "lib" dir)
and my properties files in "conf" dir (double)



Wayne Fay wrote:
> 
> Use dependencies plugin to unpack the properties files into your
> current module so they will be packaged by assembly into the conf dir
> you require.
> 
> Wayne
> 
> On 11/9/07, Saloucious <sa...@gmail.com> wrote:
>>
>> So if  i package properties file into my jars, how can I create finally
>> an
>> assembly which create a deploy/conf dir with all properties from jar.
>>
>> We put all properties into this dir because it is easiest to patch it.
>>
>>
>>
>>
>>
>> Wayne Fay wrote:
>> >
>> > No such "all" classifier exists. You must specify each dependency.
>> >
>> > Wayne
>> >
>> > On 11/6/07, Saloucious <sa...@gmail.com> wrote:
>> >>
>> >> Ok, but is it possible to get jar artifact and properties artifact in
>> one
>> >> dependency decalaration:
>> >>
>> >> For example, I deploy module1 with jar artifact and properties
>> artifact
>> >>
>> >> and in a module2, i declare a dependency  with module1
>> >> Is Maven able to retrieve 2 artifacts (for example with a
>> >> <classifier>ALL</classifier or something like that)
>> >>
>> >> <dependency>
>> >> <groupid>mygroup</groupid>
>> >> <artifactid>module1</artifactid>
>> >> </dependency>
>> >>
>> >> Otherwise i must declare 2 dependencies by module, one for binaries
>> files
>> >> and one for properties files...
>> >>
>> >>
>> >> Wayne Fay wrote:
>> >> >
>> >> > You could make another artifact (jar) that consists only of
>> properties
>> >> > files that are jar'ed together and deploy it into your repo.
>> >> >
>> >> > Wayne
>> >> >
>> >> > On 10/26/07, Saloucious <sa...@gmail.com> wrote:
>> >> >>
>> >> >> Hi,
>> >> >>
>> >> >> Acutally, i'm working on a migration from Ant to Maven.
>> >> >> The old Ant script creates for each project a  jar and  copy
>> >> properties
>> >> >> files in a deploy dir.
>> >> >> So these properties file are not embeded in jar.
>> >> >>
>> >> >> Now i'm on Maven,
>> >> >> If I excludes files from jar, they will not be in repository
>> >> >> I don't find the way to be able to not embed properties file from
>> jar
>> >> and
>> >> >> install them in repo.
>> >> >> --
>> >> >> View this message in context:
>> >> >>
>> >>
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
>> >> >> Sent from the Maven - Users mailing list archive at Nabble.com.
>> >> >>
>> >> >>
>> >> >>
>> ---------------------------------------------------------------------
>> >> >> 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
>> >> >
>> >> >
>> >> >
>> >>
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13616078
>> >> Sent from the Maven - Users mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> 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
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13669183
>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> 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
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13708126
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Properties files exclude from jar artifact

Posted by Wayne Fay <wa...@gmail.com>.
Use dependencies plugin to unpack the properties files into your
current module so they will be packaged by assembly into the conf dir
you require.

Wayne

On 11/9/07, Saloucious <sa...@gmail.com> wrote:
>
> So if  i package properties file into my jars, how can I create finally an
> assembly which create a deploy/conf dir with all properties from jar.
>
> We put all properties into this dir because it is easiest to patch it.
>
>
>
>
>
> Wayne Fay wrote:
> >
> > No such "all" classifier exists. You must specify each dependency.
> >
> > Wayne
> >
> > On 11/6/07, Saloucious <sa...@gmail.com> wrote:
> >>
> >> Ok, but is it possible to get jar artifact and properties artifact in one
> >> dependency decalaration:
> >>
> >> For example, I deploy module1 with jar artifact and properties artifact
> >>
> >> and in a module2, i declare a dependency  with module1
> >> Is Maven able to retrieve 2 artifacts (for example with a
> >> <classifier>ALL</classifier or something like that)
> >>
> >> <dependency>
> >> <groupid>mygroup</groupid>
> >> <artifactid>module1</artifactid>
> >> </dependency>
> >>
> >> Otherwise i must declare 2 dependencies by module, one for binaries files
> >> and one for properties files...
> >>
> >>
> >> Wayne Fay wrote:
> >> >
> >> > You could make another artifact (jar) that consists only of properties
> >> > files that are jar'ed together and deploy it into your repo.
> >> >
> >> > Wayne
> >> >
> >> > On 10/26/07, Saloucious <sa...@gmail.com> wrote:
> >> >>
> >> >> Hi,
> >> >>
> >> >> Acutally, i'm working on a migration from Ant to Maven.
> >> >> The old Ant script creates for each project a  jar and  copy
> >> properties
> >> >> files in a deploy dir.
> >> >> So these properties file are not embeded in jar.
> >> >>
> >> >> Now i'm on Maven,
> >> >> If I excludes files from jar, they will not be in repository
> >> >> I don't find the way to be able to not embed properties file from jar
> >> and
> >> >> install them in repo.
> >> >> --
> >> >> View this message in context:
> >> >>
> >> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
> >> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >> >>
> >> >>
> >> >> ---------------------------------------------------------------------
> >> >> 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
> >> >
> >> >
> >> >
> >>
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13616078
> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> 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
> >
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13669183
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> 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: Properties files exclude from jar artifact

Posted by Saloucious <sa...@gmail.com>.
So if  i package properties file into my jars, how can I create finally an
assembly which create a deploy/conf dir with all properties from jar.

We put all properties into this dir because it is easiest to patch it.





Wayne Fay wrote:
> 
> No such "all" classifier exists. You must specify each dependency.
> 
> Wayne
> 
> On 11/6/07, Saloucious <sa...@gmail.com> wrote:
>>
>> Ok, but is it possible to get jar artifact and properties artifact in one
>> dependency decalaration:
>>
>> For example, I deploy module1 with jar artifact and properties artifact
>>
>> and in a module2, i declare a dependency  with module1
>> Is Maven able to retrieve 2 artifacts (for example with a
>> <classifier>ALL</classifier or something like that)
>>
>> <dependency>
>> <groupid>mygroup</groupid>
>> <artifactid>module1</artifactid>
>> </dependency>
>>
>> Otherwise i must declare 2 dependencies by module, one for binaries files
>> and one for properties files...
>>
>>
>> Wayne Fay wrote:
>> >
>> > You could make another artifact (jar) that consists only of properties
>> > files that are jar'ed together and deploy it into your repo.
>> >
>> > Wayne
>> >
>> > On 10/26/07, Saloucious <sa...@gmail.com> wrote:
>> >>
>> >> Hi,
>> >>
>> >> Acutally, i'm working on a migration from Ant to Maven.
>> >> The old Ant script creates for each project a  jar and  copy
>> properties
>> >> files in a deploy dir.
>> >> So these properties file are not embeded in jar.
>> >>
>> >> Now i'm on Maven,
>> >> If I excludes files from jar, they will not be in repository
>> >> I don't find the way to be able to not embed properties file from jar
>> and
>> >> install them in repo.
>> >> --
>> >> View this message in context:
>> >>
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
>> >> Sent from the Maven - Users mailing list archive at Nabble.com.
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> 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
>> >
>> >
>> >
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13616078
>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> 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
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13669183
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Properties files exclude from jar artifact

Posted by Wayne Fay <wa...@gmail.com>.
No such "all" classifier exists. You must specify each dependency.

Wayne

On 11/6/07, Saloucious <sa...@gmail.com> wrote:
>
> Ok, but is it possible to get jar artifact and properties artifact in one
> dependency decalaration:
>
> For example, I deploy module1 with jar artifact and properties artifact
>
> and in a module2, i declare a dependency  with module1
> Is Maven able to retrieve 2 artifacts (for example with a
> <classifier>ALL</classifier or something like that)
>
> <dependency>
> <groupid>mygroup</groupid>
> <artifactid>module1</artifactid>
> </dependency>
>
> Otherwise i must declare 2 dependencies by module, one for binaries files
> and one for properties files...
>
>
> Wayne Fay wrote:
> >
> > You could make another artifact (jar) that consists only of properties
> > files that are jar'ed together and deploy it into your repo.
> >
> > Wayne
> >
> > On 10/26/07, Saloucious <sa...@gmail.com> wrote:
> >>
> >> Hi,
> >>
> >> Acutally, i'm working on a migration from Ant to Maven.
> >> The old Ant script creates for each project a  jar and  copy properties
> >> files in a deploy dir.
> >> So these properties file are not embeded in jar.
> >>
> >> Now i'm on Maven,
> >> If I excludes files from jar, they will not be in repository
> >> I don't find the way to be able to not embed properties file from jar and
> >> install them in repo.
> >> --
> >> View this message in context:
> >> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
> >> Sent from the Maven - Users mailing list archive at Nabble.com.
> >>
> >>
> >> ---------------------------------------------------------------------
> >> 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
> >
> >
> >
>
> --
> View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13616078
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> 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: Properties files exclude from jar artifact

Posted by Saloucious <sa...@gmail.com>.
Ok, but is it possible to get jar artifact and properties artifact in one
dependency decalaration:

For example, I deploy module1 with jar artifact and properties artifact

and in a module2, i declare a dependency  with module1
Is Maven able to retrieve 2 artifacts (for example with a
<classifier>ALL</classifier or something like that)

<dependency>
<groupid>mygroup</groupid>
<artifactid>module1</artifactid>
</dependency>

Otherwise i must declare 2 dependencies by module, one for binaries files
and one for properties files...


Wayne Fay wrote:
> 
> You could make another artifact (jar) that consists only of properties
> files that are jar'ed together and deploy it into your repo.
> 
> Wayne
> 
> On 10/26/07, Saloucious <sa...@gmail.com> wrote:
>>
>> Hi,
>>
>> Acutally, i'm working on a migration from Ant to Maven.
>> The old Ant script creates for each project a  jar and  copy properties
>> files in a deploy dir.
>> So these properties file are not embeded in jar.
>>
>> Now i'm on Maven,
>> If I excludes files from jar, they will not be in repository
>> I don't find the way to be able to not embed properties file from jar and
>> install them in repo.
>> --
>> View this message in context:
>> http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
>> Sent from the Maven - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> 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
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13616078
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Properties files exclude from jar artifact

Posted by Wayne Fay <wa...@gmail.com>.
You could make another artifact (jar) that consists only of properties
files that are jar'ed together and deploy it into your repo.

Wayne

On 10/26/07, Saloucious <sa...@gmail.com> wrote:
>
> Hi,
>
> Acutally, i'm working on a migration from Ant to Maven.
> The old Ant script creates for each project a  jar and  copy properties
> files in a deploy dir.
> So these properties file are not embeded in jar.
>
> Now i'm on Maven,
> If I excludes files from jar, they will not be in repository
> I don't find the way to be able to not embed properties file from jar and
> install them in repo.
> --
> View this message in context: http://www.nabble.com/Properties-files-exclude-from-jar-artifact-tf4698085s177.html#a13429857
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> 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