Hi:
Here is what needs to be achieved:
I have 3 different configuration files: application-dev.properties,
application-int.properties, application-prod.properties. Depending on
the value taken by a certain variable (where and how do shoudl I define
this variable??), I need to have one of the above files copied to a
certain directory, and renamed.
How do I achieve this with Maven?
I have tried using the maven-dependency-plugin, but am not sure how to
define the artifacts...
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>copy</id>
<phase>package</phase>
<goals>
<goal>copy</goal>
</goals>
<configuration>
<artifactItems>
<artifactItem>
<groupId>my-application</groupId>
<artifactId>application-prod.xml</artifactId>
<type>file</type>
<overWrite>false</overWrite>
<outputDirectory>${project.build.directory}</outputDirectory>
<destFileName>application.xml</destFileName>
</artifactItem>
</artifactItems>
</configuration>
</execution>
</executions>
</plugin>
This message (including any attachments) contains confidential information
intended for a specific individual and purpose, and is protected by law. If
you are not the intended recipient, you should delete this message.
Any disclosure, copying, or distribution of this message, or the taking of any
action based on it, is strictly prohibited. [v.E.1]