android - 找不到构建工具修订版 27.1.1。当我尝试下载时,说它没有下载链接 :

标签 android maven build build.gradle build-tools

这是我的 build.gradle 文件:

buildscript {
repositories {
    google()
    maven { url 'https://maven.fabric.io/public' }
    maven { url 'https://maven.google.com' }
    maven { url 'http://dl.bintray.com/amulyakhare/maven' }
    maven { url 'https://jcenter.bintray.com/' }
    maven { url "https://jitpack.io" }
    mavenCentral()
}

dependencies {
    classpath 'io.fabric.tools:gradle:1.+'
    classpath "io.realm:realm-gradle-plugin:3.2.0"
    classpath 'com.google.gms:google-services:3.1.0' // google-services plugin
}
}
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
apply plugin: 'realm-android'

repositories {
google()
maven { url 'https://maven.fabric.io/public' }
maven { url 'http://dl.bintray.com/amulyakhare/maven' }
maven { url 'https://jcenter.bintray.com/' }
maven { url "https://jitpack.io" }
maven {
    url 'https://maven.google.com'
}
}


android {
compileSdkVersion 27
buildToolsVersion '27.1.1'
defaultConfig {
    applicationId "nl.hgrams.passenger"
    minSdkVersion 17
    targetSdkVersion 23
    versionCode 905
    versionName '3.2'
    multiDexEnabled true
}
sourceSets {
    main {
        java {
            exclude 'nl.hgrams.passenger.activities.PSSimilarTripsGroupActivity'
            exclude 'nl.hgrams.passenger.activities.PSTripStatsActivity'
        }
    }
}
lintOptions {
    checkReleaseBuilds false
    abortOnError false
}
dexOptions {
    preDexLibraries = false
    javaMaxHeapSize "4g"
}
packagingOptions {
    exclude 'META-INF/services/javax.annotation.processing.Processor'
    exclude 'META-INF/LICENSE'
    exclude 'META-INF/NOTICE'
}
buildTypes {
    release {
        minifyEnabled false
        shrinkResources false
        ext.enableCrashlytics = true
        ext.betaDistributionReleaseNotesFilePath = "/Users/gopublic/bamboo-home/xml-data/build-dir/131073/PAS-PAD-VRANDROID/changelog.txt"
        ext.betaDistributionEmails = "alin.rosu@100grams.nl, pedro.amanhui@100grams.nl, 100gramstest@gmail.com"
        ext.betaDistributionGroupAliases = "passenger-android-beta"

    }

    debug {
        minifyEnabled false
        shrinkResources false
        ext.enableCrashlytics = true
        ext.betaDistributionEmails = "alin.rosu@100grams.nl, pedro.amanhui@100grams.nl, 100gramstest@gmail.com"
        ext.betaDistributionReleaseNotesFilePath = "/Users/gopublic/bamboo-home/xml-data/build-dir/131073/PAS-PAD-VRANDROID/changelog.txt"
        ext.betaDistributionGroupAliases = "passenger-android-beta"

    }
}
}

dependencies {
implementation 'com.android.support:multidex:1.0.0'
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:design:27.1.1'
implementation 'com.android.support:percent:27.1.1'
implementation 'com.android.support:recyclerview-v7:27.1.1'
implementation 'com.android.support:transition:27.1.1'
implementation 'com.google.code.gson:gson:2+'
implementation 'com.android.volley:volley:1+'
implementation 'com.squareup.okhttp:okhttp:2.0.0+'
implementation 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'
implementation 'com.google.android.gms:play-services-maps:11.8.0'
implementation 'com.google.android.gms:play-services-location:11.8.0'
implementation 'com.google.android.gms:play-services-gcm:11.8.0'
implementation 'com.google.android.gms:play-services-analytics:11.8.0'
implementation 'com.google.android.gms:play-services-auth:11.8.0'
implementation 'com.google.firebase:firebase-core:11.8.0'
implementation 'com.google.firebase:firebase-storage:11.8.0'
implementation 'com.google.firebase:firebase-auth:11.8.0'
implementation 'com.google.firebase:firebase-messaging:11.8.0'
implementation files('libs/nineoldandroids-2.4.0.jar')
implementation files('libs/okhttp-urlconnection-2.0.0.jar')
implementation 'com.edmodo:cropper:1.0.1'
implementation 'com.squareup.picasso:picasso:2.5.2'
implementation 'com.makeramen:roundedimageview:2.3.0'
implementation 'com.google.maps.android:android-maps-utils:0.4+'
implementation 'com.instabug.library:instabug:4.2.6'
implementation 'io.reactivex:rxjava:1.1.0'
implementation 'com.plattysoft.leonids:LeonidsLib:1.3.1'
implementation 'io.smooch:core:latest.release'
implementation 'io.smooch:ui:latest.release'
implementation "com.daimajia.swipelayout:library:1.2.0@aar"
implementation 'com.squareup.okhttp3:okhttp:3.2.0'
implementation 'com.squareup.retrofit:retrofit:1.9.0'
implementation 'com.bartoszlipinski:recyclerviewheader2:2.0.1'
implementation 'io.branch.sdk.android:library:2.+'
implementation 'com.github.2359media:EasyAndroidAnimations:0.8'
implementation 'me.grantland:autofittextview:0.2.+'
implementation 'com.github.kaknazaveshtakipishi:PermissionEverywhere:1.0.2'
implementation('com.crashlytics.sdk.android:crashlytics:2.8.0@aar') {
    transitive = true;
}
implementation(
        [group: 'com.fasterxml.jackson.core', name: 'jackson-core', version: '2.4.1'],
        [group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version: '2.4.1'],
        [group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.4.1']
)
implementation 'devlight.io:navigationtabbar:1.2.5'
implementation 'org.apache.commons:commons-lang3:3.4'
implementation 'com.android.support.constraint:constraint-layout:1.0.2'
implementation 'com.yahoo.mobile.client.android.util.rangeseekbar:rangeseekbar-library:0.1.0'
implementation 'commons-io:commons-io:2.4'
implementation 'com.facebook.android:facebook-android-sdk:[4,5)'
}

apply plugin: 'com.google.gms.google-services'

我收到这个错误:

Failed to find Build Tools revision 27.1.1
Install Build Tools 27.1.1 and sync project

如果我按安装构建工具 27.1.1。我收到无法下载的错误消息:

https://s3.amazonaws.com/uploads.hipchat.com/39260/829560/ECeAJ5Gi0GQnjoZ/upload.png

为什么会这样?它曾经与 26.1.1 一起工作,但现在我更新到 Android Studio 3.1,它不允许我使用那个版本,说 27.0.3 是最小的工作。但尝试使用 27.0.3 和 27.1.1,我总是遇到编译错误

最佳答案

指的是 official documentation ,实际发布是:

android {
    buildToolsVersion "27.0.3"
    ...
}

而不是 27.1.1

所以,修复你的android节点

android {
  compileSdkVersion 27
  buildToolsVersion '27.0.3'
   .....

关于android - 找不到构建工具修订版 27.1.1。当我尝试下载时,说它没有下载链接 :,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49921807/

相关文章:

java.lang.NoClassDefFoundError : org/slf4j/impl/StaticLoggerBinder

tomcat - 将 Angular2 项目集成到 Tomcat 服务器中

iOS Simulator 无法运行并且 xCode 构建应用程序的速度太慢

android - 来自谷歌开发人员的交互式图表示例显示错误 eclipse

android - ListView 选中的项目可绘制

android - 后退按钮不起作用

ios - FFmpeg 构建错误 "openssl not found"(适用于 Mac 上的 iOS)

android - 具有单一数据输入的 MPAndroid 线图

maven - java.lang.NoSuchMethodError : org. springframework.beans.factory.xml.XmlReaderContext.getResourceLoader()Lorg/springframework/core/io/ResourceLoader

java - 部署 WAR 包 TOMCAT