Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What are the ProGuard rules for Firebase?

What are the ProGuard rules for these dependencies?

compile 'com.google.firebase:firebase-core:10.0.1'
compile 'com.google.firebase:firebase-crash:10.0.1'
compile 'com.google.firebase:firebase-messaging:10.0.1'
compile 'com.google.firebase:firebase-ads:10.0.1'
like image 254
Mi_Dhah Avatar asked Jan 08 '17 22:01

Mi_Dhah


People also ask

What are ProGuard rules?

ProGuard is a tool to help minify, obfuscate, and optimize your code. It is not only especially useful for reducing the overall size of your Android application as well as removing unused classes and methods that contribute towards the intrinsic 64k method limit of Android applications.

How do I connect apps with Firebase?

Open the Firebase Assistant: Tools > Firebase. In the Assistant pane, choose a Firebase product to add to your app. Expand its section, then click the tutorial link (for example, Analytics > Log an Analytics event). Click Connect to Firebase to connect your Android project with Firebase.


1 Answers

Firebase uses the consumerProguardFiles feature to automatically include the appropriate ProGuard if you're using Gradle, meaning you don't need to manually include anything.

If you need to manually apply the proguard rules, you can extract the proguard.txt file from each AAR file.

like image 147
ianhanniballake Avatar answered Sep 18 '22 15:09

ianhanniballake