|
1 | 1 | @file:Suppress("INLINE_FROM_HIGHER_PLATFORM") |
2 | 2 |
|
3 | 3 | import com.android.build.gradle.internal.cxx.configure.gradleLocalProperties |
| 4 | +import java.util.Properties |
4 | 5 |
|
5 | 6 | plugins { |
6 | 7 | alias(libs.plugins.booket.android.application) |
7 | 8 | alias(libs.plugins.booket.android.application.compose) |
8 | 9 | alias(libs.plugins.booket.android.hilt) |
| 10 | + alias(libs.plugins.booket.android.firebase) |
9 | 11 | } |
10 | 12 |
|
11 | 13 | android { |
12 | 14 | namespace = "com.ninecraft.booket" |
13 | 15 |
|
14 | | - defaultConfig { |
15 | | - buildConfigField("String", "KAKAO_NATIVE_APP_KEY", getApiKey("KAKAO_NATIVE_APP_KEY")) |
16 | | - manifestPlaceholders["KAKAO_NATIVE_APP_KEY"] = getApiKey("KAKAO_NATIVE_APP_KEY").trim('"') |
| 16 | + signingConfigs { |
| 17 | + create("release") { |
| 18 | + val propertiesFile = rootProject.file("keystore.properties") |
| 19 | + val properties = Properties() |
| 20 | + properties.load(propertiesFile.inputStream()) |
| 21 | + storeFile = rootProject.file(properties["STORE_FILE"] as String) |
| 22 | + storePassword = properties["STORE_PASSWORD"] as String |
| 23 | + keyAlias = properties["KEY_ALIAS"] as String |
| 24 | + keyPassword = properties["KEY_PASSWORD"] as String |
| 25 | + } |
17 | 26 | } |
18 | 27 |
|
19 | 28 | buildTypes { |
20 | | - release { |
21 | | - isMinifyEnabled = false |
| 29 | + getByName("debug") { |
| 30 | + isDebuggable = true |
| 31 | + applicationIdSuffix = ".dev" |
| 32 | + manifestPlaceholders += mapOf( |
| 33 | + "appName" to "@string/app_name_dev", |
| 34 | + ) |
| 35 | + } |
| 36 | + |
| 37 | + getByName("release") { |
| 38 | + isDebuggable = false |
| 39 | + isMinifyEnabled = true |
| 40 | + isShrinkResources = true |
| 41 | + signingConfig = signingConfigs.getByName("release") |
| 42 | + manifestPlaceholders += mapOf( |
| 43 | + "appName" to "@string/app_name", |
| 44 | + ) |
22 | 45 | proguardFiles( |
23 | 46 | getDefaultProguardFile("proguard-android-optimize.txt"), |
24 | 47 | "proguard-rules.pro", |
25 | 48 | ) |
26 | 49 | } |
27 | 50 | } |
28 | 51 |
|
| 52 | + defaultConfig { |
| 53 | + buildConfigField("String", "KAKAO_NATIVE_APP_KEY", getApiKey("KAKAO_NATIVE_APP_KEY")) |
| 54 | + manifestPlaceholders["KAKAO_NATIVE_APP_KEY"] = getApiKey("KAKAO_NATIVE_APP_KEY").trim('"') |
| 55 | + } |
| 56 | + |
29 | 57 | buildFeatures { |
30 | 58 | buildConfig = true |
31 | 59 | } |
|
0 commit comments