The best way to handle this is with multiple profiles. Then you activate one 
with -Pprofilename eg -Pdbupdate. You could either include the full plugin 
config in the plugin or just a property value, whatever makes the most sense.

Wayne

On 4/4/08, Alan Gutierrez <[EMAIL PROTECTED]> wrote:
> I have the maven plugin working with the following code.
> 
> <plugin>
>     <groupId>org.codehaus.mojo</groupId>
>     <artifactId>hibernate3-maven-plugin</artifactId>
>     <version>2.0-alpha-2</version>
>     <dependencies>
>         <dependency> 
>             <groupId>mysql</groupId>
>             <artifactId>mysql-connector-java</artifactId>
>             <version>5.1.3</version>
>         </dependency> 
>     </dependencies>
>     <configuration>
>         <executions>
>             <execution>
>                 <phase>process-resources</phase>
>                 <goals>
>                     <goal>hbm2ddl</goal>
>                 </goals>
>             </execution>
>         </executions>
>         <componentProperties>
>             <export>false</export>
>             <!-- 
>                 <update>true</update>
>             -->
>             <ejb3>true</ejb3>
>             <jdk5>true</jdk5>
>             <format>true</format>
>             <outputfilename>schema.sql</outputfilename>
>         </componentProperties>
>     </configuration>
> </plugin>
> 
> The executions section I've just added, but I'm not sure how to get
> to where I want to go.
> 
> What I want is the ability to run this plugin with the update
> feature on, so that I can update the databases easily, when I'm in
> development mode.
> 
> What XML do I add to create a new separate goal? I supposed I could
> toggle update using a commandline parameter, but I'm wondering, what
> are the ways to create a different configuration for a plugin? For
> the antrun plugin to be useful, it seems like you should be able to
> specify many different task configurations.
> 
> Alan Gutierrez
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

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

Reply via email to