From 95ac0e328fbe920f8b0faa7a8559ba2ee8142e9f Mon Sep 17 00:00:00 2001 From: Vyacheslav Gerasimov Date: Thu, 31 Oct 2019 15:40:14 +0300 Subject: [PATCH] Build: Extract bootstrap teamcity url to parameter --- buildSrc/src/main/kotlin/Bootstrap.kt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/buildSrc/src/main/kotlin/Bootstrap.kt b/buildSrc/src/main/kotlin/Bootstrap.kt index 610020e2bab..3d42e2111c0 100644 --- a/buildSrc/src/main/kotlin/Bootstrap.kt +++ b/buildSrc/src/main/kotlin/Bootstrap.kt @@ -83,11 +83,12 @@ sealed class BootstrapOption { val kotlinVersion: String, val buildNumber: String? = null, val projectExtId: String? = null, - val onlySuccessBootstrap: Boolean = true + val onlySuccessBootstrap: Boolean = true, + val teamcityUrl: String = "https://teamcity.jetbrains.com" ) : BootstrapOption() { override fun applyToProject(project: Project) { val query = if (onlySuccessBootstrap) "status:SUCCESS,tag:bootstrap,pinned:true" else "branch:default:any" - project.bootstrapKotlinRepo = "https://teamcity.jetbrains.com/guestAuth/app/rest/builds/buildType:(id:${projectExtId + project.bootstrapKotlinRepo = "$teamcityUrl/guestAuth/app/rest/builds/buildType:(id:${projectExtId ?: "Kotlin_dev_Compiler"}),number:${buildNumber ?: kotlinVersion},$query/artifacts/content/maven/" project.bootstrapKotlinVersion = kotlinVersion }