Skip to content

Commit

Permalink
[Feature] Add Firebase.
Browse files Browse the repository at this point in the history
  • Loading branch information
zhanghai committed May 17, 2019
1 parent d83e362 commit dbe3f52
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/build.gradle
Expand Up @@ -54,6 +54,7 @@ dependencies {
implementation "androidx.lifecycle:lifecycle-common-java8:2.0.0"
implementation 'androidx.appcompat:appcompat:1.0.2'
implementation 'com.google.android.material:material:1.1.0-alpha06'
implementation 'com.google.firebase:firebase-core:16.0.9'
debugImplementation 'com.facebook.stetho:stetho:1.5.0'
// If added along with okhttp3, remove the related dontwarn from proguard-rules.pro.
//debugImplementation 'com.facebook.stetho:stetho-okhttp3:1.5.0'
Expand All @@ -79,3 +80,5 @@ dependencies {
implementation 'org.apache.commons:commons-text:1.3'
implementation 'org.greenrobot:eventbus:3.1.1'
}

apply plugin: 'com.google.gms.google-services'
40 changes: 40 additions & 0 deletions app/google-services.json
@@ -0,0 +1,40 @@
{
"project_info": {
"project_number": "728501351509",
"firebase_url": "https://zhanghai-materialfiles.firebaseio.com",
"project_id": "zhanghai-materialfiles",
"storage_bucket": "zhanghai-materialfiles.appspot.com"
},
"client": [
{
"client_info": {
"mobilesdk_app_id": "1:728501351509:android:007cb5eb181702a9",
"android_client_info": {
"package_name": "me.zhanghai.android.files"
}
},
"oauth_client": [
{
"client_id": "728501351509-3ul5c5u8jpd9q9gi4e7537bd31r5nkr5.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [
{
"current_key": "AIzaSyDUcQAOKRcCjsA-e5-cZHbt4HQQFDP4wA4"
}
],
"services": {
"appinvite_service": {
"other_platform_oauth_client": [
{
"client_id": "728501351509-3ul5c5u8jpd9q9gi4e7537bd31r5nkr5.apps.googleusercontent.com",
"client_type": 3
}
]
}
}
}
],
"configuration_version": "1"
}
1 change: 1 addition & 0 deletions app/src/main/AndroidManifest.xml
Expand Up @@ -11,6 +11,7 @@
package="me.zhanghai.android.files">

<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />

Expand Down
1 change: 1 addition & 0 deletions build.gradle
Expand Up @@ -12,6 +12,7 @@ buildscript {
}
dependencies {
classpath 'com.android.tools.build:gradle:3.4.1'
classpath 'com.google.gms:google-services:4.2.0'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
Expand Down

0 comments on commit dbe3f52

Please sign in to comment.