Join the two executions of the maven-exec-plugin to avoid a Maven warning
<version>1.1</version>
<executions>
<execution>
+ <id>create-build-properties</id>
<phase>compile</phase>
<goals>
<goal>exec</goal>
<outputFile>target/build.properties</outputFile>
</configuration>
</execution>
- </executions>
- </plugin>
- <!-- This forces the dependencies to be copied to target/lib -->
- <plugin>
- <artifactId>maven-dependency-plugin</artifactId>
- <executions>
<execution>
- <phase>package</phase>
+ <id>create-classes-build-properties</id>
+ <phase>compile</phase>
<goals>
- <goal>copy-dependencies</goal>
+ <goal>exec</goal>
</goals>
<configuration>
- <outputDirectory>${project.build.directory}/lib</outputDirectory>
+ <executable>git</executable>
+ <arguments>
+ <argument>log</argument>
+ <argument>--pretty=format:build_revision=%H</argument>
+ <argument>-n1</argument>
+ </arguments>
+ <outputFile>target/classes/com/pinterest/secor/common/build.properties</outputFile>
</configuration>
</execution>
</executions>
</plugin>
+ <!-- This forces the dependencies to be copied to target/lib -->
<plugin>
- <groupId>org.codehaus.mojo</groupId>
- <artifactId>exec-maven-plugin</artifactId>
- <version>1.1</version>
+ <artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
- <phase>compile</phase>
+ <phase>package</phase>
<goals>
- <goal>exec</goal>
+ <goal>copy-dependencies</goal>
</goals>
<configuration>
- <executable>git</executable>
- <arguments>
- <argument>log</argument>
- <argument>--pretty=format:build_revision=%H</argument>
- <argument>-n1</argument>
- </arguments>
- <outputFile>target/classes/com/pinterest/secor/common/build.properties</outputFile>
+ <outputDirectory>${project.build.directory}/lib</outputDirectory>
</configuration>
</execution>
</executions>
