Take the 2-minute tour ×

I've set up the buildnumber-maven-plugin to pull the version number from SVN and stash it away in the META-INF/MANIFEST.MF inside the jar. That works ok.

But when I try to use it together with the maven-assembly-plugin to pack all the other libs together It doesn't seem to work, the version number stuff is not included in the manifest in the ...-jar-with-dependencies.jar.

Has anybody managed to get them to work together?

Alternatively: Is there a (reasonable simple) way to output the ${buildNumber} into a text file (.properties, perhaps) using Maven? An Ant task in Maven could do it I guess but is there an easier way?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

Argh... after posting I found THIS: how to add arbitrary information in manifest from maven assembly plugin and smacked my head.

OK, so My maven-assembly-plugin bit in the pom now looks like this

<build> ... <plugins> ...
share|improve this answer
And I did NOT post a question and an answer to it on purpose. The "Related" column gave me the answer after posting the question... –  PapaFreud Sep 15 '11 at 7:27

Your Answer


