I've got a Maven2 project, where I use assembly plugin. Everything would be just fine if created assembly file name wouldn't ended with format extension (ex. ".zip"). I specified in plugin configuration a fileName parameter and setted appendAssemblyId to false. I have already spent few hours on that problem... Any idea?
My answer is a bit of a non-answer - don't remove the format extension. If you are using a specific <format>
in your assembly descriptor to produce an artifact (zip, tar.gz, etc.) there is exists no good reason to remove the extension from the file. If I'm a user of your software and download this binary, I don't want to have to guess as to what the packaging type is, I should be able to tell just by looking at the filename.
FWIW, setting appendAssemblyId to false means that the <id>
of your assembly descriptor will not be included in your file name.
Now, if you really are dead set on making this a pain for you and everyone else, what you probably want to do (as with most nonsensical things people want to make maven do) is to either use the antrun plugin to rename the generated file during your maven invocation, or just simply run a shell script to rename it after your maven process has finished.