You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Nicolas FRANK <nf...@financeactive.com> on 2003/11/25 15:28:51 UTC

RE : specify a different properties file rather than build.properties file

I have a similar problem :

I want people to be able to customize some properties (ex: where is there
jboss folder so I can automaticaly deploy in it) without changing the maven
build.properties , and I want this property file to be placed in the project
folder so it can be put into cvs easily. (ex: a property into the
build.properties : jboss.folder=${user.jboss.folder} or directly the
jboss.folder property into the personal property file)

I have would like a structure like this :

myProject
  |
  --userconf
     |
     -- nfrank
       |
       -- user-build.properties
     -- prod1
     -- integration
     -- ...
  --src
  |
  maven.xml
  build.properties
...

I would like properties defined into the user user-build.properties to be
used for that purpose. But how to "include" it ?

At worth I would like to do it by hand with :
<properties file="$username/user-build.properties"/>,
but the better would be to be able to use those properties inside the
build.properties


I think there is no way to do it right now with maven... But maybe someone
found a workaround ?
 
Thank's
 Nicolas.


-----Message d'origine-----
De : Jim Crossley [mailto:jim@crossleys.org] 
Envoyé : mardi 25 novembre 2003 14:24
À : Maven Users List
Objet : Re: specify a different properties file rather than build.properties
file


Jason van Zyl <jv...@maven.org> writes:

> On Mon, 2003-11-24 at 19:31, Nelson, Scott (MAN-Corporate) wrote:
>> Hey guys,
>> 
>> After reading the documentation I know that the order of properties 
>> file processing is project.properties, build.properties, 
>> build.properties(user.home).  I also read that the -Dname=value 
>> properties set at the CLI take precedence over all of these but...
>> 
>> Say I wanted maven to use a file called build-qa.properties instead 
>> of build.properties, is there a way to do this in maven?
>
> Why would you need to that?

Because the properties for each environment you might build/deploy the
project in are different, e.g. QA's mail host is not the same as Production's
mail host.  We keep each environment's properties file under version control
to simplify deployment -- we don't want to introduce the potential for human
error by editing a properties file. We've used various ways of determining
which properties file to use at build-time -- it would be nice if Maven
provided a more standard way of doing it.

Thanks,
Jim

---------------------------------------------------------------------
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