Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Adding twitter-kit to android studio project

I am trying to add enable logging in with twitter to my application. I am following this manual in order to do so. When I'm trying to sync the gradle after adding to the dependencies these lines:

compile('com.twitter.sdk.android:twitter:1.3.2@aar') {
    transitive = true;
}

(as they instruct in their website) I recieve this gradle error:

Failed to resolve: com.twitter.sdk.android:twitter:1.3.2

How can I fix this issue?

like image 438
Yuval Avatar asked Mar 31 '15 07:03

Yuval


1 Answers

You need to add Fabric at the top of your build.gradle - you probably already have the apply plugin: 'com.android.application' line, just put all of this stuff in its place.

buildscript {
  repositories {
    maven { url 'https://maven.fabric.io/repo' }
  }
  dependencies {
    classpath 'io.fabric.tools:gradle:1.+'
  }
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
repositories {
  maven { url 'https://maven.fabric.io/repo' }
}

But this is just one hurdle - next you're going to have to authenticate to Fabric itself. Basically, you started in the wrong place - Twitter wants you to start by going to https://get.fabric.io/ and integrating Fabric into your workflow.

like image 162
kodi Avatar answered Sep 22 '22 04:09

kodi