* Where: Build file 'your-build-your-rules/build.gradle.kts' line: 45 * What went wrong: The value for property 'jvmTarget' cannot be changed any further. ❌
abstract val manifest: RegularFileProperty @TaskAction fun validate() { if (!manifest.get().asFile.readText().contains( """<uses-sdk android:minSdkVersion="24" />""" )) throw Exception("minSdkVersion was not set to 24") } }
abstract val build: RegularFileProperty @TaskAction fun validate() { val buildContents = build.get().asFile.readText() if (buildContents.contains("kotlin {")) throw Exception("Do not configure Kotlin ...") } }
class BuildFile( val type: ProjectType, val dependencies: Dependencies, ) enum class ProjectType { androidLibrary, androidApplication } @JsonClass(generateAdapter = true) data class Dependencies(val implementation: List<String>)