Skip to content
This repository has been archived by the owner on May 30, 2024. It is now read-only.

Commit

Permalink
Fix release build
Browse files Browse the repository at this point in the history
  • Loading branch information
onlymash committed Oct 20, 2022
1 parent d45f071 commit ab2984e
Show file tree
Hide file tree
Showing 4 changed files with 19 additions and 14 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ dependencies {
implementation("io.noties.markwon:linkify:$markwonVersion")
implementation("me.saket:better-link-movement-method:2.2.0")
implementation("com.google.firebase:firebase-analytics-ktx:21.2.0")
implementation("com.google.firebase:firebase-crashlytics:18.3.0")
implementation("com.google.firebase:firebase-crashlytics:18.2.13")
implementation("com.google.android.datatransport:transport-runtime:3.1.8")
testImplementation("junit:junit:4.13.2")
androidTestImplementation("androidx.work:work-testing:$workVersion")
Expand Down
27 changes: 16 additions & 11 deletions app/proguard-rules.pro
Original file line number Diff line number Diff line change
Expand Up @@ -93,16 +93,15 @@

# Serializer for classes with named companion objects are retrieved using `getDeclaredClasses`.
# If you have any, uncomment and replace classes with those containing named companion objects.
#-keepattributes InnerClasses # Needed for `getDeclaredClasses`.
#-if @kotlinx.serialization.Serializable class
#com.example.myapplication.HasNamedCompanion, # <-- List serializable classes with named companions.
#com.example.myapplication.HasNamedCompanion2
#{
# static **$* *;
#}
#-keepnames class <1>$$serializer { # -keepnames suffices; class is kept when serializer() is kept.
# static <1>$$serializer INSTANCE;
#}
-keepattributes InnerClasses # Needed for `getDeclaredClasses`.
-if @kotlinx.serialization.Serializable class
onlymash.flexbooru.ap.data.model.** # <-- List serializable classes with named companions.
{
static **$* *;
}
-keepnames class <1>$$serializer { # -keepnames suffices; class is kept when serializer() is kept.
static <1>$$serializer INSTANCE;
}

-keep,includedescriptorclasses class onlymash.flexbooru.ap.data.model.**$$serializer { *; }
-keepclassmembers class onlymash.flexbooru.ap.data.model.** {
Expand All @@ -113,4 +112,10 @@
}

-keep class com.google.android.datatransport.runtime.ForcedSender
-dontwarn com.google.android.datatransport.runtime.ForcedSender
-dontwarn com.google.android.datatransport.runtime.ForcedSender

-keep, allowobfuscation, allowoptimization class org.kodein.type.TypeReference
-keep, allowobfuscation, allowoptimization class org.kodein.type.JVMAbstractTypeToken$Companion$WrappingTest

-keep, allowobfuscation, allowoptimization class * extends org.kodein.type.TypeReference
-keep, allowobfuscation, allowoptimization class * extends org.kodein.type.JVMAbstractTypeToken$Companion$WrappingTest
2 changes: 1 addition & 1 deletion app/src/main/java/onlymash/flexbooru/ap/common/Settings.kt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ private const val MUZEI_QUERY_KEY = "muzei_query"

object Settings {

private val sp by App.app.instance<SharedPreferences>()
private val sp: SharedPreferences by App.app.instance()

private val nightModeString: String
get() = sp.getString(SETTINGS_NIGHT_MODE_KEY, SETTINGS_NIGHT_MODE_SYSTEM) ?: SETTINGS_NIGHT_MODE_SYSTEM
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ kotlin.code.style=official
android.injected.testOnly=false
android.enableJetifier=true
android.useAndroidX=true
android.enableR8.fullMode=true
#android.enableR8.fullMode=true
org.gradle.jvmargs=-Xmx2048M

0 comments on commit ab2984e

Please sign in to comment.