File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed
otel/src/main/kotlin/com/ryandens/javaagent/otel Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -5,6 +5,7 @@ import org.gradle.api.Plugin
55import org.gradle.api.Project
66import org.gradle.api.file.DuplicatesStrategy
77import org.gradle.jvm.tasks.Jar
8+ import java.io.File
89
910/* *
1011 * Enables easy consumption of external extensions and instrumentation libraries by creating a new jar with extra
@@ -54,7 +55,11 @@ class JavaagentOTelModificationPlugin : Plugin<Project> {
5455 jar.from(otel.map { project.zipTree(it.singleFile) }) {
5556 it.exclude(" inst/META-INF/services/**" )
5657 }
57- jar.from(otelExtension.map { it.singleFile }) {
58+ jar.from(
59+ otelExtension.map { config ->
60+ if (! config.isEmpty) config.singleFile else emptyList<File >()
61+ },
62+ ) {
5863 it.into(" extensions" )
5964 }
6065 jar.manifest {
You can’t perform that action at this time.
0 commit comments