Skip to content

Commit 0faa939

Browse files
committed
update mode
1 parent b1256d1 commit 0faa939

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

sdk-extensions/incubator/build.gradle.kts

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,8 +58,9 @@ dependencies {
5858
// ... proceed with normal sourcesJar, compileJava, etc
5959

6060
val configurationTag = "1.0.0-rc.1"
61-
val configurationRef = "refs/tags/v$configurationTag" // Replace with commit SHA to point to experiment with a specific commit
62-
val configurationRepoZip = "https://github.com/open-telemetry/opentelemetry-configuration/archive/$configurationRef.zip"
61+
// todo revert this when config PR is merged: https://github.com/open-telemetry/opentelemetry-configuration/pull/275
62+
val configurationRef = "refs/heads/authenticator" // Replace with commit SHA to point to experiment with a specific commit
63+
val configurationRepoZip = "https://github.com/zeitlinger/opentelemetry-configuration/archive/$configurationRef.zip"
6364
val buildDirectory = layout.buildDirectory.asFile.get()
6465

6566
val downloadConfigurationSchema by tasks.registering(Download::class) {
@@ -69,8 +70,15 @@ val downloadConfigurationSchema by tasks.registering(Download::class) {
6970
}
7071

7172
val unzipConfigurationSchema by tasks.registering(Copy::class) {
72-
from("/home/gregor/source/opentelemetry-configuration/schema")
73-
into("$buildDirectory/configuration/schema/")
73+
dependsOn(downloadConfigurationSchema)
74+
75+
from(zipTree(downloadConfigurationSchema.get().dest))
76+
eachFile(closureOf<FileCopyDetails> {
77+
// Remove the top level folder "/opentelemetry-configuration-$configurationRef"
78+
val pathParts = path.split("/")
79+
path = pathParts.subList(1, pathParts.size).joinToString("/")
80+
})
81+
into("$buildDirectory/configuration/")
7482
}
7583

7684
val deleteTypeDescriptions by tasks.registering(Delete::class) {

0 commit comments

Comments
 (0)