I'm writing a Maven plugin that takes as a parameter the path to the .jar file built by the project. At the moment I'm using the following definition for my configuration variable within my Mojo class...
/**
* Location of the built artifact
* @parameter expression="${project.build.finalName}
* @required
*/
private File path;
The ${project.build.finalName} property returns the path to the built artifact but does not contain the file extension. So if my build produced a file called TheBuiltJar-1.0.jar my path variable's path points to TheBuiltJar-1.0 - which isn't a valid file path.
Is there another maven property that contains the full path and extension? Or even another property that contains just the extension?