enable code shrink

This commit is contained in:
Jannik 2020-10-20 20:22:50 +02:00
parent a5fffd5d02
commit f0ed6aa379
Signed by: Seil0
GPG Key ID: E8459F3723C52C24
4 changed files with 17 additions and 15 deletions

View File

@ -11,7 +11,7 @@ android {
minSdkVersion 23 minSdkVersion 23
targetSdkVersion 30 targetSdkVersion 30
versionCode 1 versionCode 1
versionName "0.1-alpha3" versionName "0.1-alpha4"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
resValue "string", "build_time", buildTime() resValue "string", "build_time", buildTime()
@ -20,7 +20,8 @@ android {
buildTypes { buildTypes {
release { release {
minifyEnabled false minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
} }
} }
@ -41,8 +42,8 @@ dependencies {
implementation 'androidx.core:core-ktx:1.3.2' implementation 'androidx.core:core-ktx:1.3.2'
implementation 'androidx.appcompat:appcompat:1.2.0' implementation 'androidx.appcompat:appcompat:1.2.0'
implementation 'androidx.constraintlayout:constraintlayout:2.0.2' implementation 'androidx.constraintlayout:constraintlayout:2.0.2'
implementation 'androidx.navigation:navigation-fragment-ktx:2.3.0' implementation 'androidx.navigation:navigation-fragment-ktx:2.3.1'
implementation 'androidx.navigation:navigation-ui-ktx:2.3.0' implementation 'androidx.navigation:navigation-ui-ktx:2.3.1'
implementation 'androidx.security:security-crypto:1.1.0-alpha02' implementation 'androidx.security:security-crypto:1.1.0-alpha02'
implementation 'androidx.legacy:legacy-support-v4:1.0.0' implementation 'androidx.legacy:legacy-support-v4:1.0.0'

View File

@ -15,7 +15,17 @@
# Uncomment this to preserve the line number information for # Uncomment this to preserve the line number information for
# debugging stack traces. # debugging stack traces.
#-keepattributes SourceFile,LineNumberTable #-keepattributes SourceFile,LineNumberTable
-dontobfuscate
# If you keep the line number information, uncomment this to # If you keep the line number information, uncomment this to
# hide the original source file name. # hide the original source file name.
#-renamesourcefileattribute SourceFile #-renamesourcefileattribute SourceFile
-keep class org.mosad.teapod.util.** { <fields>; }
#Gson
-keepattributes Signature
-dontwarn sun.misc.**
#misc
-dontwarn java.lang.instrument.ClassFileTransformer
-dontwarn java.lang.ClassValue

View File

@ -240,10 +240,6 @@ object AoDParser {
val secondary = pl.attr("data-otherplaylist") val secondary = pl.attr("data-otherplaylist")
val secondaryIsOmU = secondary.contains("OmU", true) val secondaryIsOmU = secondary.contains("OmU", true)
println("primary: $primary")
println("secondary: $secondary")
println("secondaryIsOmU: $secondaryIsOmU")
// load primary and secondary playlist // load primary and secondary playlist
val primaryPlaylist = parsePlaylistAsync(primary) val primaryPlaylist = parsePlaylistAsync(primary)
val secondaryPlaylist = parsePlaylistAsync(secondary) val secondaryPlaylist = parsePlaylistAsync(secondary)

View File

@ -92,13 +92,8 @@ class TMDBApiController {
GlobalScope.async { GlobalScope.async {
val response = JsonParser.parseString(url.readText()).asJsonObject val response = JsonParser.parseString(url.readText()).asJsonObject
//println(response)
val runtime = getStringNotNull(response,"runtime").toInt() return@async getStringNotNull(response,"runtime").toInt()
println(runtime)
return@async runtime
}.await() }.await()
} }