Teamcity build configurations
Hello
I have created two new Android projects and configured the TeamCity by commiting current projects settings to repository using TeamCity
Now each project has a bit different configuration:
Project 1:

settings.kts
version = "2018.1"
project {
buildType(TCTestBuildConfiguration)
}
object TCTestBuildConfiguration : BuildType({
name = "TCTest Build configuration"
vcs {
root(DslContext.settingsRoot)
}
steps {
gradle {
tasks = "clean build"
buildFile = ""
gradleWrapperPath = ""
}
}
})
Project 2: (has some custom code)

settings.kts
version = "2018.1"
project
}
//AndroidLint.kts (other files in path folder are similar)
create(DslContext.projectId, BuildType({
id("AndroidLint")
name = "Android lint"
vcs {
root(DslContext.settingsRoot)
}
steps {
gradle {
tasks = "lint"
buildFile = ""
param("teamcity.tool.jacoco", "%teamcity.tool.jacoco.DEFAULT%")
}
}
}))
Now my question is what is the difference between these two configurations and with one is the desired way to go with? What is the role of path folder and when I would need it? When I should I follow teamcity files structure from Project 1 and when form Project 2?
Please sign in to leave a comment.
Hi Igor,
patches, as in the second, are usually changes made to the UI, which are applied to the repository as UI Patches, which need to be applied to the settings.kts manually. More information about them here: https://confluence.jetbrains.com/display/TCD18/Kotlin+DSL#KotlinDSL-Patches
Summarizing, you are expected to move everything into the settings.kts file, patches simply are a method to allow for UI changes and transition them into the DSL