diff --git a/app/build.gradle.kts b/app/build.gradle.kts index 09f19b4..632004a 100644 --- a/app/build.gradle.kts +++ b/app/build.gradle.kts @@ -2,6 +2,8 @@ plugins { alias(libs.plugins.androidApplication) alias(libs.plugins.kotlinAndroid) + id("com.google.gms.google-services") + id("com.google.firebase.crashlytics") } android { @@ -89,6 +91,7 @@ dependencies { implementation(libs.netty.resolver) implementation(libs.fastjson) implementation(libs.ipaddress) + implementation(libs.installreferrer) implementation(libs.androidx.material3) implementation(libs.androidx.material3.window.size.clazz) @@ -102,6 +105,12 @@ dependencies { debugImplementation(libs.ui.tooling) debugImplementation(libs.ui.test.manifest) + // Firebase + implementation(platform("com.google.firebase:firebase-bom:33.1.2")) + implementation("com.google.firebase:firebase-crashlytics") + implementation("com.google.firebase:firebase-analytics") + + coreLibraryDesugaring(libs.desugar.jdk.libs) implementation(libs.androidx.runtime.livedata) diff --git a/app/proguard-rules.pro b/app/proguard-rules.pro index 5eaef57..d7451a0 100644 --- a/app/proguard-rules.pro +++ b/app/proguard-rules.pro @@ -30,3 +30,5 @@ -dontwarn ** +-keepattributes SourceFile,LineNumberTable # Keep file names and line numbers. +-keep public class * extends java.lang.Exception # Optional: Keep custom exceptions. \ No newline at end of file diff --git a/build.gradle.kts b/build.gradle.kts index 20d87a7..fc02e89 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -3,5 +3,7 @@ plugins { alias(libs.plugins.androidApplication) apply false alias(libs.plugins.kotlinAndroid) apply false + id("com.google.gms.google-services") version "4.4.2" apply false + id("com.google.firebase.crashlytics") version "3.0.2" apply false } true // Needed to make the Suppress annotation work for the plugins block \ No newline at end of file diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index ed16213..2347f70 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,6 +1,7 @@ [versions] agp = "8.2.0" desugar_jdk_libs = "2.0.3" +installreferrer = "2.2" ipaddress = "5.5.0" kotlin = "1.9.0" core-ktx = "1.13.1" @@ -26,6 +27,7 @@ androidx-material3-window-size-clazz = { module = "androidx.compose.material3:ma androidx-runtime-livedata = { module = "androidx.compose.runtime:runtime-livedata", version.ref = "runtime-livedata" } core-ktx = { group = "androidx.core", name = "core-ktx", version.ref = "core-ktx" } desugar_jdk_libs = { module = "com.android.tools:desugar_jdk_libs", version.ref = "desugar_jdk_libs" } +installreferrer = { module = "com.android.installreferrer:installreferrer", version.ref = "installreferrer" } ipaddress = { module = "com.github.seancfoley:ipaddress", version.ref = "ipaddress" } junit = { group = "junit", name = "junit", version.ref = "junit" } androidx-test-ext-junit = { group = "androidx.test.ext", name = "junit", version.ref = "androidx-test-ext-junit" }