gpt4 book ai didi

android - 将 twitter-kit 添加到 android studio 项目

转载 作者:塔克拉玛干 更新时间:2023-11-01 21:20:57 26 4
gpt4 key购买 nike

我正在尝试将启用使用 Twitter 登录添加到我的应用程序。我正在关注 this手册,以便这样做。当我在将这些行添加到依赖项后尝试同步 gradle 时:

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

(正如他们在其网站上所指示的那样)我收到此 gradle 错误:

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

我该如何解决这个问题?

最佳答案

您需要在 build.gradle 的顶部添加 Fabric - 您可能已经有了 apply plugin: 'com.android.application' 行,只需将所有这些东西放在它的位置即可。

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' }
}

但这只是一个障碍 - 接下来您将必须对 Fabric 本身进行身份验证。基本上,您从错误的地方开始 - Twitter 希望您从转到 https://get.fabric.io/ 开始并将 Fabric 集成到您的工作流程中。

关于android - 将 twitter-kit 添加到 android studio 项目,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29363372/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com