in src/main/java/org/apache/sling/maven/projectsupport/PreparePackageMojo.java [309:326]
private void unpack(File source, File destination)
throws MojoExecutionException {
getLog().info("Unpacking " + source.getPath() + " to\n " + destination.getPath());
try {
destination.mkdirs();
UnArchiver unArchiver = archiverManager.getUnArchiver(source);
unArchiver.setSourceFile(source);
unArchiver.setDestDirectory(destination);
unArchiver.extract();
} catch (NoSuchArchiverException e) {
throw new MojoExecutionException("Unable to find archiver for " + source.getPath(), e);
} catch (ArchiverException e) {
throw new MojoExecutionException("Unable to unpack " + source.getPath(), e);
}
}