Skip to content

Commit 669b3e9

Browse files
committed
release-1.0.0 chore: 실배포 설정
1 parent a3e6b4a commit 669b3e9

8 files changed

Lines changed: 104 additions & 5 deletions

File tree

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
*.iml
22
.gradle
33
/local.properties
4+
/keystore.properties
45
/.idea/caches
56
/.idea/libraries
67
/.idea/modules.xml
@@ -13,3 +14,4 @@
1314
.externalNativeBuild
1415
.cxx
1516
local.properties
17+
keystore.properties

app/build.gradle.kts

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
import com.android.build.gradle.internal.cxx.configure.gradleLocalProperties
2+
import java.io.FileInputStream
3+
import java.util.Properties
24

35
@Suppress("DSL_SCOPE_VIOLATION")
46
plugins {
@@ -11,11 +13,16 @@ plugins {
1113

1214
}
1315

14-
fun getApiKey(propertyKey : String): String {
15-
return gradleLocalProperties(rootDir).getProperty(propertyKey)
16-
}
17-
1816
android {
17+
signingConfigs {
18+
create("release") {
19+
storeFile =
20+
file(getKeyStore("storeFile"))
21+
storePassword = getKeyStore("storePassword")
22+
keyAlias = getKeyStore("keyAlias")
23+
keyPassword = getKeyStore("keyPassword")
24+
}
25+
}
1926
namespace = "com.moneymong.moneymong"
2027
compileSdk = 34
2128

@@ -43,6 +50,7 @@ android {
4350
getDefaultProguardFile("proguard-android-optimize.txt"),
4451
"proguard-rules.pro"
4552
)
53+
signingConfig = signingConfigs.getByName("release")
4654
}
4755
}
4856
packaging {
@@ -84,4 +92,20 @@ dependencies {
8492
testImplementation(libs.junit4)
8593
androidTestImplementation(libs.androidx.junit)
8694
androidTestImplementation(libs.androidx.test.espresso.core)
95+
}
96+
97+
fun keystoreProperties(projectRootDir : File) : Properties {
98+
val keystorePropertiesFile = rootProject.file("keystore.properties")
99+
val keystoreProperties = Properties()
100+
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
101+
102+
return keystoreProperties
103+
}
104+
105+
fun getApiKey(propertyKey : String): String {
106+
return gradleLocalProperties(rootDir).getProperty(propertyKey)
107+
}
108+
109+
fun getKeyStore(keystoreKey : String): String {
110+
return keystoreProperties(rootDir).getProperty(keystoreKey)
87111
}

app/proguard-rules.pro

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,20 @@
2626
# https://github.com/square/okhttp/pull/6792
2727
-dontwarn org.bouncycastle.jsse.**
2828
-dontwarn org.conscrypt.*
29-
-dontwarn org.openjsse.**
29+
-dontwarn org.openjsse.**
30+
31+
# With R8 full mode generic signatures are stripped for classes that are not
32+
# kept. Suspend functions are wrapped in continuations where the type argument
33+
# is used.
34+
-keep,allowobfuscation,allowshrinking interface retrofit2.Call
35+
-keep,allowobfuscation,allowshrinking class kotlin.coroutines.Continuation
36+
37+
# Kotlin Result Wrapper 예외
38+
-keep class kotlin.Result { *; }
39+
40+
# R8 full mode strips generic signatures from return types if not kept.
41+
-if interface * { @retrofit2.http.* public *** *(...); }
42+
-keep,allowoptimization,allowshrinking,allowobfuscation class <3>
43+
44+
# With R8 full mode generic signatures are stripped for classes that are not kept.
45+
-keep,allowobfuscation,allowshrinking class retrofit2.Response

app/src/live/google-services.json

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
{
2+
"project_info": {
3+
"project_number": "1091533625653",
4+
"project_id": "moneymong-9e794",
5+
"storage_bucket": "moneymong-9e794.appspot.com"
6+
},
7+
"client": [
8+
{
9+
"client_info": {
10+
"mobilesdk_app_id": "1:1091533625653:android:f8c3edecf6f6108fad547c",
11+
"android_client_info": {
12+
"package_name": "com.moneymong.moneymong.live"
13+
}
14+
},
15+
"oauth_client": [],
16+
"api_key": [
17+
{
18+
"current_key": "AIzaSyAb9dOMs-B-u9YynEWdtV9nrq_VbMpAXtg"
19+
}
20+
],
21+
"services": {
22+
"appinvite_service": {
23+
"other_platform_oauth_client": []
24+
}
25+
}
26+
},
27+
{
28+
"client_info": {
29+
"mobilesdk_app_id": "1:1091533625653:android:435637da7f3d4352ad547c",
30+
"android_client_info": {
31+
"package_name": "com.moneymong.moneymong.tb"
32+
}
33+
},
34+
"oauth_client": [],
35+
"api_key": [
36+
{
37+
"current_key": "AIzaSyAb9dOMs-B-u9YynEWdtV9nrq_VbMpAXtg"
38+
}
39+
],
40+
"services": {
41+
"appinvite_service": {
42+
"other_platform_oauth_client": []
43+
}
44+
}
45+
}
46+
],
47+
"configuration_version": "1"
48+
}

core/network/build.gradle.kts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,15 @@ android {
2222
buildConfigField("String", "MONEYMONG_BASE_URL", "\"https://dev.moneymong.site/\"")
2323
}
2424

25+
buildTypes {
26+
debug {
27+
buildConfigField("String", "MONEYMONG_BASE_URL", "\"https://dev.moneymong.site/\"")
28+
}
29+
release {
30+
buildConfigField("String", "MONEYMONG_BASE_URL", "\"https://moneymong.site/\"")
31+
}
32+
}
33+
2534
buildFeatures {
2635
buildConfig = true
2736
}

keystore/moneymong-keystore

-2.47 KB
Binary file not shown.

keystore/moneymong-keystore2

2.5 KB
Binary file not shown.

0 commit comments

Comments
 (0)