【问题标题】:'Gradle sync failed: Gradle DSL method not found: 'minSdkVersdion()''Gradle 同步失败:未找到 Gradle DSL 方法:'minSdkVersdion()'
【发布时间】:2016-04-11 22:26:39
【问题描述】:

Gradle 同步失败:未找到 Gradle DSL 方法:'minSdkVersdion()。我正在使用最新版本的 Android Studio 2.0。

这是我更新的 gradle。

apply plugin: 'com.android.application'

android {
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig {
    applicationId 'com.gkhindi'
    minSdkVersdion 16
    targetSdkVersion 23
    versionCode 1
    versionName '1.0.0'
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}
productFlavors {
}
}
buildscript {
repositories {
    jcenter()
}
dependencies {
    classpath 'com.android.tools.build:gradle:2.0.0'
}
}

allprojects {
repositories {
    jcenter()
}
}

dependencies {
 compile fileTree(dir: 'libs', include: ['*.jar'])
 compile files('libs/StartAppInApp-3.1.0.jar')
 compile files('libs/Shutterbug-1.0.0.jar')
 compile files('libs/Parse-1.11.0.jar')
 compile files('libs/bolts-tasks-1.3.0.jar')
//    compile 'com.android.support:support-v4:23.1.1'
 compile 'com.android.support:appcompat-v7:23.3.0'
 compile 'com.android.support:design:23.3.0'
 compile 'com.google.android.gms:play-services-ads:8.4.0'
 compile 'com.google.android.gms:play-services-games:8.4.0'
 compile 'com.android.support:recyclerview-v7:23.3.0'
 compile 'com.squareup.picasso:picasso:2.5.2'
 compile 'com.google.android.gms:play-services-analytics:8.4.0'
}
android {
  useLibrary 'org.apache.http.legacy'
}    

这是我最后的毕业典礼。当我同步 gradle 时,我收到错误是“Gradle sync failed: Gradle DSL method not found: 'minSdkVersdion()'.

【问题讨论】:

    标签: android android-studio android-gradle-plugin build.gradle


    【解决方案1】:

    你的build.gradle有错别字

    minSdkVersdion 16
    

    而不是

    minSdkVersion 16
    

    【讨论】:

    • 非常感谢@Gaberile
    • @user3144577 如果解决了您的问题,请标记答案。
    猜你喜欢
    • 2016-10-05
    • 2020-02-21
    • 2019-04-02
    • 1970-01-01
    • 1970-01-01
    • 2020-09-16
    • 2019-07-26
    • 1970-01-01
    • 2019-09-29
    相关资源
    最近更新 更多