I've spent countless hours trying to resolve this issue but i'm still on the dark and hoping someone could give a helping hand. Here is my situation:
(finalName)somename.${var1}-${var2}(/finalName) --> i'm using parenthesis here around the fileName element since somehow i cannot use the brackets in this editor.
These ${var1} and ${var2} are defined in an external .properties file. To read in these vars i'm using the properties-maven-plugin. I cannot define these vars within the pom cuz they change for each deployment and cannot be provided from the cmd line. When i run mvn assembly:single, the zip artifact is created as somename.null-null.zip. It looks like the properties defined in the .properties files are null or not being evaluated. When i run mvn in debug mode, i see that the resources are set properly: var1=something and var2=somethingelse. They both have the right values. I'm at loss right now. Any help will be greatly appreciated.
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-assembly-plugin</artifactId>
<executions>
<execution>
<id>assembly:package</id>
<phase>package</phase>
.
.
<configuration>
<finalName>zipName</finalName>
<appendAssemblyId>false</appendAssemblyId>
<descriptors>
.
.
</descriptors>
</configuration>
</execution>
</executions>
</plugin>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With