有人用Kinvey作为后端服务吗?我按照以下步骤设置它:http://devcenter.kinvey.com/android/guides/getting-started
当我将Kinvey添加到我的gradle文件中的依赖项时,我会得到一个语法错误,其状态是:未能解决:kinvey-android-*
这是我的build.gradle(Module:app)文件:
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
applicationId "com.markf.kinveytest"
minSdkVersion 15
targetSdkVersion 23
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}}
dependencies {
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.1.1'
compile fileTree(dir: 'libs', include: ['*.jar'])
compile(name:'kinvey-android-*', ext:'aar')}这是一个截图:

有人知道为什么吗?谢谢。
发布于 2016-03-25 06:26:38
我也面临着同样的问题,我刚刚找到了解决问题的方法。
1.转到您的项目文件夹/应用程序/libs
2.检查kinvey库的名称。在我的例子中,它是kinvey-android-2.10.5
3.将其添加到build.gradle文件中
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:23.1.1'
compile 'com.android.support:design:23.1.1'
compile(name:'kinvey-android-2.10.5', ext:'jar')
}发布于 2016-02-12 11:35:03
目前,您可以通过在build.gradle文件中提供aar的确切文件名来解决此问题。例如编译(名称:‘kinvey-android-2.10.4’,ext:'aar')
" kinvey -android-*“应该解析到libs文件夹中可用的最新Kinvey,这样每次升级到最新的Kinvey时都不需要更改build.gradle文件。但是,我不知道为什么现在对Android的aar文件不起作用。
发布于 2016-02-17 04:47:34
你也失踪了
repositories {
jcenter()
flatDir {
dirs 'libs'
}在你的梯度档案里。直到added.You能够在依赖项之前添加它,我的等级文件才会生成。
https://stackoverflow.com/questions/35258060
复制相似问题