简体   繁体   中英

Twitter Fabric integration plugin on android studio gradle (build failure)

I'm trying to implement twitter login on my app and followed the fabric tips but i get an error while building the app:

Error:Execution failed for task ':app:fabricGenerateResourcesDebug'. Crashlytics Developer Tools error.

here is my gradle file:

buildscript {
    repositories {
        maven { url 'https://maven.fabric.io/public' }
    }

    dependencies {
        classpath 'io.fabric.tools:gradle:1.+'
    }
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'

repositories {
    maven { url 'https://maven.fabric.io/public' }
}

android {
    compileSdkVersion 23
    buildToolsVersion '23.0.1'

    defaultConfig {
        applicationId "com.ntg.hatmaak"
        minSdkVersion 17
        targetSdkVersion 22
        versionCode 1
        versionName "1.0"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'),     'proguard-rules.pro'
        }
    }
} 

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    //    compile project(':facebook')
    compile 'de.hdodenhof:circleimageview:1.3.0'
    compile 'com.android.support:recyclerview-v7:+'
    compile 'com.facebook.android:facebook-android-sdk:4.6.0'
    compile 'com.github.marcohc:robotocalendarview:1.1.0'
    compile 'com.prolificinteractive:material-calendarview:0.8.1'
    //compile 'com.wrapp.floatlabelededittext:library:0.0.6'
    compile 'com.google.android.gms:play-services:7.5.0'
    compile 'com.daimajia.swipelayout:library:1.2.0@aar'
    compile 'com.android.support:appcompat-v7:23.1.0'
    compile 'com.android.support:cardview-v7:23.1.0'
    compile 'com.android.support:design:23.1.0'
    compile('com.twitter.sdk.android:twitter:1.8.0@aar') {
        transitive = true;
    }

}

Have you created a "fabric.properties" file which is required to contain API Key and Build Secret, in your app directory ?

Hope it helps.

Your manifest must contain an io.fabric.ApiKey

<meta-data
            android:name="io.fabric.ApiKey"
            android:value="--------------" /> 

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM