|
| 1 | +import extension.addCoreModuleDependencies |
| 2 | +import extension.addInstrumentationTestDependencies |
| 3 | +import extension.addUnitTestDependencies |
| 4 | + |
| 5 | +plugins { |
| 6 | + id(Plugins.ANDROID_LIBRARY_PLUGIN) |
| 7 | + id(Plugins.KOTLIN_ANDROID_PLUGIN) |
| 8 | + id(Plugins.KOTLIN_ANDROID_EXTENSIONS_PLUGIN) |
| 9 | + id(Plugins.KOTLIN_KAPT_PLUGIN) |
| 10 | + id(Plugins.DAGGER_HILT_PLUGIN) |
| 11 | +} |
| 12 | + |
| 13 | +android { |
| 14 | + |
| 15 | + compileSdkVersion(AndroidVersion.COMPILE_SDK_VERSION) |
| 16 | + defaultConfig { |
| 17 | + minSdkVersion(AndroidVersion.MIN_SDK_VERSION) |
| 18 | + targetSdkVersion(AndroidVersion.TARGET_SDK_VERSION) |
| 19 | + versionCode = AndroidVersion.VERSION_CODE |
| 20 | + versionName = AndroidVersion.VERSION_NAME |
| 21 | + testInstrumentationRunner = "androidx.test.runner.AndroidJUnitRunner" |
| 22 | + } |
| 23 | + |
| 24 | + buildTypes { |
| 25 | + getByName("release") { |
| 26 | + isMinifyEnabled = false |
| 27 | + proguardFiles( |
| 28 | + getDefaultProguardFile("proguard-android-optimize.txt"), |
| 29 | + "proguard-rules.pro" |
| 30 | + ) |
| 31 | + } |
| 32 | + } |
| 33 | + |
| 34 | + android.buildFeatures.dataBinding = true |
| 35 | + |
| 36 | + compileOptions { |
| 37 | + sourceCompatibility = JavaVersion.VERSION_1_8 |
| 38 | + targetCompatibility = JavaVersion.VERSION_1_8 |
| 39 | + } |
| 40 | + |
| 41 | + kotlinOptions { |
| 42 | + jvmTarget = "1.8" |
| 43 | + } |
| 44 | + |
| 45 | + testOptions { |
| 46 | + unitTests.isIncludeAndroidResources = true |
| 47 | + } |
| 48 | +} |
| 49 | + |
| 50 | +dependencies { |
| 51 | + |
| 52 | + implementation(fileTree(mapOf("dir" to "libs", "include" to listOf("*.jar")))) |
| 53 | + |
| 54 | + implementation(project(Modules.AndroidLibrary.DOMAIN)) |
| 55 | + implementation(project(Modules.AndroidLibrary.DATA)) |
| 56 | + |
| 57 | + addCoreModuleDependencies() |
| 58 | + |
| 59 | + addUnitTestDependencies() |
| 60 | + testImplementation(project(Modules.AndroidLibrary.TEST_UTILS)) |
| 61 | + |
| 62 | + addInstrumentationTestDependencies() |
| 63 | + androidTestImplementation(project(Modules.AndroidLibrary.TEST_UTILS)) |
| 64 | +} |
0 commit comments