feature: integrate Sentry SDK for crash reporting on Android and iOS
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
package bzh.ajaury.chombev
|
||||
|
||||
import io.sentry.kotlin.multiplatform.Sentry
|
||||
|
||||
object SentryHelper {
|
||||
fun initializeSentry() {
|
||||
// The DSN is injected at build time from local.properties (or the GLITCHTIP_DSN
|
||||
// environment variable) so it never lands in version control. Without it, crash
|
||||
// reporting is simply disabled.
|
||||
val dsn = BuildSecrets.GLITCHTIP_DSN
|
||||
if (dsn.isBlank()) return
|
||||
|
||||
Sentry.init { options ->
|
||||
options.dsn = dsn
|
||||
options.debug = true
|
||||
options.sendDefaultPii = false
|
||||
options.enableAutoSessionTracking = false
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user