├── .github
└── ISSUE_TEMPLATE.md
├── .gitignore
├── CHANGELOG.md
├── LICENSE
├── README.md
├── app
├── .gitignore
├── build.gradle
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── com
│ │ └── blankj
│ │ └── freeproguard
│ │ └── MainActivity.java
│ └── res
│ ├── drawable-v24
│ └── ic_launcher_foreground.xml
│ ├── drawable
│ └── ic_launcher_background.xml
│ ├── layout
│ └── activity_main.xml
│ ├── mipmap-anydpi-v26
│ ├── ic_launcher.xml
│ └── ic_launcher_round.xml
│ ├── mipmap-hdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-mdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xxhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ ├── mipmap-xxxhdpi
│ ├── ic_launcher.png
│ └── ic_launcher_round.png
│ └── values
│ ├── colors.xml
│ ├── strings.xml
│ └── styles.xml
├── art
└── logo.png
├── build.gradle
├── free-proguard
├── .gitignore
├── bintrayUpload.gradle
├── build.gradle
├── proguard-ARouter.pro
├── proguard-AliPay.pro
├── proguard-AndFix.pro
├── proguard-AndroidCommon.pro
├── proguard-AndroidEventBus.pro
├── proguard-AndroidUniversalImageLoader.pro
├── proguard-BaiduMap.pro
├── proguard-BaseRecyclerViewAdapterHelper.pro
├── proguard-Bugly.pro
├── proguard-ButterKnife.pro
├── proguard-Dagger.pro
├── proguard-EventBus.pro
├── proguard-Fastjson.pro
├── proguard-Fresco.pro
├── proguard-GaoDeMap.pro
├── proguard-Getui.pro
├── proguard-Glide.pro
├── proguard-GreenDAO.pro
├── proguard-Gson.pro
├── proguard-Guava.pro
├── proguard-Ijkplayer.pro
├── proguard-ImmersionBar.pro
├── proguard-JPush.pro
├── proguard-Jackson.pro
├── proguard-KotlinxCoroutines.pro
├── proguard-LitePal.pro
├── proguard-Mars.pro
├── proguard-MiPush.pro
├── proguard-Nuwa.pro
├── proguard-OkHttp.pro
├── proguard-PingPlusPlus.pro
├── proguard-Realm.pro
├── proguard-Retrofit.pro
├── proguard-Retrolambda.pro
├── proguard-RongCloud.pro
├── proguard-RxJava.pro
├── proguard-ShareSDK.pro
├── proguard-SinaWeiboSDK.pro
├── proguard-Stetho.pro
├── proguard-Tencent.pro
├── proguard-UMeng.pro
├── proguard-UnionPay.pro
├── proguard-Volley.pro
├── proguard-XinGe.pro
├── proguard-XunFei.pro
├── proguard-ZXing.pro
├── proguard-push.pro
├── proguard-xUtils.pro
├── project.properties
└── src
│ └── main
│ └── AndroidManifest.xml
├── gradle.properties
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
└── settings.gradle
/.github/ISSUE_TEMPLATE.md:
--------------------------------------------------------------------------------
1 | # 这里输入库地址
2 | ```
3 | 这里输入防混淆配置
4 | ```
5 |
6 |
7 | 请删除本行及之后内容:
8 |
9 | 感谢您对 [FreeProGuard](https://github.com/Blankj/FreeProGuard) 的支持。
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | *.iml
2 | .gradle
3 | /.idea
4 | /local.properties
5 | .DS_Store
6 | /build
7 | /captures
8 | .externalNativeBuild
9 |
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | * `19/11/30` 跟新 GreenDao 和 Push 混淆,发布 1.0.2
2 | * `19/05/15` 修复 `-keep class * implements java.lang.annotation.Annotation`,发布 1.0.1
3 | * `19/03/26` 修复未混淆类名的问题,发布 1.0.0
4 | * `19/03/08` 去除中文,适配 androidx,发布 0.0.12
5 | * `19/02/26` 新增 KotlinxCoroutines,发布 0.0.11
6 | * `18/12/12` 新增 ImmersionBar,发布 0.0.10
7 | * `18/11/25` 修复 typo,发布 0.0.9
8 | * `18/09/04` 新增 xUtils3,发布 0.0.8
9 | * `18/08/31` 去除 `-dontshrink`、`-dontoptimize`,发布 0.0.7
10 | * `18/08/30` 新增 AndFix、AndroidUniversalImageLoader、ARouter、Ijkplayer、Mars、Nuwa、PingPlusPlus、ShareSDK、UnionPay、Volley、XinGe、XunFei、ZXing,发布 0.0.6
11 | * `18/08/29` 开源到 GitHub
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Apache License
2 | Version 2.0, January 2004
3 | http://www.apache.org/licenses/
4 |
5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6 |
7 | 1. Definitions.
8 |
9 | "License" shall mean the terms and conditions for use, reproduction,
10 | and distribution as defined by Sections 1 through 9 of this document.
11 |
12 | "Licensor" shall mean the copyright owner or entity authorized by
13 | the copyright owner that is granting the License.
14 |
15 | "Legal Entity" shall mean the union of the acting entity and all
16 | other entities that control, are controlled by, or are under common
17 | control with that entity. For the purposes of this definition,
18 | "control" means (i) the power, direct or indirect, to cause the
19 | direction or management of such entity, whether by contract or
20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the
21 | outstanding shares, or (iii) beneficial ownership of such entity.
22 |
23 | "You" (or "Your") shall mean an individual or Legal Entity
24 | exercising permissions granted by this License.
25 |
26 | "Source" form shall mean the preferred form for making modifications,
27 | including but not limited to software source code, documentation
28 | source, and configuration files.
29 |
30 | "Object" form shall mean any form resulting from mechanical
31 | transformation or translation of a Source form, including but
32 | not limited to compiled object code, generated documentation,
33 | and conversions to other media types.
34 |
35 | "Work" shall mean the work of authorship, whether in Source or
36 | Object form, made available under the License, as indicated by a
37 | copyright notice that is included in or attached to the work
38 | (an example is provided in the Appendix below).
39 |
40 | "Derivative Works" shall mean any work, whether in Source or Object
41 | form, that is based on (or derived from) the Work and for which the
42 | editorial revisions, annotations, elaborations, or other modifications
43 | represent, as a whole, an original work of authorship. For the purposes
44 | of this License, Derivative Works shall not include works that remain
45 | separable from, or merely link (or bind by name) to the interfaces of,
46 | the Work and Derivative Works thereof.
47 |
48 | "Contribution" shall mean any work of authorship, including
49 | the original version of the Work and any modifications or additions
50 | to that Work or Derivative Works thereof, that is intentionally
51 | submitted to Licensor for inclusion in the Work by the copyright owner
52 | or by an individual or Legal Entity authorized to submit on behalf of
53 | the copyright owner. For the purposes of this definition, "submitted"
54 | means any form of electronic, verbal, or written communication sent
55 | to the Licensor or its representatives, including but not limited to
56 | communication on electronic mailing lists, source code control systems,
57 | and issue tracking systems that are managed by, or on behalf of, the
58 | Licensor for the purpose of discussing and improving the Work, but
59 | excluding communication that is conspicuously marked or otherwise
60 | designated in writing by the copyright owner as "Not a Contribution."
61 |
62 | "Contributor" shall mean Licensor and any individual or Legal Entity
63 | on behalf of whom a Contribution has been received by Licensor and
64 | subsequently incorporated within the Work.
65 |
66 | 2. Grant of Copyright License. Subject to the terms and conditions of
67 | this License, each Contributor hereby grants to You a perpetual,
68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69 | copyright license to reproduce, prepare Derivative Works of,
70 | publicly display, publicly perform, sublicense, and distribute the
71 | Work and such Derivative Works in Source or Object form.
72 |
73 | 3. Grant of Patent License. Subject to the terms and conditions of
74 | this License, each Contributor hereby grants to You a perpetual,
75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76 | (except as stated in this section) patent license to make, have made,
77 | use, offer to sell, sell, import, and otherwise transfer the Work,
78 | where such license applies only to those patent claims licensable
79 | by such Contributor that are necessarily infringed by their
80 | Contribution(s) alone or by combination of their Contribution(s)
81 | with the Work to which such Contribution(s) was submitted. If You
82 | institute patent litigation against any entity (including a
83 | cross-claim or counterclaim in a lawsuit) alleging that the Work
84 | or a Contribution incorporated within the Work constitutes direct
85 | or contributory patent infringement, then any patent licenses
86 | granted to You under this License for that Work shall terminate
87 | as of the date such litigation is filed.
88 |
89 | 4. Redistribution. You may reproduce and distribute copies of the
90 | Work or Derivative Works thereof in any medium, with or without
91 | modifications, and in Source or Object form, provided that You
92 | meet the following conditions:
93 |
94 | (a) You must give any other recipients of the Work or
95 | Derivative Works a copy of this License; and
96 |
97 | (b) You must cause any modified files to carry prominent notices
98 | stating that You changed the files; and
99 |
100 | (c) You must retain, in the Source form of any Derivative Works
101 | that You distribute, all copyright, patent, trademark, and
102 | attribution notices from the Source form of the Work,
103 | excluding those notices that do not pertain to any part of
104 | the Derivative Works; and
105 |
106 | (d) If the Work includes a "NOTICE" text file as part of its
107 | distribution, then any Derivative Works that You distribute must
108 | include a readable copy of the attribution notices contained
109 | within such NOTICE file, excluding those notices that do not
110 | pertain to any part of the Derivative Works, in at least one
111 | of the following places: within a NOTICE text file distributed
112 | as part of the Derivative Works; within the Source form or
113 | documentation, if provided along with the Derivative Works; or,
114 | within a display generated by the Derivative Works, if and
115 | wherever such third-party notices normally appear. The contents
116 | of the NOTICE file are for informational purposes only and
117 | do not modify the License. You may add Your own attribution
118 | notices within Derivative Works that You distribute, alongside
119 | or as an addendum to the NOTICE text from the Work, provided
120 | that such additional attribution notices cannot be construed
121 | as modifying the License.
122 |
123 | You may add Your own copyright statement to Your modifications and
124 | may provide additional or different license terms and conditions
125 | for use, reproduction, or distribution of Your modifications, or
126 | for any such Derivative Works as a whole, provided Your use,
127 | reproduction, and distribution of the Work otherwise complies with
128 | the conditions stated in this License.
129 |
130 | 5. Submission of Contributions. Unless You explicitly state otherwise,
131 | any Contribution intentionally submitted for inclusion in the Work
132 | by You to the Licensor shall be under the terms and conditions of
133 | this License, without any additional terms or conditions.
134 | Notwithstanding the above, nothing herein shall supersede or modify
135 | the terms of any separate license agreement you may have executed
136 | with Licensor regarding such Contributions.
137 |
138 | 6. Trademarks. This License does not grant permission to use the trade
139 | names, trademarks, service marks, or product names of the Licensor,
140 | except as required for reasonable and customary use in describing the
141 | origin of the Work and reproducing the content of the NOTICE file.
142 |
143 | 7. Disclaimer of Warranty. Unless required by applicable law or
144 | agreed to in writing, Licensor provides the Work (and each
145 | Contributor provides its Contributions) on an "AS IS" BASIS,
146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147 | implied, including, without limitation, any warranties or conditions
148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149 | PARTICULAR PURPOSE. You are solely responsible for determining the
150 | appropriateness of using or redistributing the Work and assume any
151 | risks associated with Your exercise of permissions under this License.
152 |
153 | 8. Limitation of Liability. In no event and under no legal theory,
154 | whether in tort (including negligence), contract, or otherwise,
155 | unless required by applicable law (such as deliberate and grossly
156 | negligent acts) or agreed to in writing, shall any Contributor be
157 | liable to You for damages, including any direct, indirect, special,
158 | incidental, or consequential damages of any character arising as a
159 | result of this License or out of the use or inability to use the
160 | Work (including but not limited to damages for loss of goodwill,
161 | work stoppage, computer failure or malfunction, or any and all
162 | other commercial damages or losses), even if such Contributor
163 | has been advised of the possibility of such damages.
164 |
165 | 9. Accepting Warranty or Additional Liability. While redistributing
166 | the Work or Derivative Works thereof, You may choose to offer,
167 | and charge a fee for, acceptance of support, warranty, indemnity,
168 | or other liability obligations and/or rights consistent with this
169 | License. However, in accepting such obligations, You may act only
170 | on Your own behalf and on Your sole responsibility, not on behalf
171 | of any other Contributor, and only if You agree to indemnify,
172 | defend, and hold each Contributor harmless for any liability
173 | incurred by, or claims asserted against, such Contributor by reason
174 | of your accepting any such warranty or additional liability.
175 |
176 | END OF TERMS AND CONDITIONS
177 |
178 | APPENDIX: How to apply the Apache License to your work.
179 |
180 | To apply the Apache License to your work, attach the following
181 | boilerplate notice, with the fields enclosed by brackets "{}"
182 | replaced with your own identifying information. (Don't include
183 | the brackets!) The text should be enclosed in the appropriate
184 | comment syntax for the file format. We also recommend that a
185 | file or class name and description of purpose be included on the
186 | same "printed page" as the copyright notice for easier
187 | identification within third-party archives.
188 |
189 | Copyright 2018 Blankj
190 |
191 | Licensed under the Apache License, Version 2.0 (the "License");
192 | you may not use this file except in compliance with the License.
193 | You may obtain a copy of the License at
194 |
195 | http://www.apache.org/licenses/LICENSE-2.0
196 |
197 | Unless required by applicable law or agreed to in writing, software
198 | distributed under the License is distributed on an "AS IS" BASIS,
199 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200 | See the License for the specific language governing permissions and
201 | limitations under the License.
202 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ![logo][logo]
2 |
3 | [![fpg][fpgsvg]][fpg] [![License][licensesvg]][license]
4 |
5 |
6 | ## About
7 |
8 | **[FreeProGuard][readme]** 为方便广大 Android 开发者们今后防混淆配置,很久之前便有打算做这个免混淆库了,只是拖到最近才有空来实现该库,该库利用了 `consumerProguardFiles` 来传递 aar 中的防混淆配置到主工程中,所以依赖了该库后常用的主流三方库便不再需要开发者们手动配置了,当然,有些友善的库已采用了该方式,我也希望更多的开源库使用该方式从而省去开发者配置防混淆,本库已配置了如下防混淆文件(包括库的不同版本):
9 |
10 | * [AndroidCommon][AndroidCommon]
11 | * [AliPay][AliPay](需防混 jar(-libraryjars libs/alipaySDK-20150602.jar))
12 | * [AndFix][AndFix]
13 | * [AndroidEventBus][AndroidEventBus]
14 | * [AndroidUniversalImageLoader][AndroidUniversalImageLoader]
15 | * [ARouter][ARouter]
16 | * [BaiduMap][BaiduMap](需防混 jar(-libraryjars libs/baidumapapi_v2_1_2.jar))
17 | * [BaseRecyclerViewAdapterHelper][BaseRecyclerViewAdapterHelper]
18 | * [Bugly][Bugly]
19 | * [ButterKnife][ButterKnife]
20 | * [Dagger][Dagger]
21 | * [EventBus][EventBus]
22 | * [Fastjson][Fastjson]
23 | * [Fresco][Fresco]
24 | * [GaoDeMap][GaoDeMap]
25 | * [Getui][Getui]
26 | * [Glide][Glide]
27 | * [GreenDAO][GreenDAO]
28 | * [Gson][Gson]
29 | * [Ijkplayer][Ijkplayer]
30 | * [ImmersionBar][ImmersionBar]
31 | * [Guava][Guava]
32 | * [Jackson][Jackson]
33 | * [JPush][JPush]
34 | * [KotlinxCoroutines][KotlinxCoroutines]
35 | * [LitePal][LitePal]
36 | * [Mars][Mars]
37 | * [MiPush][MiPush]
38 | * [Nuwa][Nuwa]
39 | * [OkHttp][OkHttp]
40 | * [PingPlusPlus][PingPlusPlus]
41 | * [Realm][Realm]
42 | * [Retrofit][Retrofit]
43 | * [Retrolambda][Retrolambda]
44 | * [RongCloud][RongCloud]
45 | * [RxJava][RxJava]
46 | * [ShareSDK][ShareSDK]
47 | * [SinaWeiboSDK][SinaWeiboSDK]
48 | * [Stetho][Stetho]
49 | * [Tencent][Tencent]
50 | * [UMeng][UMeng]
51 | * [UnionPay][UnionPay]
52 | * [Volley][Volley]
53 | * [XinGe][XinGe]
54 | * [XunFei][XunFei]
55 | * [ZXing][ZXing]
56 |
57 |
58 | ## How to use
59 |
60 | 1. 首先开启混淆,设置 `minifyEnabled true`;
61 | 2. 添加依赖:
62 | ```groovy
63 | implementation "com.blankj:free-proguard:1.0.2"
64 | ```
65 | 3. 把项目中的实体类加入到 `proguard-rules.pro` 文件中,一般为 `-keep class urpackage.xx.bean/entity/model.** { *; }`,或者使用 `@Keep` 注解这些实体类;
66 | 4. 把项目中需要防混淆的 jar 加入到 `proguard-rules.pro` 文件中,比如支付宝 SDK 的 `-libraryjars libs/alipaySDK-20150602.jar`,如果要对所有 jar 都防混,那么使用 `-libraryjars libs` 即可;
67 | 5. 把项目中用到的一些不包括在如上列表中的三方库配置到 `proguard-rules.pro` 文件中,或者[提 issue](https://github.com/Blankj/FreeProGuard/issues/new) 使其加入到本库中来(小众或者冷门的不予合入哦)。
68 |
69 |
70 | ## Profit
71 |
72 | 1. 开启混淆会将代码中的所有变量、函数、类的名称变为简短的英文字母代号(也可自定义),在缺乏相应的函数名和程序注释的情况下,即使被反编译,也将难以阅读,提升应用的安全性;
73 | 2. 混淆通过分析字节码,去掉冗余代码,再加上缩短了变量、函数、类的名称,可以进一步缩减应用大小,如果想混淆资源文件,可以使用微信的 [AndResGuard](https://github.com/shwenzhang/AndResGuard)。
74 |
75 |
76 | ## Last but not least
77 |
78 | 如果该库能为你节省 10 分钟甚至更多的时间,请把它分享给他人来帮助更多的开发者们节省时间,这些时间可以多陪伴家人、多运动、多做自己喜欢的事情,希望开源可以帮助到更多的人,也希望更多的人加入到开源中来。
79 |
80 |
81 | ## [ChangeLog](https://github.com/Blankj/FreeProGuard/blob/master/CHANGELOG.md)
82 |
83 |
84 | ## 打个小广告
85 |
86 | 欢迎加入我的小专栏「**[基你太美](https://xiaozhuanlan.com/Blankj)**」一起学习。
87 |
88 |
89 |
90 | [logo]: https://raw.githubusercontent.com/Blankj/FreeProGuard/master/art/logo.png
91 |
92 | [fpgsvg]: https://img.shields.io/badge/FreeProGuard-v1.0.2-brightgreen.svg
93 | [fpg]: https://github.com/Blankj/FreeProGuard
94 |
95 | [licensesvg]: https://img.shields.io/badge/License-Apache--2.0-brightgreen.svg
96 | [license]: https://github.com/Blankj/AndroidUtilCode/blob/master/LICENSE
97 |
98 | [readme]: https://github.com/Blankj/FreeProGuard
99 |
100 | [AndroidCommon]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AndroidCommon.pro
101 | [AliPay]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AliPay.pro
102 | [AndFix]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AndFix.pro
103 | [AndroidEventBus]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AndroidEventBus.pro
104 | [AndroidUniversalImageLoader]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AndroidUniversalImageLoader.pro
105 | [ARouter]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-AndroidEventBus.pro
106 | [BaiduMap]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-BaiduMap.pro
107 | [BaseRecyclerViewAdapterHelper]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-BaseRecyclerViewAdapterHelper.pro
108 | [Bugly]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Bugly.pro
109 | [ButterKnife]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-ButterKnife.pro
110 | [Dagger]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Dagger.pro
111 | [EventBus]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-EventBus.pro
112 | [Fastjson]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Fastjson.pro
113 | [Fresco]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Fresco.pro
114 | [GaoDeMap]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-GaoDeMap.pro
115 | [Getui]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Getui.pro
116 | [Glide]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Glide.pro
117 | [GreenDAO]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-GreenDAO.pro
118 | [Gson]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Gson.pro
119 | [Guava]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Guava.pro
120 | [Ijkplayer]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Ijkplayer.pro
121 | [ImmersionBar]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-ImmersionBar.pro
122 | [Jackson]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Jackson.pro
123 | [JPush]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-JPush.pro
124 | [KotlinxCoroutines]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-KotlinxCoroutines.pro
125 | [LitePal]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-LitePal.pro
126 | [Mars]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Mars.pro
127 | [MiPush]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-MiPush.pro
128 | [Nuwa]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Nuwa.pro
129 | [OkHttp]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-OkHttp.pro
130 | [PingPlusPlus]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-PingPlusPlus.pro
131 | [Realm]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Realm.pro
132 | [Retrofit]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Retrofit.pro
133 | [Retrolambda]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Retrolambda.pro
134 | [RongCloud]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-RongCloud.pro
135 | [RxJava]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-RxJava.pro
136 | [ShareSDK]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-ShareSDK.pro
137 | [SinaWeiboSDK]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-SinaWeiboSDK.pro
138 | [Stetho]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Stetho.pro
139 | [Tencent]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Tencent.pro
140 | [UMeng]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-UMeng.pro
141 | [UnionPay]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-UnionPay.pro
142 | [Volley]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-Volley.pro
143 | [XinGe]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-XinGe.pro
144 | [XunFei]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-XunFei.pro
145 | [ZXing]: https://github.com/Blankj/FreeProGuard/blob/master/free-proguard/proguard-ZXing.pro
146 |
--------------------------------------------------------------------------------
/app/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/app/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 28
5 | defaultConfig {
6 | applicationId 'com.blankj.freeproguard'
7 | minSdkVersion 14
8 | targetSdkVersion 28
9 | versionCode 1
10 | versionName "1.0"
11 | }
12 | buildTypes {
13 | release {
14 | minifyEnabled false
15 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
16 | }
17 | }
18 | productFlavors {
19 |
20 | }
21 | }
22 |
23 | dependencies {
24 | implementation fileTree(include: ['*.jar'], dir: 'libs')
25 | implementation 'com.android.support:appcompat-v7:28.0.0-rc02'
26 | implementation 'com.android.support.constraint:constraint-layout:1.1.3'
27 | }
28 |
--------------------------------------------------------------------------------
/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # You can control the set of applied configuration files using the
3 | # proguardFiles setting in build.gradle.
4 | #
5 | # For more details, see
6 | # http://developer.android.com/guide/developing/tools/proguard.html
7 |
8 | # If your project uses WebView with JS, uncomment the following
9 | # and specify the fully qualified class name to the JavaScript interface
10 | # class:
11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
12 | # public *;
13 | #}
14 |
15 | # Uncomment this to preserve the line number information for
16 | # debugging stack traces.
17 | #-keepattributes SourceFile,LineNumberTable
18 |
19 | # If you keep the line number information, uncomment this to
20 | # hide the original source file name.
21 | #-renamesourcefileattribute SourceFile
22 |
--------------------------------------------------------------------------------
/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/app/src/main/java/com/blankj/freeproguard/MainActivity.java:
--------------------------------------------------------------------------------
1 | package com.blankj.freeproguard;
2 |
3 | import android.support.v7.app.AppCompatActivity;
4 | import android.os.Bundle;
5 |
6 | public class MainActivity extends AppCompatActivity {
7 |
8 | @Override
9 | protected void onCreate(Bundle savedInstanceState) {
10 | super.onCreate(savedInstanceState);
11 | setContentView(R.layout.activity_main);
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/app/src/main/res/drawable-v24/ic_launcher_foreground.xml:
--------------------------------------------------------------------------------
1 |
7 |
12 |
13 |
19 |
22 |
25 |
26 |
27 |
28 |
34 |
35 |
--------------------------------------------------------------------------------
/app/src/main/res/drawable/ic_launcher_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
10 |
15 |
20 |
25 |
30 |
35 |
40 |
45 |
50 |
55 |
60 |
65 |
70 |
75 |
80 |
85 |
90 |
95 |
100 |
105 |
110 |
115 |
120 |
125 |
130 |
135 |
140 |
145 |
150 |
155 |
160 |
165 |
170 |
171 |
--------------------------------------------------------------------------------
/app/src/main/res/layout/activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
14 |
15 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-hdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-mdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/app/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 |
7 |
--------------------------------------------------------------------------------
/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | FreeProGuard
3 |
4 |
--------------------------------------------------------------------------------
/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/art/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/art/logo.png
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 |
3 | buildscript {
4 |
5 | repositories {
6 | google()
7 | jcenter()
8 | }
9 | dependencies {
10 | classpath 'com.android.tools.build:gradle:3.1.4'
11 |
12 | // NOTE: Do not place your application dependencies here; they belong
13 | // in the individual module build.gradle files
14 | }
15 | }
16 |
17 | allprojects {
18 | repositories {
19 | google()
20 | jcenter()
21 | }
22 | }
23 |
24 | task clean(type: Delete) {
25 | delete rootProject.buildDir
26 | }
27 |
28 | ext {
29 | versionCode = 1_000_002
30 | versionName = '1.0.2'
31 | }
32 | //./gradlew bintrayUpload
--------------------------------------------------------------------------------
/free-proguard/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 | local.properties
--------------------------------------------------------------------------------
/free-proguard/bintrayUpload.gradle:
--------------------------------------------------------------------------------
1 |
2 | apply plugin: 'com.github.dcendents.android-maven'
3 | apply plugin: 'com.jfrog.bintray'
4 |
5 | // load properties
6 | Properties properties = new Properties()
7 | File localPropertiesFile = project.file("local.properties");
8 | if(localPropertiesFile.exists()){
9 | properties.load(localPropertiesFile.newDataInputStream())
10 | }
11 | File projectPropertiesFile = project.file("project.properties");
12 | if(projectPropertiesFile.exists()){
13 | properties.load(projectPropertiesFile.newDataInputStream())
14 | }
15 |
16 | // read properties
17 | def projectName = properties.getProperty("project.name")
18 | def projectGroupId = properties.getProperty("project.groupId")
19 | def projectArtifactId = properties.getProperty("project.artifactId")
20 | def projectVersionName = android.defaultConfig.versionName
21 | def projectPackaging = properties.getProperty("project.packaging")
22 | def projectSiteUrl = properties.getProperty("project.siteUrl")
23 | def projectGitUrl = properties.getProperty("project.gitUrl")
24 |
25 | def developerId = properties.getProperty("developer.id")
26 | def developerName = properties.getProperty("developer.name")
27 | def developerEmail = properties.getProperty("developer.email")
28 |
29 | def bintrayUser = properties.getProperty("bintray.user")
30 | def bintrayApikey = properties.getProperty("bintray.apikey")
31 |
32 | def javadocName = properties.getProperty("javadoc.name")
33 |
34 | group = projectGroupId
35 |
36 | // This generates POM.xml with proper parameters
37 | install {
38 | repositories.mavenInstaller {
39 | pom {
40 | project {
41 | name projectName
42 | groupId projectGroupId
43 | artifactId projectArtifactId
44 | version projectVersionName
45 | packaging projectPackaging
46 | url projectSiteUrl
47 | licenses {
48 | license {
49 | name 'The Apache Software License, Version 2.0'
50 | url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
51 | }
52 | }
53 | developers {
54 | developer {
55 | id developerId
56 | name developerName
57 | email developerEmail
58 | }
59 | }
60 | scm {
61 | connection projectGitUrl
62 | developerConnection projectGitUrl
63 | url projectSiteUrl
64 | }
65 | }
66 | }
67 | }
68 | }
69 |
70 | // This generates sources.jar
71 | task sourcesJar(type: Jar) {
72 | from android.sourceSets.main.java.srcDirs
73 | classifier = 'sources'
74 | }
75 |
76 | task javadoc(type: Javadoc) {
77 | source = android.sourceSets.main.java.srcDirs
78 | classpath += project.files(android.getBootClasspath().join(File.pathSeparator))
79 | }
80 |
81 | // This generates javadoc.jar
82 | task javadocJar(type: Jar, dependsOn: javadoc) {
83 | classifier = 'javadoc'
84 | from javadoc.destinationDir
85 | }
86 |
87 | artifacts {
88 | archives javadocJar
89 | archives sourcesJar
90 | }
91 |
92 | // javadoc configuration
93 | javadoc {
94 | options{
95 | encoding "UTF-8"
96 | charSet 'UTF-8'
97 | author true
98 | version projectVersionName
99 | links "http://docs.oracle.com/javase/7/docs/api"
100 | title javadocName
101 | }
102 | }
103 |
104 | // bintray configuration
105 | bintray {
106 | user = bintrayUser
107 | key = bintrayApikey
108 | configurations = ['archives']
109 | pkg {
110 | repo = "maven"
111 | name = projectName
112 | websiteUrl = projectSiteUrl
113 | vcsUrl = projectGitUrl
114 | licenses = ["Apache-2.0"]
115 | publish = true
116 | }
117 | }
--------------------------------------------------------------------------------
/free-proguard/build.gradle:
--------------------------------------------------------------------------------
1 | plugins {
2 | id "com.android.library"
3 | id "com.github.dcendents.android-maven" version "2.1"
4 | id "com.jfrog.bintray" version "1.8.0"
5 | }
6 |
7 | android {
8 | compileSdkVersion 27
9 |
10 | defaultConfig {
11 | minSdkVersion 14
12 | versionCode rootProject.versionCode
13 | versionName rootProject.versionName
14 | }
15 |
16 | buildTypes {
17 | release {
18 | consumerProguardFiles file('.').listFiles(new FilenameFilter() {
19 | @Override
20 | boolean accept(File file, String s) {
21 | return s.endsWith('.pro')
22 | }
23 | })
24 | }
25 | }
26 | }
27 |
28 | apply from: "bintrayUpload.gradle"
--------------------------------------------------------------------------------
/free-proguard/proguard-ARouter.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/alibaba/ARouter
2 | -keep public class com.alibaba.android.arouter.routes.** { *; }
3 | -keep public class com.alibaba.android.arouter.facade.** { *; }
4 | -keep class * implements com.alibaba.android.arouter.facade.template.ISyringe { *; }
5 |
6 | # If you use the byType method to obtain Service, add the following rules to protect the interface:
7 | -keep interface * implements com.alibaba.android.arouter.facade.template.IProvider
8 |
9 | # If single-type injection is used, that is, no interface is defined to implement IProvider, the following rules need to be added to protect the implementation
10 | -keep class * implements com.alibaba.android.arouter.facade.template.IProvider
11 |
--------------------------------------------------------------------------------
/free-proguard/proguard-AliPay.pro:
--------------------------------------------------------------------------------
1 | # https://docs.open.alipay.com/59/103683/
2 | #-libraryjars libs/alipaySDK-20150602.jar
3 |
4 | -keep class com.alipay.android.app.IAlixPay { *; }
5 | -keep class com.alipay.android.app.IAlixPay$Stub { *; }
6 | -keep class com.alipay.android.app.IRemoteServiceCallback { *; }
7 | -keep class com.alipay.android.app.IRemoteServiceCallback$Stub { *; }
8 | -keep class com.alipay.sdk.app.PayTask { public *; }
9 | -keep class com.alipay.sdk.app.AuthTask { public *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-AndFix.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/alibaba/AndFix
2 | -keep class * implements java.lang.annotation.Annotation
3 | -keepclasseswithmembernames class * {
4 | native ;
5 | }
6 | -keep class com.alipay.euler.andfix.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-AndroidCommon.pro:
--------------------------------------------------------------------------------
1 | #############################################
2 | #
3 | # 对于一些基本指令的添加
4 | #
5 | #############################################
6 | # 代码混淆压缩比,在 0~7 之间,默认为 5,一般不做修改
7 | -optimizationpasses 5
8 |
9 | # 混合时不使用大小写混合,混合后的类名为小写
10 | -dontusemixedcaseclassnames
11 |
12 | # 指定不去忽略非公共库的类
13 | -dontskipnonpubliclibraryclasses
14 |
15 | # 这句话能够使我们的项目混淆后产生映射文件
16 | # 包含有类名->混淆后类名的映射关系
17 | -verbose
18 |
19 | # 指定不去忽略非公共库的类成员
20 | -dontskipnonpubliclibraryclassmembers
21 |
22 | # 不做预校验,preverify 是 proguard 的四个步骤之一,Android 不需要 preverify,去掉这一步能够加快混淆速度。
23 | -dontpreverify
24 |
25 | # 保留 Annotation 不混淆
26 | -keepattributes *Annotation*,InnerClasses
27 |
28 | # 避免混淆泛型
29 | -keepattributes Signature
30 |
31 | # 抛出异常时保留代码行号
32 | -keepattributes SourceFile,LineNumberTable
33 |
34 | # 指定混淆是采用的算法,后面的参数是一个过滤器
35 | # 这个过滤器是谷歌推荐的算法,一般不做更改
36 | -optimizations !code/simplification/cast,!field/*,!class/merging/*
37 |
38 |
39 | #############################################
40 | #
41 | # Android开发中一些需要保留的公共部分
42 | #
43 | #############################################
44 |
45 | # 保留我们使用的四大组件,自定义的 Application 等等这些类不被混淆
46 | # 因为这些子类都有可能被外部调用
47 | -keep public class * extends android.app.Activity
48 | -keep public class * extends android.app.Appliction
49 | -keep public class * extends android.app.Service
50 | -keep public class * extends android.content.BroadcastReceiver
51 | -keep public class * extends android.content.ContentProvider
52 | -keep public class * extends android.app.backup.BackupAgentHelper
53 | -keep public class * extends android.preference.Preference
54 | -keep public class * extends android.view.View
55 | -keep public class com.android.vending.licensing.ILicensingService
56 |
57 |
58 | # 保留 support 下的所有类及其内部类
59 | -keep class android.support.** { *; }
60 |
61 | # 保留继承的
62 | -keep public class * extends android.support.v4.**
63 | -keep public class * extends android.support.v7.**
64 | -keep public class * extends android.support.annotation.**
65 |
66 | # 保留 R 下面的资源
67 | -keep class **.R$* { *; }
68 |
69 | # 保留本地 native 方法不被混淆
70 | -keepclasseswithmembernames class * {
71 | native ;
72 | }
73 |
74 | # 保留在 Activity 中的方法参数是view的方法,
75 | # 这样以来我们在 layout 中写的 onClick 就不会被影响
76 | -keepclassmembers class * extends android.app.Activity {
77 | public void *(android.view.View);
78 | }
79 |
80 | # 保留枚举类不被混淆
81 | -keepclassmembers enum * {
82 | public static **[] values();
83 | public static ** valueOf(java.lang.String);
84 | }
85 |
86 | # 保留我们自定义控件(继承自 View)不被混淆
87 | -keep public class * extends android.view.View {
88 | *** get*();
89 | void set*(***);
90 | public (android.content.Context);
91 | public (android.content.Context, android.util.AttributeSet);
92 | public (android.content.Context, android.util.AttributeSet, int);
93 | }
94 |
95 | # 保留 Parcelable 序列化类不被混淆
96 | -keep class * implements android.os.Parcelable {
97 | public static final android.os.Parcelable$Creator *;
98 | }
99 |
100 | # 保留 Serializable 序列化的类不被混淆
101 | -keepnames class * implements java.io.Serializable
102 | -keepclassmembers class * implements java.io.Serializable {
103 | static final long serialVersionUID;
104 | private static final java.io.ObjectStreamField[] serialPersistentFields;
105 | !static !transient ;
106 | !private ;
107 | !private ;
108 | private void writeObject(java.io.ObjectOutputStream);
109 | private void readObject(java.io.ObjectInputStream);
110 | java.lang.Object writeReplace();
111 | java.lang.Object readResolve();
112 | }
113 |
114 | # 对于带有回调函数的 onXXEvent、**On*Listener 的,不能被混淆
115 | -keepclassmembers class * {
116 | void *(**On*Event);
117 | void *(**On*Listener);
118 | }
119 |
120 | # webView 处理,项目中没有使用到 webView 忽略即可
121 | -keepclassmembers class fqcn.of.javascript.interface.for.webview {
122 | public *;
123 | }
124 | -keepclassmembers class * extends android.webkit.webViewClient {
125 | public void *(android.webkit.WebView, java.lang.String, android.graphics.Bitmap);
126 | public boolean *(android.webkit.WebView, java.lang.String);
127 | }
128 | -keepclassmembers class * extends android.webkit.webViewClient {
129 | public void *(android.webkit.webView, java.lang.String);
130 | }
131 |
132 | # js
133 | -keepattributes JavascriptInterface
134 | -keep class android.webkit.JavascriptInterface { *; }
135 | -keepclassmembers class * {
136 | @android.webkit.JavascriptInterface ;
137 | }
138 |
139 | # @Keep
140 | -keep,allowobfuscation @interface android.support.annotation.Keep
141 | -keep @android.support.annotation.Keep class *
142 | -keepclassmembers class * {
143 | @android.support.annotation.Keep *;
144 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-AndroidEventBus.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/hehonghui/AndroidEventBus
2 | -keep class org.simple.** { *; }
3 | -keep interface org.simple.** { *; }
4 | -keepclassmembers class * {
5 | @org.simple.eventbus.Subscriber ;
6 | }
7 | -keepattributes *Annotation*
--------------------------------------------------------------------------------
/free-proguard/proguard-AndroidUniversalImageLoader.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/nostra13/Android-Universal-Image-Loader
2 | -dontwarn com.nostra13.universalimageloader.**
3 | -keep class com.nostra13.universalimageloader.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-BaiduMap.pro:
--------------------------------------------------------------------------------
1 | # http://lbsyun.baidu.com/index.php?title=androidsdk/qa
2 | -keep class com.baidu.** { *; }
3 | -keep class vi.com.gdi.bgl.android.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-BaseRecyclerViewAdapterHelper.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/CymChad/BaseRecyclerViewAdapterHelper
2 | -keep class com.chad.library.adapter.** { *; }
3 | -keep public class * extends com.chad.library.adapter.base.BaseQuickAdapter
4 | -keep public class * extends com.chad.library.adapter.base.BaseViewHolder
5 | -keepclassmembers class **$** extends com.chad.library.adapter.base.BaseViewHolder {
6 | (...);
7 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-Bugly.pro:
--------------------------------------------------------------------------------
1 | # https://bugly.qq.com/docs/user-guide/instruction-manual-android/
2 | -dontwarn com.tencent.bugly.**
3 | -keep public class com.tencent.bugly.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-ButterKnife.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/JakeWharton/butterknife/blob/81a8c70a41f86a066335d6d818aee6d17ec87ac5/butterknife/proguard-rules.txt
2 | -keep public class * implements butterknife.Unbinder { public (**, android.view.View); }
3 | -keep class butterknife.*
4 | -keepclasseswithmembernames class * { @butterknife.* ; }
5 | -keepclasseswithmembernames class * { @butterknife.* ; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Dagger.pro:
--------------------------------------------------------------------------------
1 | # dagger
2 | -dontwarn dagger.internal.codegen.**
3 | -keepclassmembers,allowobfuscation class * {
4 | @javax.inject.* *;
5 | @dagger.* *;
6 | ();
7 | }
8 |
9 | -keep class dagger.* { *; }
10 | -keep class javax.inject.* { *; }
11 | -keep class * extends dagger.internal.Binding
12 | -keep class * extends dagger.internal.ModuleAdapter
13 | -keep class * extends dagger.internal.StaticInjection
14 |
15 | # dagger2
16 | # https://github.com/google/dagger/issues/645
17 | -dontwarn com.google.errorprone.annotations.*
--------------------------------------------------------------------------------
/free-proguard/proguard-EventBus.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/greenrobot/EventBus
2 |
3 | # EventBus2
4 | -keepclassmembers class ** {
5 | public void onEvent*(***);
6 | }
7 |
8 | # Only required if you use AsyncExecutor
9 | -keepclassmembers class * extends de.greenrobot.event.util.ThrowableFailureEvent {
10 | public (java.lang.Throwable);
11 | }
12 |
13 | # EventBus3
14 | # http://greenrobot.org/eventbus/documentation/proguard
15 | # Don't warn for missing support classes
16 | -dontwarn de.greenrobot.event.util.*$Support
17 | -dontwarn de.greenrobot.event.util.*$SupportManagerFragment
18 |
19 | -keepattributes *Annotation*
20 | -keepclassmembers class * {
21 | @org.greenrobot.eventbus.Subscribe ;
22 | }
23 | -keep enum org.greenrobot.eventbus.ThreadMode { *; }
24 |
25 | # Only required if you use AsyncExecutor
26 | -keepclassmembers class * extends org.greenrobot.eventbus.util.ThrowableFailureEvent {
27 | (java.lang.Throwable);
28 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-Fastjson.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/alibaba/fastjson
2 | -dontwarn com.alibaba.fastjson.**
3 | -keepattributes Signature
4 | -keepattributes *Annotation*
--------------------------------------------------------------------------------
/free-proguard/proguard-Fresco.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/facebook/fresco/blob/307f996e34a2665df0f1b714a660c6cd4254835b/fbcore/proguard-fresco.pro
2 | # Keep our interfaces so they can be used by other ProGuard rules.
3 | # See http://sourceforge.net/p/proguard/bugs/466/
4 | -keep,allowobfuscation @interface com.facebook.common.internal.DoNotStrip
5 | -keep,allowobfuscation @interface com.facebook.soloader.DoNotOptimize
6 |
7 | # Do not strip any method/class that is annotated with @DoNotStrip
8 | -keep @com.facebook.common.internal.DoNotStrip class *
9 | -keepclassmembers class * {
10 | @com.facebook.common.internal.DoNotStrip *;
11 | }
12 |
13 | # Do not strip any method/class that is annotated with @DoNotOptimize
14 | -keep @com.facebook.soloader.DoNotOptimize class *
15 | -keepclassmembers class * {
16 | @com.facebook.soloader.DoNotOptimize *;
17 | }
18 |
19 | # Keep native methods
20 | -keepclassmembers class * {
21 | native ;
22 | }
23 |
24 | -dontwarn okio.**
25 | -dontwarn com.squareup.okhttp.**
26 | -dontwarn okhttp3.**
27 | -dontwarn javax.annotation.**
28 | -dontwarn com.android.volley.toolbox.**
29 | -dontwarn com.facebook.infer.**
--------------------------------------------------------------------------------
/free-proguard/proguard-GaoDeMap.pro:
--------------------------------------------------------------------------------
1 | # https://lbs.amap.com/api/android-location-sdk/guide/create-project/dev-attention
2 | # 3D 地图 V5.0.0之前:
3 | -keep class com.amap.api.maps.** { *; }
4 | -keep class com.autonavi.amap.mapcore.* { *; }
5 | -keep class com.amap.api.trace.** { *; }
6 |
7 | # 3D 地图 V5.0.0之后:
8 | -keep class com.amap.api.maps.** { *; }
9 | -keep class com.autonavi.** { *; }
10 | -keep class com.amap.api.trace.** { *; }
11 |
12 | # 定位
13 | -keep class com.amap.api.location.** { *; }
14 | -keep class com.amap.api.fence.** { *; }
15 | -keep class com.autonavi.aps.amapapi.model.** { *; }
16 |
17 | # 搜索
18 | -keep class com.amap.api.services.** { *; }
19 |
20 | # 2D地图
21 | -keep class com.amap.api.maps2d.** { *; }
22 | -keep class com.amap.api.mapcore2d.** { *; }
23 |
24 | # 导航
25 | -keep class com.amap.api.navi.** { *; }
26 | -keep class com.autonavi.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Getui.pro:
--------------------------------------------------------------------------------
1 | # http://docs.getui.com/getui/mobile/android/androidstudio/
2 | -dontwarn com.igexin.**
3 | -keep class com.igexin.** { *; }
4 | -keep class org.json.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Glide.pro:
--------------------------------------------------------------------------------
1 | # https://proguard-rules.blogspot.com/2017/05/glide-proguard-rules.html
2 | -keep public class * implements com.bumptech.glide.module.GlideModule
3 | -keep public enum com.bumptech.glide.load.resource.bitmap.ImageHeaderParser$** {
4 | **[] $VALUES;
5 | public *;
6 | }
7 |
8 | # for DexGuard only
9 | #-keepresourcexmlelements manifest/application/meta-data@value=GlideModule
10 |
11 | # https://github.com/bumptech/glide/blob/master/library/proguard-rules.txt
12 | -keep public class * extends com.bumptech.glide.module.AppGlideModule
13 | -keep public enum com.bumptech.glide.load.ImageHeaderParser$** {
14 | **[] $VALUES;
15 | public *;
16 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-GreenDAO.pro:
--------------------------------------------------------------------------------
1 | # Source: http://greendao-orm.com/documentation/technical-faq
2 | ### greenDAO 3
3 | -keepclassmembers class * extends org.greenrobot.greendao.AbstractDao {
4 | public static java.lang.String TABLENAME;
5 | }
6 | -keep class **$Properties
7 |
8 | # If you do not use SQLCipher:
9 | -dontwarn org.greenrobot.greendao.database.**
10 | # If you do not use RxJava:
11 | -dontwarn rx.**
12 |
13 | ### greenDAO 2
14 | -keepclassmembers class * extends de.greenrobot.dao.AbstractDao {
15 | public static java.lang.String TABLENAME;
16 | }
17 | -keep class **$Properties
18 |
19 | -keep class **$Properties { *; }
20 |
21 | # If you do not use SQLCipher:
22 | -dontwarn net.sqlcipher.database.**
23 | # If you do not use RxJava:
24 | -dontwarn rx.**
--------------------------------------------------------------------------------
/free-proguard/proguard-Gson.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/google/gson/blob/master/examples/android-proguard-example/proguard.cfg
2 | -keepattributes Signature
3 | -keepattributes *Annotation*
4 | -dontwarn sun.misc.**
5 | -keep class com.google.gson.stream.** { *; }
6 | -keep class * implements com.google.gson.TypeAdapterFactory
7 | -keep class * implements com.google.gson.JsonSerializer
8 | -keep class * implements com.google.gson.JsonDeserializer
--------------------------------------------------------------------------------
/free-proguard/proguard-Guava.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/google/guava
2 | -keep class com.google.common.io.Resources {
3 | public static ;
4 | }
5 | -keep class com.google.common.collect.Lists {
6 | public static ** reverse(**);
7 | }
8 | -keep class com.google.common.base.Charsets {
9 | public static ;
10 | }
11 |
12 | -keep class com.google.common.base.Joiner {
13 | public static com.google.common.base.Joiner on(java.lang.String);
14 | public ** join(...);
15 | }
16 |
17 | -keep class com.google.common.collect.MapMakerInternalMap$ReferenceEntry
18 | -keep class com.google.common.cache.LocalCache$ReferenceEntry
19 |
20 | # https://stackoverflow.com/a/50338429/287575
21 | # 25.0-android
22 | -dontwarn afu.org.checkerframework.**
23 | -dontwarn org.checkerframework.**
24 | -dontwarn com.google.errorprone.**
25 | -dontwarn sun.misc.Unsafe
26 | -dontwarn java.lang.ClassValue
27 | -dontwarn javax.inject.**
28 |
29 | # Guava 19.0
30 | -dontwarn com.google.j2objc.annotations.Weak
31 | -dontwarn org.codehaus.mojo.animal_sniffer.IgnoreJRERequirement
32 |
--------------------------------------------------------------------------------
/free-proguard/proguard-Ijkplayer.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/Bilibili/ijkplayer
2 | -keep class tv.danmaku.ijk.media.player.** { *; }
3 | -keep class tv.danmaku.ijk.media.player.IjkMediaPlayer { *; }
4 | -keep class tv.danmaku.ijk.media.player.ffmpeg.FFmpegApi { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-ImmersionBar.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/gyf-dev/ImmersionBar
2 | -keep class com.gyf.barlibrary.* { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-JPush.pro:
--------------------------------------------------------------------------------
1 | # https://docs.jiguang.cn/jpush/client/Android/android_guide/
2 | #-dontoptimize
3 | #-dontpreverify
4 |
5 | -dontwarn cn.jpush.**
6 | -keep class cn.jpush.** { *; }
7 | -keep class * extends cn.jpush.android.helpers.JPushMessageReceiver { *; }
8 |
9 | -dontwarn cn.jiguang.**
10 | -keep class cn.jiguang.** { *; }
11 |
12 | #==================gson && protobuf==========================
13 | -dontwarn com.google.**
14 | -keep class com.google.gson.** { *; }
15 | -keep class com.google.protobuf.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Jackson.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/FasterXML/jackson-docs/wiki/JacksonOnAndroid
2 | # Jackson
3 | -keep @com.fasterxml.jackson.annotation.JsonIgnoreProperties class * { *; }
4 | -keep @com.fasterxml.jackson.annotation.JsonCreator class * { *; }
5 | -keep @com.fasterxml.jackson.annotation.JsonValue class * { *; }
6 | -keep class com.fasterxml.** { *; }
7 | -keep class org.codehaus.** { *; }
8 | -keepnames class com.fasterxml.jackson.** { *; }
9 | -keepclassmembers public final enum com.fasterxml.jackson.annotation.JsonAutoDetect$Visibility {
10 | public static final com.fasterxml.jackson.annotation.JsonAutoDetect$Visibility *;
11 | }
12 |
13 | # General
14 | -keepattributes SourceFile,LineNumberTable,*Annotation*,EnclosingMethod,Signature,Exceptions,InnerClasses
15 |
16 | # Proguard configuration for Jackson 2.x
17 | -keep class com.fasterxml.jackson.databind.ObjectMapper {
18 | public ;
19 | protected ;
20 | }
21 | -keep class com.fasterxml.jackson.databind.ObjectWriter {
22 | public ** writeValueAsString(**);
23 | }
24 | -keepnames class com.fasterxml.jackson.** { *; }
25 | -dontwarn com.fasterxml.jackson.databind.**
26 |
27 | # Proguard configuration for Jackson 2.x
28 | -dontwarn com.fasterxml.jackson.databind.**
29 | -keepclassmembers class * {
30 | @com.fasterxml.jackson.annotation.* *;
31 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-KotlinxCoroutines.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/Kotlin/kotlinx.coroutines
2 | -keepnames class kotlinx.coroutines.internal.MainDispatcherFactory {}
3 | -keepnames class kotlinx.coroutines.CoroutineExceptionHandler {}
4 | -keepnames class kotlinx.coroutines.android.AndroidExceptionPreHandler {}
5 | -keepnames class kotlinx.coroutines.android.AndroidDispatcherFactory {}
6 |
7 | -keepclassmembernames class kotlinx.** {
8 | volatile ;
9 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-LitePal.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/LitePalFramework/LitePal#proguard
2 | -keep class org.litepal.** { *; }
3 | -keep class * extends org.litepal.crud.DataSupport { *; }
4 | -keep class * extends org.litepal.crud.LitePalSupport { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Mars.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/Tencent/mars/wiki/Mars-%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98#debug%E7%89%88%E6%9C%AC%E4%B8%8B%E6%B2%A1%E9%97%AE%E9%A2%98release%E7%89%88%E6%9C%AC%E4%B8%8B%E6%8A%A5-javalangunsatisfiedlinkerror
2 | -keep class com.tencent.mars.** {
3 | public protected private *;
4 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-MiPush.pro:
--------------------------------------------------------------------------------
1 | # https://dev.mi.com/doc/tag=%E6%8E%A8%E9%80%81%E6%9C%8D%E5%8A%A1/index.html
2 | -keepclasseswithmembernames class com.xiaomi.** { *; }
3 | -keep public class * extends com.xiaomi.mipush.sdk.PushMessageReceiver
4 | -dontwarn com.xiaomi.push.service.a.a
--------------------------------------------------------------------------------
/free-proguard/proguard-Nuwa.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/jasonross/Nuwa#proguard
2 | -keep class cn.jiajixin.nuwa.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-OkHttp.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/square/okhttp
2 | # okhttp
3 | -keepattributes Signature
4 | -keepattributes *Annotation*
5 | -keep class com.squareup.okhttp.* { *; }
6 | -keep interface com.squareup.okhttp.** { *; }
7 | -dontwarn com.squareup.okhttp.**
8 |
9 | # okhttp 3
10 | -keepattributes Signature
11 | -keepattributes *Annotation*
12 | -keep class okhttp3.** { *; }
13 | -keep interface okhttp3.** { *; }
14 | -dontwarn okhttp3.**
15 |
16 | # Okio
17 | -dontwarn com.squareup.**
18 | -dontwarn okio.**
19 | -keep public class org.codehaus.* { *; }
20 | -keep public class java.nio.* { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-PingPlusPlus.pro:
--------------------------------------------------------------------------------
1 | # https://www.pingxx.com/docs/client/android
2 | # Ping++ 混淆过滤
3 | -dontwarn com.pingplusplus.**
4 | -keep class com.pingplusplus.** {*;}
5 |
6 | # 支付宝混淆过滤
7 | -dontwarn com.alipay.**
8 | -keep class com.alipay.** {*;}
9 |
10 | # 微信或QQ钱包混淆过滤
11 | -dontwarn com.tencent.**
12 | -keep class com.tencent.** {*;}
13 |
14 | # 银联支付混淆过滤
15 | -dontwarn com.unionpay.**
16 | -keep class com.unionpay.** {*;}
17 |
18 | # 招行一网通混淆过滤
19 | -keepclasseswithmembers class cmb.pb.util.CMBKeyboardFunc {
20 | public (android.app.Activity);
21 | public boolean HandleUrlCall(android.webkit.WebView,java.lang.String);
22 | public void callKeyBoardActivity();
23 | }
24 |
25 | # 内部WebView混淆过滤
26 | -keepclassmembers class * {
27 | @android.webkit.JavascriptInterface ;
28 | }
--------------------------------------------------------------------------------
/free-proguard/proguard-Realm.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/realm/realm-java/issues/4909
2 | -keep class io.realm.annotations.RealmModule
3 | -keep @io.realm.annotations.RealmModule class *
4 | -keep class io.realm.internal.Keep
5 | -keep @io.realm.internal.Keep class *
6 | -dontwarn javax.**
7 | -dontwarn io.realm.**
8 | -keepnames public class * extends io.realm.RealmObject
9 | -keep public class * extends io.realm.RealmObject { *; }
10 |
11 | # the version of now needn't config proguard
--------------------------------------------------------------------------------
/free-proguard/proguard-Retrofit.pro:
--------------------------------------------------------------------------------
1 | # https://square.github.io/retrofit
2 | # Retrofit
3 | -dontwarn retrofit.**
4 | -keep class retrofit.** { *; }
5 | -keepattributes Signature
6 | -keepattributes Exceptions
7 |
8 | # Retrofit2
9 | -keep class retrofit2.** { *; }
10 | -dontwarn retrofit2.**
11 | -keepattributes Signature
12 | -keepattributes Exceptions
13 | -dontwarn okio.**
14 | -dontwarn javax.annotation.**
--------------------------------------------------------------------------------
/free-proguard/proguard-Retrolambda.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/evant/gradle-retrolambda#proguard
2 | -dontwarn java.lang.invoke.*
3 | -dontwarn **$$Lambda$*
--------------------------------------------------------------------------------
/free-proguard/proguard-RongCloud.pro:
--------------------------------------------------------------------------------
1 | # http://www.rongcloud.cn/docs/android.html
2 | -keepattributes Signature
3 |
4 | # RongCloud SDK
5 | -keep class io.rong.** { *; }
6 | -keep class * implements io.rong.imlib.model.MessageContent { *; }
7 | -dontwarn io.rong.push.**
8 | -dontnote com.xiaomi.**
9 | -dontnote com.google.android.gms.gcm.**
10 | -dontnote io.rong.**
11 |
12 | # VoIP
13 | -keep class io.agora.rtc.** { *; }
14 |
15 | # Location
16 | -keep class com.amap.api.** { *; }
17 | -keep class com.amap.api.services.** { *; }
18 |
19 | # 红包
20 | -keep class com.google.gson.** { *; }
21 | -keep class com.uuhelper.Application.** { *; }
22 | -keep class net.sourceforge.zbar.** { *; }
23 | -keep class com.google.android.gms.** { *; }
24 | -keep class com.alipay.** { *; }
25 | -keep class com.jrmf360.rylib.** { *; }
26 |
27 | -ignorewarnings
28 |
29 | -keep public class * extends **.PushMessageReceiver
30 |
--------------------------------------------------------------------------------
/free-proguard/proguard-RxJava.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/artem-zinnatullin/RxJavaProGuardRules/blob/master/rxjava-proguard-rules/proguard-rules.txt
2 | -dontwarn sun.misc.**
3 | -keepclassmembers class rx.internal.util.unsafe.*ArrayQueue*Field* {
4 | long producerIndex;
5 | long consumerIndex;
6 | }
7 | -keepclassmembers class rx.internal.util.unsafe.BaseLinkedQueueProducerNodeRef {
8 | rx.internal.util.atomic.LinkedQueueNode producerNode;
9 | }
10 | -keepclassmembers class rx.internal.util.unsafe.BaseLinkedQueueConsumerNodeRef {
11 | rx.internal.util.atomic.LinkedQueueNode consumerNode;
12 | }
13 | -dontnote rx.internal.util.PlatformDependent
--------------------------------------------------------------------------------
/free-proguard/proguard-ShareSDK.pro:
--------------------------------------------------------------------------------
1 | # http://wiki.mob.com/sdk-share-android-3-0-0/
2 | -keep class cn.sharesdk.** { *; }
3 | -keep class com.sina.** { *; }
4 | -keep class **.R$* { *; }
5 | -keep class **.R { *; }
6 | -keep class com.mob.** { *; }
7 | -keep class m.framework.** { *; }
8 | -dontwarn cn.sharesdk.**
9 | -dontwarn com.sina.**
10 | -dontwarn com.mob.**
11 | -dontwarn **.R$*
--------------------------------------------------------------------------------
/free-proguard/proguard-SinaWeiboSDK.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/sinaweibosdk/weibo_android_sdk
2 | -keep class com.sina.weibo.sdk.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-Stetho.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/facebook/stetho/blob/master/stetho/proguard-consumer.pro
2 | -keep class com.facebook.stetho.** { *; }
3 | -dontwarn com.facebook.stetho.**
--------------------------------------------------------------------------------
/free-proguard/proguard-Tencent.pro:
--------------------------------------------------------------------------------
1 | # https://mta.qq.com/docs/app_Android_introduction.html
2 | -keep class com.tencent.stat.** { *; }
3 | -keep class com.tencent.mid.** { *; }
4 |
5 | -keep class com.tencent.mm.opensdk.** { *; }
6 | -keep class com.tencent.wxop.** { *; }
7 | -keep class com.tencent.mm.sdk.** { *; }
8 |
9 |
10 | # http://wiki.open.qq.com/wiki/mobile/Android_SDK%E4%BD%BF%E7%94%A8%E8%AF%B4%E6%98%8E#4.6.09.E6.B7.B7.E6.B7.86.E8.AF.B4.E6.98.8E
11 | -keep class com.tencent.open.TDialog$*
12 | -keep class com.tencent.open.TDialog$* { *; }
13 | -keep class com.tencent.open.PKDialog
14 | -keep class com.tencent.open.PKDialog { *; }
15 | -keep class com.tencent.open.PKDialog$*
16 | -keep class com.tencent.open.PKDialog$* { *; }
17 |
18 |
19 | # http://lbs.qq.com/android_v1/guide-project-setup.html
20 | -keep class com.tencent.mapsdk.** { *; }
21 | -keep class com.tencent.tencentmap.** { *; }
22 |
23 | -keep class com.tencent.tencentmap.** { *; }
24 | -keep class com.tencent.map.** { *; }
25 | -keep class com.tencent.beacontmap.** { *; }
26 | -keep class navsns.** { *; }
27 | -dontwarn com.qq.**
28 | -dontwarn com.tencent.beacon.**
29 |
30 | -keep class com.tencent.lbssearch.** { *; }
31 | -keepattributes Signature
32 | -dontwarn com.tencent.lbssearch.**
33 |
34 | -keep class com.tencent.tencentmap.streetviewsdk.** { *; }
35 |
36 | # https://cloud.tencent.com/document/product/269/9227
37 | -keep class com.tencent.** { *; }
38 | -dontwarn com.tencent.**
39 |
40 | -keep class tencent.** { *; }
41 | -dontwarn tencent.**
42 |
43 | -keep class qalsdk.** { *; }
44 | -dontwarn qalsdk.**
--------------------------------------------------------------------------------
/free-proguard/proguard-UMeng.pro:
--------------------------------------------------------------------------------
1 | # https://developer.umeng.com/docs/66632/detail/66889
2 | -keep class com.umeng.** { *; }
3 | -keepclassmembers class * {
4 | public (org.json.JSONObject);
5 | }
6 | -keepclassmembers enum * {
7 | public static **[] values();
8 | public static ** valueOf(java.lang.String);
9 | }
10 |
11 |
12 | # https://developer.umeng.com/docs/66632/detail/66744
13 | -dontwarn com.umeng.**
14 | -dontwarn com.taobao.**
15 | -dontwarn anet.channel.**
16 | -dontwarn anetwork.channel.**
17 | -dontwarn org.android.**
18 | -dontwarn org.apache.thrift.**
19 | -dontwarn com.xiaomi.**
20 | -dontwarn com.huawei.**
21 | -dontwarn com.meizu.**
22 |
23 | -keepattributes *Annotation*
24 |
25 | -keep class com.taobao.** { *; }
26 | -keep class org.android.** { *; }
27 | -keep class anet.channel.** { *; }
28 | -keep class com.umeng.** { *; }
29 | -keep class com.xiaomi.** { *; }
30 | -keep class com.huawei.** { *; }
31 | -keep class com.meizu.** { *; }
32 | -keep class org.apache.thrift.** { *; }
33 |
34 | -keep class com.alibaba.sdk.android.** { *; }
35 | -keep class com.ut.** { *; }
36 | -keep class com.ta.** { *; }
37 |
38 | -keep public class **.R$* {
39 | public static final int *;
40 | }
41 |
42 | # https://developer.umeng.com/docs/66632/detail/66639
43 | #-dontshrink
44 | #-dontoptimize
45 | -dontwarn com.google.android.maps.**
46 | -dontwarn android.webkit.WebView
47 | -dontwarn com.umeng.**
48 | -dontwarn com.tencent.weibo.sdk.**
49 | -dontwarn com.facebook.**
50 | -keep public class javax.**
51 | -keep public class android.webkit.**
52 | -dontwarn android.support.v4.**
53 | -keep enum com.facebook.**
54 | -keepattributes Exceptions,InnerClasses,Signature
55 | -keepattributes *Annotation*
56 | -keepattributes SourceFile,LineNumberTable
57 |
58 | -keep public interface com.facebook.**
59 | -keep public interface com.tencent.**
60 | -keep public interface com.umeng.socialize.**
61 | -keep public interface com.umeng.socialize.sensor.**
62 | -keep public interface com.umeng.scrshot.**
63 |
64 | -keep public class com.umeng.socialize.* { *; }
65 |
66 |
67 | -keep class com.facebook.**
68 | -keep class com.facebook.** { *; }
69 | -keep class com.umeng.scrshot.**
70 | -keep public class com.tencent.** { *; }
71 | -keep class com.umeng.socialize.sensor.**
72 | -keep class com.umeng.socialize.handler.**
73 | -keep class com.umeng.socialize.handler.*
74 | -keep class com.umeng.weixin.handler.**
75 | -keep class com.umeng.weixin.handler.*
76 | -keep class com.umeng.qq.handler.**
77 | -keep class com.umeng.qq.handler.*
78 | -keep class UMMoreHandler { *; }
79 | -keep class com.tencent.mm.sdk.modelmsg.WXMediaMessage { *; }
80 | -keep class com.tencent.mm.sdk.modelmsg.** implements com.tencent.mm.sdk.modelmsg.WXMediaMessage$IMediaObject { *; }
81 | -keep class im.yixin.sdk.api.YXMessage { *; }
82 | -keep class im.yixin.sdk.api.** implements im.yixin.sdk.api.YXMessage$YXMessageData { *; }
83 | -keep class com.tencent.mm.sdk.** {
84 | *;
85 | }
86 | -keep class com.tencent.mm.opensdk.** {
87 | *;
88 | }
89 | -keep class com.tencent.wxop.** {
90 | *;
91 | }
92 | -keep class com.tencent.mm.sdk.** {
93 | *;
94 | }
95 | -dontwarn twitter4j.**
96 | -keep class twitter4j.** { *; }
97 |
98 | -keep class com.tencent.** { *; }
99 | -dontwarn com.tencent.**
100 | -keep class com.kakao.** { *; }
101 | -dontwarn com.kakao.**
102 | -keep public class com.umeng.com.umeng.soexample.R$*{
103 | public static final int *;
104 | }
105 | -keep public class com.linkedin.android.mobilesdk.R$*{
106 | public static final int *;
107 | }
108 | -keepclassmembers enum * {
109 | public static **[] values();
110 | public static ** valueOf(java.lang.String);
111 | }
112 |
113 | -keep class com.tencent.open.TDialog$*
114 | -keep class com.tencent.open.TDialog$* { *; }
115 | -keep class com.tencent.open.PKDialog
116 | -keep class com.tencent.open.PKDialog { *; }
117 | -keep class com.tencent.open.PKDialog$*
118 | -keep class com.tencent.open.PKDialog$* { *; }
119 | -keep class com.umeng.socialize.impl.ImageImpl { *; }
120 | -keep class com.sina.** { *; }
121 | -dontwarn com.sina.**
122 | -keep class com.alipay.share.sdk.** {
123 | *;
124 | }
125 |
126 | -keepnames class * implements android.os.Parcelable {
127 | public static final ** CREATOR;
128 | }
129 |
130 | -keep class com.linkedin.** { *; }
131 | -keep class com.android.dingtalk.share.ddsharemodule.** { *; }
132 | -keepattributes Signature
--------------------------------------------------------------------------------
/free-proguard/proguard-UnionPay.pro:
--------------------------------------------------------------------------------
1 | # https://open.unionpay.com/ajweb/help/faq/list?id=241&level=0&from=0
2 | -keep class org.simalliance.openmobileapi.** {*;}
3 | -keep class org.simalliance.openmobileapi.service.** {*;}
4 | -keep class com.unionpay.** {*;}
--------------------------------------------------------------------------------
/free-proguard/proguard-Volley.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/google/volley
2 | -keep class com.android.volley.** { *; }
3 | -keep class com.android.volley.toolbox.** { *; }
4 | -keep class com.android.volley.Response$* { *; }
5 | -keep class com.android.volley.Request$* { *; }
6 | -keep class com.android.volley.RequestQueue$* { *; }
7 | -keep class com.android.volley.toolbox.HurlStack$* { *; }
8 | -keep class com.android.volley.toolbox.ImageLoader$* { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-XinGe.pro:
--------------------------------------------------------------------------------
1 | # http://developer.qq.com/wiki/xg/Android%E6%8E%A5%E5%85%A5/Android%20SDK%E5%BF%AB%E9%80%9F%E6%8E%A5%E5%85%A5/Android%20SDK%E5%BF%AB%E9%80%9F%E6%8E%A5%E5%85%A5.html
2 | -keep public class * extends android.app.Service
3 | -keep public class * extends android.content.BroadcastReceiver
4 | -keep class com.tencent.android.tpush.** { *; }
5 | -keep class com.tencent.mid.** { *; }
6 | -keep public class * extends com.qq.taf.jce.JceStruct { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-XunFei.pro:
--------------------------------------------------------------------------------
1 | # https://www.xfyun.cn/doccenter/awd
2 | -keep class com.iflytek.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-ZXing.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/zxing/zxing
2 | -dontwarn com.google.zxing.**
3 | -keep class com.google.zxing.** { *; }
--------------------------------------------------------------------------------
/free-proguard/proguard-push.pro:
--------------------------------------------------------------------------------
1 | # http://wiki.mob.com/mobpush-plugins-%E5%BF%AB%E9%80%9F%E9%9B%86%E6%88%90/
2 | -keep class com.huawei.** {*;}
3 | -keep class com.meizu.** {*;}
4 | -keep class com.xiaomi.** {*;}
5 | -keep class android.os.SystemProperties
6 | -keep class com.coloros.** {*;}
7 | -keep class com.google.** {*;}
8 | -keep class org.apache.thrift.** {*;}
9 |
10 | -dontwarn com.huawei.**
11 | -dontwarn com.meizu.**
12 | -dontwarn com.xiaomi.**
13 | -dontwarn android.os.SystemProperties
14 | -dontwarn com.coloros.**
15 | -dontwarn com.google.**
16 | -dontwarn org.apache.thrift.**
17 |
18 | -dontwarn com.vivo.push.**
19 | -keep class com.vivo.push.** {*;}
20 | -keep class com.vivo.vms.** {*;}
--------------------------------------------------------------------------------
/free-proguard/proguard-xUtils.pro:
--------------------------------------------------------------------------------
1 | # https://github.com/wyouflf/xUtils3
2 | -keep public class org.xutils.** {
3 | public protected *;
4 | }
5 | -keep public interface org.xutils.** {
6 | public protected *;
7 | }
8 | -keepclassmembers class * extends org.xutils.** {
9 | public protected *;
10 | }
11 | -keepclassmembers @org.xutils.db.annotation.* class * { *; }
12 | -keepclassmembers @org.xutils.http.annotation.* class * { *; }
13 | -keepclassmembers class * {
14 | @org.xutils.view.annotation.Event ;
15 | }
--------------------------------------------------------------------------------
/free-proguard/project.properties:
--------------------------------------------------------------------------------
1 | #project
2 | project.name=FreeProGuard
3 | project.groupId=com.blankj
4 | project.artifactId=free-proguard
5 | project.packaging=aar
6 | project.siteUrl=https://github.com/Blankj/FreeProGuard
7 | project.gitUrl=https://github.com/Blankj/FreeProGuard.git
8 |
9 | #javadoc
10 | javadoc.name=FreeProGuard
--------------------------------------------------------------------------------
/free-proguard/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 | # IDE (e.g. Android Studio) users:
3 | # Gradle settings configured through the IDE *will override*
4 | # any settings specified in this file.
5 | # For more details on how to configure your build environment visit
6 | # http://www.gradle.org/docs/current/userguide/build_environment.html
7 | # Specifies the JVM arguments used for the daemon process.
8 | # The setting is particularly useful for tweaking memory settings.
9 | org.gradle.jvmargs=-Xmx1536m
10 | # When configured, Gradle will run in incubating parallel mode.
11 | # This option should only be used with decoupled projects. More details, visit
12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
13 | # org.gradle.parallel=true
14 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Blankj/FreeProGuard/4a3a9de0f361751c6501cb87d89ea9ea5f97b945/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Sun Aug 26 15:58:28 CST 2018
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip
7 |
--------------------------------------------------------------------------------
/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Attempt to set APP_HOME
10 | # Resolve links: $0 may be a link
11 | PRG="$0"
12 | # Need this for relative symlinks.
13 | while [ -h "$PRG" ] ; do
14 | ls=`ls -ld "$PRG"`
15 | link=`expr "$ls" : '.*-> \(.*\)$'`
16 | if expr "$link" : '/.*' > /dev/null; then
17 | PRG="$link"
18 | else
19 | PRG=`dirname "$PRG"`"/$link"
20 | fi
21 | done
22 | SAVED="`pwd`"
23 | cd "`dirname \"$PRG\"`/" >/dev/null
24 | APP_HOME="`pwd -P`"
25 | cd "$SAVED" >/dev/null
26 |
27 | APP_NAME="Gradle"
28 | APP_BASE_NAME=`basename "$0"`
29 |
30 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
31 | DEFAULT_JVM_OPTS=""
32 |
33 | # Use the maximum available, or set MAX_FD != -1 to use that value.
34 | MAX_FD="maximum"
35 |
36 | warn () {
37 | echo "$*"
38 | }
39 |
40 | die () {
41 | echo
42 | echo "$*"
43 | echo
44 | exit 1
45 | }
46 |
47 | # OS specific support (must be 'true' or 'false').
48 | cygwin=false
49 | msys=false
50 | darwin=false
51 | nonstop=false
52 | case "`uname`" in
53 | CYGWIN* )
54 | cygwin=true
55 | ;;
56 | Darwin* )
57 | darwin=true
58 | ;;
59 | MINGW* )
60 | msys=true
61 | ;;
62 | NONSTOP* )
63 | nonstop=true
64 | ;;
65 | esac
66 |
67 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
68 |
69 | # Determine the Java command to use to start the JVM.
70 | if [ -n "$JAVA_HOME" ] ; then
71 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
72 | # IBM's JDK on AIX uses strange locations for the executables
73 | JAVACMD="$JAVA_HOME/jre/sh/java"
74 | else
75 | JAVACMD="$JAVA_HOME/bin/java"
76 | fi
77 | if [ ! -x "$JAVACMD" ] ; then
78 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
79 |
80 | Please set the JAVA_HOME variable in your environment to match the
81 | location of your Java installation."
82 | fi
83 | else
84 | JAVACMD="java"
85 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
86 |
87 | Please set the JAVA_HOME variable in your environment to match the
88 | location of your Java installation."
89 | fi
90 |
91 | # Increase the maximum file descriptors if we can.
92 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
93 | MAX_FD_LIMIT=`ulimit -H -n`
94 | if [ $? -eq 0 ] ; then
95 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
96 | MAX_FD="$MAX_FD_LIMIT"
97 | fi
98 | ulimit -n $MAX_FD
99 | if [ $? -ne 0 ] ; then
100 | warn "Could not set maximum file descriptor limit: $MAX_FD"
101 | fi
102 | else
103 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
104 | fi
105 | fi
106 |
107 | # For Darwin, add options to specify how the application appears in the dock
108 | if $darwin; then
109 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
110 | fi
111 |
112 | # For Cygwin, switch paths to Windows format before running java
113 | if $cygwin ; then
114 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
115 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
116 | JAVACMD=`cygpath --unix "$JAVACMD"`
117 |
118 | # We build the pattern for arguments to be converted via cygpath
119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120 | SEP=""
121 | for dir in $ROOTDIRSRAW ; do
122 | ROOTDIRS="$ROOTDIRS$SEP$dir"
123 | SEP="|"
124 | done
125 | OURCYGPATTERN="(^($ROOTDIRS))"
126 | # Add a user-defined pattern to the cygpath arguments
127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
129 | fi
130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
131 | i=0
132 | for arg in "$@" ; do
133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
135 |
136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
138 | else
139 | eval `echo args$i`="\"$arg\""
140 | fi
141 | i=$((i+1))
142 | done
143 | case $i in
144 | (0) set -- ;;
145 | (1) set -- "$args0" ;;
146 | (2) set -- "$args0" "$args1" ;;
147 | (3) set -- "$args0" "$args1" "$args2" ;;
148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
154 | esac
155 | fi
156 |
157 | # Escape application args
158 | save () {
159 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
160 | echo " "
161 | }
162 | APP_ARGS=$(save "$@")
163 |
164 | # Collect all arguments for the java command, following the shell quoting and substitution rules
165 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
166 |
167 | # by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
168 | if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
169 | cd "$(dirname "$0")"
170 | fi
171 |
172 | exec "$JAVACMD" "$@"
173 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | set DIRNAME=%~dp0
12 | if "%DIRNAME%" == "" set DIRNAME=.
13 | set APP_BASE_NAME=%~n0
14 | set APP_HOME=%DIRNAME%
15 |
16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
17 | set DEFAULT_JVM_OPTS=
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windows variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 |
53 | :win9xME_args
54 | @rem Slurp the command line arguments.
55 | set CMD_LINE_ARGS=
56 | set _SKIP=2
57 |
58 | :win9xME_args_slurp
59 | if "x%~1" == "x" goto execute
60 |
61 | set CMD_LINE_ARGS=%*
62 |
63 | :execute
64 | @rem Setup the command line
65 |
66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
67 |
68 | @rem Execute Gradle
69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
70 |
71 | :end
72 | @rem End local scope for the variables with windows NT shell
73 | if "%ERRORLEVEL%"=="0" goto mainEnd
74 |
75 | :fail
76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
77 | rem the _cmd.exe /c_ return code!
78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
79 | exit /b 1
80 |
81 | :mainEnd
82 | if "%OS%"=="Windows_NT" endlocal
83 |
84 | :omega
85 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app', ':free-proguard'
2 |
--------------------------------------------------------------------------------