Groovy Extension Module Transformer
Aggregate Apache Groovy extension modules descriptors.
Resource transformer that merges Groovy extension module descriptor files into a single file. Groovy extension module descriptor files have the name org.codehaus.groovy.runtime.ExtensionModule and live in the META-INF/services (Groovy up to 2.4) or META-INF/groovy (Groovy 2.5+) directory. See GROOVY-8480 for more details of the change.
If there are several descriptor files spread across many JARs the individual entries will be merged into a single descriptor file which will be packaged into the resultant JAR produced by the shadowing process. It will live in the legacy directory (META-INF/services) if all the processed descriptor files came from the legacy location, otherwise it will be written into the now standard location (META-INF/groovy). Note that certain JDK9+ tooling will break when using the legacy location.
Modified from eu.appsatori.gradle.fatjar.tasks.PrepareFiles.groovy. Related to org.apache.maven.plugins.shade.resource.GroovyResourceTransformer.java.