From 4d8f43dde4782ab0ccceeab7898e75a0ca0d0a7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kuba=20Szczodrzy=C5=84ski?= Date: Sun, 29 Sep 2019 20:11:21 +0200 Subject: [PATCH] Update .gitignore and proguard config --- .gitignore | 2 +- app/proguard/android-job.pro | 14 ++++++++++ app/proguard/app.pro | 42 ++++++++++++++++++++++++++++++ app/proguard/blurry.pro | 1 + app/proguard/cafebar.pro | 25 ++++++++++++++++++ app/proguard/eventbus.pro | 10 ++++++++ app/proguard/iconics.pro | 14 ++++++++++ app/proguard/jsoup.pro | 1 + app/proguard/mhttp.pro | 48 +++++++++++++++++++++++++++++++++++ app/proguard/okhttp3.pro | 19 ++++++++++++++ app/proguard/szkolny-font.pro | 1 + app/proguard/wear.pro | 21 +++++++++++++++ 12 files changed, 197 insertions(+), 1 deletion(-) create mode 100644 app/proguard/android-job.pro create mode 100644 app/proguard/app.pro create mode 100644 app/proguard/blurry.pro create mode 100644 app/proguard/cafebar.pro create mode 100644 app/proguard/eventbus.pro create mode 100644 app/proguard/iconics.pro create mode 100644 app/proguard/jsoup.pro create mode 100644 app/proguard/mhttp.pro create mode 100644 app/proguard/okhttp3.pro create mode 100644 app/proguard/szkolny-font.pro create mode 100644 app/proguard/wear.pro diff --git a/.gitignore b/.gitignore index e7ded9f4..047ad745 100644 --- a/.gitignore +++ b/.gitignore @@ -23,7 +23,7 @@ build/ local.properties # Proguard folder generated by Eclipse -proguard/ +#proguard/ # Log Files *.log diff --git a/app/proguard/android-job.pro b/app/proguard/android-job.pro new file mode 100644 index 00000000..3f1a67be --- /dev/null +++ b/app/proguard/android-job.pro @@ -0,0 +1,14 @@ +-dontwarn com.evernote.android.job.gcm.** +-dontwarn com.evernote.android.job.GcmAvailableHelper +-dontwarn com.evernote.android.job.work.** +-dontwarn com.evernote.android.job.WorkManagerAvailableHelper + +-keep public class com.evernote.android.job.v21.PlatformJobService +-keep public class com.evernote.android.job.v14.PlatformAlarmService +-keep public class com.evernote.android.job.v14.PlatformAlarmReceiver +-keep public class com.evernote.android.job.JobBootReceiver +-keep public class com.evernote.android.job.JobRescheduleService +-keep public class com.evernote.android.job.gcm.PlatformGcmService +-keep public class com.evernote.android.job.work.PlatformWorker + +-keep class com.evernote.android.job.** { *; } \ No newline at end of file diff --git a/app/proguard/app.pro b/app/proguard/app.pro new file mode 100644 index 00000000..cca80f68 --- /dev/null +++ b/app/proguard/app.pro @@ -0,0 +1,42 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile +-keep class android.support.v7.widget.** { *; } + +-keep class pl.szczodrzynski.edziennik.utils.models.** { *; } +-keep class pl.szczodrzynski.edziennik.db.modules.events.Event { *; } +-keep class pl.szczodrzynski.edziennik.db.modules.events.EventFull { *; } +-keepclassmembers class pl.szczodrzynski.edziennik.widgets.WidgetConfig { public *; } +-keepnames class pl.szczodrzynski.edziennik.WidgetTimetable +-keepnames class pl.szczodrzynski.edziennik.notifications.WidgetNotifications +-keepnames class pl.szczodrzynski.edziennik.luckynumber.WidgetLuckyNumber + +-keep class .R +-keep class **.R$* { + ; +} + +-keepattributes SourceFile,LineNumberTable +#-printmapping mapping.txt + +-keep class okhttp3.** { *; } + +-keep class com.google.android.material.tabs.** {*;} \ No newline at end of file diff --git a/app/proguard/blurry.pro b/app/proguard/blurry.pro new file mode 100644 index 00000000..980f404e --- /dev/null +++ b/app/proguard/blurry.pro @@ -0,0 +1 @@ +-keep class android.support.v8.renderscript.** { *; } \ No newline at end of file diff --git a/app/proguard/cafebar.pro b/app/proguard/cafebar.pro new file mode 100644 index 00000000..6f8147fd --- /dev/null +++ b/app/proguard/cafebar.pro @@ -0,0 +1,25 @@ +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in D:\AndroidSDK/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the proguardFiles +# directive in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +-keep class !android.support.v7.internal.view.menu.**,android.support.** {*;} +-keep class android.support.v7.graphics.** { *; } +-dontwarn android.support.v7.graphics.** + +-keep class android.support.design.widget.** { *; } +-keep interface android.support.design.widget.** { *; } +-dontwarn android.support.design.** diff --git a/app/proguard/eventbus.pro b/app/proguard/eventbus.pro new file mode 100644 index 00000000..cf6b3480 --- /dev/null +++ b/app/proguard/eventbus.pro @@ -0,0 +1,10 @@ +-keepattributes *Annotation* +-keepclassmembers class * { + @org.greenrobot.eventbus.Subscribe ; +} +-keep enum org.greenrobot.eventbus.ThreadMode { *; } + +# Only required if you use AsyncExecutor +-keepclassmembers class * extends org.greenrobot.eventbus.util.ThrowableFailureEvent { + (java.lang.Throwable); +} \ No newline at end of file diff --git a/app/proguard/iconics.pro b/app/proguard/iconics.pro new file mode 100644 index 00000000..0aa62122 --- /dev/null +++ b/app/proguard/iconics.pro @@ -0,0 +1,14 @@ +# Android iconics library - https://github.com/mikepenz/Android-Iconics +# Warning: works ONLY with iconics > 1.0.0 +# +# Tested on gradle config: +# +# compile 'com.mikepenz:iconics-core:1.7.1@aar' +# + +-keep class com.mikepenz.iconics.** { *; } +-keep class com.mikepenz.community_material_typeface_library.CommunityMaterial +-keep class com.mikepenz.fontawesome_typeface_library.FontAwesome +-keep class com.mikepenz.google_material_typeface_library.GoogleMaterial +-keep class com.mikepenz.meteocons_typeface_library.Meteoconcs +-keep class com.mikepenz.octicons_typeface_library.Octicons \ No newline at end of file diff --git a/app/proguard/jsoup.pro b/app/proguard/jsoup.pro new file mode 100644 index 00000000..cb139ecd --- /dev/null +++ b/app/proguard/jsoup.pro @@ -0,0 +1 @@ +-keep class org.jsoup.** \ No newline at end of file diff --git a/app/proguard/mhttp.pro b/app/proguard/mhttp.pro new file mode 100644 index 00000000..6d3e4e38 --- /dev/null +++ b/app/proguard/mhttp.pro @@ -0,0 +1,48 @@ +# Add project specific ProGuard rules here. +# By default, the flags in this file are appended to flags specified +# in /Users/wangchao/Work/android-sdk/sdk/tools/proguard/proguard-android.txt +# You can edit the include path and order by changing the proguardFiles +# directive in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# Add any project specific keep options here: + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} +-dontwarn im.wangchao.** +-dontwarn okio.** +-dontwarn javax.annotation.Nullable +-dontwarn javax.annotation.ParametersAreNonnullByDefault +-keep class im.wangchao.** { *; } +-keep class **_HttpBinder { *; } +-keepclasseswithmembernames class * { + @im.wangchao.* ; +} +-keepclasseswithmembernames class * { + @im.wangchao.* ; +} +-keepclassmembers class * implements java.io.Serializable { + static final long serialVersionUID; + private static final java.io.ObjectStreamField[] serialPersistentFields; + !static !transient ; + private void writeObject(java.io.ObjectOutputStream); + private void readObject(java.io.ObjectInputStream); + java.lang.Object writeReplace(); + java.lang.Object readResolve(); +} +# okhttp +-dontwarn okhttp3.** +-dontwarn okio.** +-dontwarn javax.annotation.** +-dontwarn org.conscrypt.** +# A resource is loaded with a relative path so the package of this class must be preserved. +-keepnames class okhttp3.internal.publicsuffix.PublicSuffixDatabase + +# If you do not use Rx: +-dontwarn rx.** \ No newline at end of file diff --git a/app/proguard/okhttp3.pro b/app/proguard/okhttp3.pro new file mode 100644 index 00000000..d17d3566 --- /dev/null +++ b/app/proguard/okhttp3.pro @@ -0,0 +1,19 @@ +# JSR 305 annotations are for embedding nullability information. +-dontwarn javax.annotation.** + +# A resource is loaded with a relative path so the package of this class must be preserved. +-keepnames class okhttp3.internal.publicsuffix.PublicSuffixDatabase + +# Animal Sniffer compileOnly dependency to ensure APIs are compatible with older versions of Java. +-dontwarn org.codehaus.mojo.animal_sniffer.* + +# OkHttp platform used only on JVM and when Conscrypt dependency is available. +-dontwarn okhttp3.internal.platform.ConscryptPlatform + +# This is added for okhttp 3.1.2 bug fix as shown at https://github.com/square/okhttp/issues/2323 +-keepclassmembers class * implements javax.net.ssl.SSLSocketFactory { + private javax.net.ssl.SSLSocketFactory delegate; +} + +-keepnames class sun.security.ssl.SSLContextImpl +-keepnames class javax.net.ssl.SSLSocketFactory diff --git a/app/proguard/szkolny-font.pro b/app/proguard/szkolny-font.pro new file mode 100644 index 00000000..4e48be73 --- /dev/null +++ b/app/proguard/szkolny-font.pro @@ -0,0 +1 @@ +-keep class com.mikepenz.szkolny_font_typeface_library.SzkolnyFont { *; } diff --git a/app/proguard/wear.pro b/app/proguard/wear.pro new file mode 100644 index 00000000..f1b42451 --- /dev/null +++ b/app/proguard/wear.pro @@ -0,0 +1,21 @@ +# Add project specific ProGuard rules here. +# You can control the set of applied configuration files using the +# proguardFiles setting in build.gradle. +# +# For more details, see +# http://developer.android.com/guide/developing/tools/proguard.html + +# If your project uses WebView with JS, uncomment the following +# and specify the fully qualified class name to the JavaScript interface +# class: +#-keepclassmembers class fqcn.of.javascript.interface.for.webview { +# public *; +#} + +# Uncomment this to preserve the line number information for +# debugging stack traces. +#-keepattributes SourceFile,LineNumberTable + +# If you keep the line number information, uncomment this to +# hide the original source file name. +#-renamesourcefileattribute SourceFile