48 lines
1.3 KiB
Groovy
48 lines
1.3 KiB
Groovy
// Top-level build file where you can add configuration options common to all sub-projects/modules.
|
|
|
|
buildscript {
|
|
|
|
repositories {
|
|
google()
|
|
mavenCentral()
|
|
}
|
|
dependencies {
|
|
classpath 'com.android.tools.build:gradle:8.9.0'
|
|
classpath 'com.google.gms:google-services:4.4.2'
|
|
|
|
// NOTE: Do not place your application dependencies here; they belong
|
|
// in the individual module build.gradle files
|
|
}
|
|
}
|
|
|
|
apply from: "variables.gradle"
|
|
|
|
allprojects {
|
|
repositories {
|
|
google()
|
|
mavenCentral()
|
|
}
|
|
|
|
// Java 버전 설정
|
|
tasks.withType(JavaCompile).configureEach {
|
|
// 이 설정은 모든 하위 프로젝트에 적용됩니다
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
targetCompatibility = JavaVersion.VERSION_17
|
|
// options.release = 17 // 안드로이드 그래들 플러그인과 호환되지 않아 제거
|
|
}
|
|
|
|
// 프로젝트가 이미 평가된 후에 도 적용될 수 있도록 동적으로 적용
|
|
afterEvaluate { project ->
|
|
if (project.hasProperty('android')) {
|
|
project.android.compileOptions {
|
|
sourceCompatibility JavaVersion.VERSION_17
|
|
targetCompatibility JavaVersion.VERSION_17
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
task clean(type: Delete) {
|
|
delete rootProject.buildDir
|
|
}
|