Update the rhq root pom to contain something like the following: + <!-- Use buildnumber plugin only if GIT metadata is present. --> + <profile> + <id>build-number-generation-git</id> + <activation> <file> <exists>.git</exists> </file> </activation> + <build> + <plugins> + <plugin> + <groupId>org.codehaus.mojo</groupId> + <artifactId>exec-maven-plugin</artifactId> + <executions> + <execution> + <id>generate-build-number-properties</id> + <phase>generate-resources</phase> + <goals> + <goal>exec</goal> + </goals> + <configuration> + <executable>git</executable> + <arguments> + <argument>log</argument> + <argument>--pretty=format:buildNumber = %h</argument> + <argument>-n1</argument> + </arguments> + <outputFile>${project.build.directory}/build-number.properties</outputFile> + </configuration> + </execution> + </executions> + </plugin> + </plugins> + </build> + </profile>
See also https://jira.jboss.org/browse/EMBJOPR-299.
ips - was this patch ever applied, and if so, which branches?