Project Name | Stars | Downloads | Repos Using This | Packages Using This | Most Recent Commit | Total Releases | Latest Release | Open Issues | License | Language |
---|---|---|---|---|---|---|---|---|---|---|
Androidnote | 1,497 | 3 months ago | apache-2.0 | HTML | ||||||
Android基础知识、Android进阶知识、Android自定义View相关、面试相关的知识,欢迎fork,star~ | ||||||||||
Mkloader | 1,352 | 6 years ago | 12 | apache-2.0 | Java | |||||
Beautiful and smooth custom loading views | ||||||||||
Bottomdialogs | 639 | 2 years ago | 28 | apache-2.0 | Java | |||||
An Android library that shows a customizable Material-based bottom sheet. API 11+ required. | ||||||||||
Mess | 586 | 5 years ago | 9 | mit | Groovy | |||||
a gradle plugin for minifying activities, services, receivers, providers and custom view | ||||||||||
Xmarqueeview | 200 | 4 years ago | 1 | apache-2.0 | Java | |||||
:collision:【MarqueeView】类似淘宝头条、京东头条的跑马灯效果,上下轮播,支持单行/多行显示、自定义轮播布局 | ||||||||||
Codeeditor | 184 | 7 months ago | 6 | apache-2.0 | Java | |||||
Code Editor Native Way | ||||||||||
Simpleratingbar | 142 | 6 years ago | apache-2.0 | Kotlin | ||||||
SimpleRatingBar allows us to create a RatingBar with margin between items | ||||||||||
Cosin | 127 | 5 years ago | 3 | February 19, 2019 | mit | Java | ||||
Android loading view library 📊🍭 | ||||||||||
Image Support | 108 | 2 years ago | 1 | April 16, 2019 | 2 | Java | ||||
Add badge with counter to ImageView Android. | ||||||||||
Csnackbar | 76 | 2 years ago | 3 | apache-2.0 | Java | |||||
This is a wrapper for android Snackbar. Which giving support to change Snackbar color, duration, message or even it's content view with a custom view. |
mess is a gradle plugin for obfuscating all code including activity, service, receiver, provider and custom view. It's really very cool to obfuscate all codes, lowers code readability after reverse engineering and ensures code's safety.
mess is super easy to integrate with your app, its implementation is also clear to understand. During android gradle assemble task execution, It has a lot of tasks to do, and can be divided to resource process & code process briefly.
process*Resources is the last task in resource process, it will generate a merged AndroidManifest.xml, aapt_rules.txt and a merged res directory in project build dir. aapt_rules.txt is the output file after aapt, it contains all classes in xml files, and then this file is delivered to proguard task as a list of keeps. transformClassesAndResourcesWithProguardFor* is the proguard task which obfuscates code, it generates a mapping.txt file which contains all mapping relation between origin and obfuscated classes.
mess hooks two android gradle tasks: process*Resources & package*, hook processResources task is to clear aapt_rules.txt, tells proguard not to obfuscate all the classes in xml; package task is the last task before package code & resource into apk, it runs after proguard, mess hooks it just to read the obfuscation mapping relation, then rewrite these into resources again, finally execute processResources task again. If your app sets shrinkResources to be true, then execute shrink task one more time.
dependencies {
...
classpath 'me.ele:mess-plugin:1.1.5'
}
apply plugin: 'com.android.library'
apply plugin: 'me.ele.mess'
In some cases, you want to ignore some proguard configuration provided by aar. E.g. latest Butter Knife is an aar which contains proguard.txt, so users do not need to configure its proguard manually. However, we would like to still obfuscate classes used with Butter Knife. So we provide an extension for such scenario.
mess {
ignoreProguard 'com.jakewharton:butterknife'
}
If you are using AAPT2, please disable AAPT2 by setting android.enableAapt2=false
in your gradle.properties file.
As a result, the Butter Knife's proguard configuration will be ignored. And those activities, views, fragments will be obfuscated by Mess.
That's all, just simple as that
As almost every Android project uses Butter Knife for view injection. And Butter Knife has its own proguard rules which keeps every class using Butter Knife. As as result, almost every android activity, fragment, custom view would be kept. And out Mess plugin is useless.
But good news is that we studied Butter Knife source code and figured it out. And the solution is also a gradle plugin ButterMess which has been a submodule of this project.