【问题标题】:Failed to resolve: com.afollestad:material-dialogs:0.6.0无法解决:com.afollestad:material-dialogs:0.6.0
【发布时间】:2016-09-10 18:17:31
【问题描述】:

我导入了一个新应用,但我从 Gradle (Android Studio) 收到以下错误:

Failed to resolve: com.afollestad:material-dialogs:0.6.0

这是我的 gradle 文件:

apply plugin: 'com.android.application'

android {
    compileSdkVersion 21
    buildToolsVersion "21.1.2"

    defaultConfig {
        applicationId "com.pongodev.recipesapp"
        minSdkVersion 11
        targetSdkVersion 21
        versionCode 5
        versionName "3.0.3"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    compile fileTree(dir: 'libs', include: ['*.jar'])

    // Main libraries, you always need this libraries in your project. do not remove them.
    compile 'com.android.support:appcompat-v7:21.0.3'
    compile 'com.android.support:support-v4:21.0.3'
    compile 'com.google.android.gms:play-services:6.5.87'

    // Important library to create material design. do not remove this.
    compile project(':materialDesign')

    // Library to create tabbar
    compile 'com.jpardogo.materialtabstrip:library:1.0.6'

    // Library to create ripple effect. work together with materialDesign library.
    compile 'com.github.traex.rippleeffect:library:1.2.2'

    // Library to create rounded, circle, and any shape image.
    compile 'com.makeramen:roundedimageview:1.4.0'

    // Library load lazy images.
    compile 'com.squareup.picasso:picasso:2.4.0'

    // Library to create simple list.
    compile 'com.android.support:recyclerview-v7:21.0.0'

    // Library to create complex clickable list.
    compile 'com.android.support:cardview-v7:21.0.3'

    // Library to create material dialog.
    compile 'com.afollestad:material-dialogs:0.6.0'

    // Library to create animation imageview.
    compile 'com.flaviofaria:kenburnsview:1.0.5'

}

我该如何解决这个问题?

【问题讨论】:

  • 尝试编译'com.afollestad.material-dialogs:core:0.9.0.1'
  • 当我这样做时,我得到一堆错误uploadpie.com/NWAgY
  • 将您的构建工具更新到至少 23.0.0。目前它在你的 gradle 中是 21.1.2。
  • 同样的问题,我认为我们在这里遗漏了一些东西uploadpie.com/ElddT
  • 您错过了字符串“core”。它是 'com.afollestad.material-dialogs:core:0.9.0.1' 而不是 'com.afollestad.material-dialogs:0.9.0.1'

标签: java android maven android-studio gradle


【解决方案1】:

应用插件:'com.android.application'

机器人{ compileSdkVersion 25 buildToolsVersion '25.0.3'

defaultConfig {
    applicationId "com.my.app"
    minSdkVersion 11
    targetSdkVersion 25
    versionCode 5
    versionName "3.0.3"
}
buildTypes {
    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

}

依赖{ 编译 fileTree(dir: 'libs', include: ['*.jar'])

// Main libraries, you always need this libraries in your project. do not remove them.
compile 'com.android.support:appcompat-v7:25.3.1'
compile 'com.android.support:support-v4:25.3.1'
compile 'com.google.android.gms:play-services:6.5.87'

// Important library to create material design. do not remove this.
compile project(':materialDesign')

// Library to create tabbar
compile 'com.jpardogo.materialtabstrip:library:1.0.6'

// Library to create ripple effect. work together with materialDesign library.
compile 'com.github.traex.rippleeffect:library:1.2.2'

// Library to create rounded, circle, and any shape image.
compile 'com.makeramen:roundedimageview:1.4.0'

// Library load lazy images.
compile 'com.squareup.picasso:picasso:2.4.0'

// Library to create simple list.
compile 'com.android.support:recyclerview-v7:25.3.1'

// Library to create complex clickable list.
compile 'com.android.support:cardview-v7:25.3.1'

// Library to create material dialog.
compile 'com.afollestad.material-dialogs:core:0.9.0.1'

// Library to create animation imageview.
compile 'com.flaviofaria:kenburnsview:1.0.5'

}

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2023-03-29
    • 2011-11-25
    • 2020-10-27
    • 1970-01-01
    • 2018-06-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多