export TERM="dumb"
if [ -e ./gradlew ]; then ./gradlew test;else gradle test;fi
FAILURE: Build failed with an exception.
What went wrong:
A problem occurred configuring root project 'Android-app'. Could not
resolve all dependencies for configuration ':classpath'. Could not
find com.android.tools.build:gradle:3.0.0-alpha1. Searched in the
following locations:
https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.0-alpha1/gradle-3.0.0-alpha1.pom
https://jcenter.bintray.com/com/android/tools/build/gradle/3.0.0-alpha1/gradle-3.0.0-alpha1.jar
Required by:
电流circle.yml
dependencies:
pre:
- mkdir -p $ANDROID_HOME"/licenses"
- echo $ANDROID_SDK_LICENSE > $ANDROID_HOME"/licenses/android-sdk-license"
- source environmentSetup.sh && get_android_sdk_25
cache_directories:
- /usr/local/android-sdk-linux
- ~/.android
- ~/.gradle
override:
- ./gradlew dependencies || true
test:
post:
- mkdir -p $CIRCLE_TEST_REPORTS/junit/
- find . -type f -regex ".*/target/surefire-reports/.*xml" -exec cp {} $CIRCLE_TEST_REPORTS/junit/ \;
machine:
java:
version: oraclejdk8
编辑:我的gradle文件:
buildscript {
repositories {
jcenter()
maven {
url 'https://maven.google.com'
}
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.0-alpha1'
classpath 'com.google.gms:google-services:3.0.0'
classpath "io.realm:realm-gradle-plugin:3.1.3"
}
}
allprojects {
repositories {
mavenCentral()
jcenter()
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}
谷歌推出了新的maven repo
https://android-developers.googleblog.com/2017/10/android-studio-30.html>部分Google的Maven存储库
https://developer.android.com/studio/preview/features/new-android-plugin-migration.html https://developer.android.com/studio/build/dependencies.html
buildscript {
repositories {
...
// You need to add the following repository to download the
// new plugin.
google() // new which replace https://maven.google.com
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.6.3' //Minimum supported Gradle version is 4.6.
}
}
我在编译新的gradle时遇到了问题,如下所示: 错误:找不到com.android.tools.build:gradle:3.0.0-beta2。在以下位置搜索:文件://c://program files/android/android-studio-preview/gradle/m2repository/com/android/tools/build/gradle/3.0.0-beta2/g
我正在尝试将gradle从1.3.1更新到3.5,因为我的一些依赖项需要3.3或更高版本。 我见过类似的问题,但都没有帮助。 build.gradle: gradle-wrapper.properties: 但是,当我尝试做任何事情(构建、清理等)时,我还是得到了这样的结果:
找不到com.android.tools.build:Gradle:4.0.0. https://jcenter.bintray.com/com/android/tools/build/gradle/4.0.0/gradle-4.0.0.pom
null Build.Gradle(项目): 我刚刚从android Studio2.3.3迁移到4.0.1。 我的问题是什么????如果你需要更多信息就告诉我。 感谢您的回答:)
我正在构建一个react原生应用程序,并使用库。 在我的Android/build.gradle中,我在buildScript中有以下内容: 这是否意味着我必须降级我的gradle版本?