我遵循了将我的 AAR 文件发布到 JCenter 所需的每个步骤,然后使用https://github.com/danielemaddaluno/gradle-jcenter-publish将其与 Maven Central 同步。我按照他的第 13 步和第 14 步编写了这个命令,得到了这个错误:
G:\Android 开发应用程序\android-studio\gradle\gradle-2.2.1\bin>gradle bintrayUpload
FAILURE:构建失败并出现异常。
- 出了什么问题:
在根项目“bin”中找不到任务“bintrayUpload”。
build.gradle(项目:xxxx)
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.1.2'
classpath 'com.github.dcendents:android-maven-plugin:1.2'
classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.1"
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
apply plugin: 'com.jfrog.bintray'
repositories {
jcenter()
}
}