Using Inline Assembly Descriptors
Introduction
For simple usage we can inline Assembly descriptor into the project configuration. We don't need to create an additional file with Assembly descriptor.
It can simplify configuration in case of the parent project inherited, we don't need to use a Shared Assembly Descriptors
The POM
We can have POM configuration of the project for the Assembly Plugin, which can look like:
<project> [...] <build> [...] <plugins> [...] <plugin> <artifactId>maven-assembly-plugin</artifactId> <version>3.7.1</version> <configuration> <inlineDescriptors> <inlineDescriptor> <id>example1</id> <formats> <format>dir</format> </formats> <files> <file> <source>TODO.txt</source> </file> </files> </inlineDescriptor> <inlineDescriptor> <id>example2</id> <formats> <format>zip</format> </formats> <files> <file> <source>TODO.txt</source> </file> </files> </inlineDescriptor> </inlineDescriptors> </configuration> </plugin> [...] </project>
Each element of inlineDescriptors
must follow Assembly Descriptor format.