<plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>maven-properties-plugin</artifactId> <version>1.0-SNAPSHOT</version> <executions> <execution> <phase>initialize</phase> <goals> <goal>read-project-properties</goal> </goals> <configuration> <files> <file>etc/config/dev.properties</file> </files> </configuration> </execution> </executions> </plugin>
<plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>maven-properties-plugin</artifactId> <version>1.0-SNAPSHOT</version> <executions> <execution> <phase>generate-resources</phase> <goals> <goal>write-project-properties</goal> </goals> <configuration> <outputFile> ${project.build.outputDirectory}/app.properties </outputFile> </configuration> </execution> </executions> </plugin>
<plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>maven-properties-plugin</artifactId> <version>1.0-SNAPSHOT</version> <executions> <execution> <phase>generate-resources</phase> <goals> <goal>write-active-profile-properties</goal> </goals> <configuration> <outputFile> ${project.build.outputDirectory}/app.properties </outputFile> </configuration> </execution> </executions> </plugin>