in src/main/java/org/apache/maven/plugins/source/AbstractSourceJarMojo.java [482:493]
protected void addDirectory(
Archiver archiver, Path sourceDirectory, String prefix, String[] pIncludes, String[] pExcludes)
throws MojoException {
try {
getLog().debug("add directory " + sourceDirectory + " to archiver with prefix " + prefix);
archiver.addFileSet(DefaultFileSet.fileSet(sourceDirectory.toFile())
.prefixed(prefix)
.includeExclude(pIncludes, pExcludes));
} catch (ArchiverException e) {
throw new MojoException("Error adding directory to source archive.", e);
}
}