Skip to content

Commit

Permalink
Add Firebase Crashlytics
Browse files Browse the repository at this point in the history
  • Loading branch information
LinZong committed Aug 18, 2024
1 parent 1d03455 commit 10a6dca
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 0 deletions.
9 changes: 9 additions & 0 deletions app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down Expand Up @@ -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)
Expand All @@ -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)
Expand Down
2 changes: 2 additions & 0 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -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.
2 changes: 2 additions & 0 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -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
2 changes: 2 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -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"
Expand All @@ -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" }
Expand Down

0 comments on commit 10a6dca

Please sign in to comment.