build.gradle.kts 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. import com.android.build.api.dsl.CommonExtension
  2. import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
  3. allprojects {
  4. repositories {
  5. google()
  6. mavenCentral()
  7. maven {
  8. name = "GitHubPackages"
  9. url = uri("https://maven.pkg.github.com/revanced/registry")
  10. credentials {
  11. username = providers.gradleProperty("gpr.user").orNull ?: System.getenv("GITHUB_ACTOR")
  12. password = providers.gradleProperty("gpr.key").orNull ?: System.getenv("GITHUB_TOKEN")
  13. }
  14. }
  15. }
  16. }
  17. layout.buildDirectory = File("../build")
  18. project(":screenshot_callback") {
  19. tasks.withType<KotlinCompile>().configureEach {
  20. kotlinOptions {
  21. jvmTarget = "17"
  22. }
  23. }
  24. }
  25. subprojects {
  26. afterEvaluate {
  27. extensions.findByName("android")?.let {
  28. it as CommonExtension<*, *, *, *, *, *>
  29. if (it.compileSdk != null && it.compileSdk!! < 31)
  30. it.compileSdk = 34
  31. }
  32. }
  33. layout.buildDirectory = rootProject.layout.buildDirectory.file(name).get().asFile
  34. evaluationDependsOn(":app")
  35. }