Thanks for the help. I had studied all these option very carefully
before. But they won't work for us. 

All our sources are in source control system. The requirement is that
anybody can reproduce the build without knowing the application by
retrieving the sources. project.property, build.property have static
relationship which can not be changed by command line. The -Dproperties
is designed to set a / few system property, it will work. In our case,
it is not practical.  Any more?

-David



On Wed, 2005-02-23 at 10:46, Russ Jubenville wrote:
> Maven does allow you to override properties defined in the properties
> files.  In fact, the properties files have a well defined processing
> order that's described here:
> http://maven.apache.org/reference/user-guide.html#Properties_Processing
> 
> So, if you have a standard set of properties for one environment,
> perhaps dev, you might define them in the project.properties file.  You
> could then override any or all of those properties with definitions in
> ${project.home}/build.properties, or ${user.home}/build.properties, or
> even at the command line using the -Dproperty=value syntax.
> 
> Hope this helps.
> 
> ..Russ Jubenville
> 
> -----Original Message-----
> From: David Cao [mailto:[EMAIL PROTECTED] 
> Sent: February 23, 2005 13:35
> To: Maven Users List
> Subject: Re: how to 'point' to another properties file
> 
> 
> Hi, this is a real need.  I need:
> 1 Change the property file name by command line;
> 2 Or, change the property value in Maven.xml (the current solution only
> enable change to properties to plugin, which is not good enough in my
> case).
> 
> I had been working on creating a process to use Maven in our production.
> But there are few properties are different from dev environment to
> stage/ft/production. 
> 
> I cannot find way to change properties after defined in the property
> files. This might be a blocker if cannot be solved. I had tried to setup
> different project.xml for different environment. But this is an
> expensive solution. Any suggestion?
> 
> -David
> 
> On Tue, 2005-02-22 at 16:39, Hal Arnold wrote:
> > Sorry if this has been asked and answered, but I searched to no avail:
> > 
> >  
> > 
> > I'm autogenerating hibernate mappings and so I have my usual 
> > project.properties file with the following:
> > 
> >  
> > 
> > maven.xdoclet.hibernatedoclet.fileset.0=true
> > 
> > maven.xdoclet.hibernatedoclet.fileset.0.dir=${maven.src.dir}/java
> > 
> > maven.xdoclet.hibernatedoclet.fileset.0.include=**/*.java
> > 
> > maven.xdoclet.hibernatedoclet.hibernate.0.Version=2.0
> > 
> >  
> > 
> > I noted somewhere that you should be able to do something like this in
> 
> > the project.properties:
> > 
> > maven.hibernate.properties=conf/hibernate.properties
> > 
> >  
> > 
> > This would allow you to remove the maven.xdoclet.hibernatedoclet.xx 
> > lines
> > 
> > and move them into the new hibernate.properties
> > 
> > located in conf. this doesn't seem to work
> > 
> >  
> > 
> > I've also tried the usual (in the project.xml):
> > 
> >  
> > 
> > <resource>
> > 
> >        <directory>conf</directory>
> > 
> >        <includes>                    
> > 
> >             <include>hibernate.properties</include>
> > 
> >         </includes>
> > 
> >  </resource>
> > 
> >  
> > 
> > And even:
> > 
> > <properties>conf/hibernate.properties</properties>
> > 
> >  
> > 
> > Nada, zip, bupkis,
> > 
> >  
> > 
> > Any help?
> > 
> >  
> > 
> > /hba
> > 
> >  
-- 
David  -- Powered by Thinking
Lead Java Engineer


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to