无法解决':app @ debug / compileClasspath':无法解析项目:learncodings

时间:2018-01-17 09:38:37

标签: android android-gradle

将学习编码项目添加到我的项目我们模块依赖项中,但它显示this error 任何人请帮助我。 gradle以下是我的应用程序的gradle

android {
compileSdkVersion 23
buildToolsVersion '26.0.2'
aaptOptions {
    cruncherEnabled = false
}

defaultConfig {
    applicationId "com.droidacademy.codings"
    minSdkVersion 15
    targetSdkVersion 23
    versionCode 1
    versionName "1.0"
    // Enabling multidex support.
    multiDexEnabled true
}

sourceSets {         主{             assets.srcDirs = [' src / main / assets',' src / main / assets /',' src / main / assets / c_outputs']             res.srcDirs = [' src / main&res',' src / main / res / anim',' src / main / res / layout-sw600dp']         }     }

buildTypes {

    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }


}
repositories {
    mavenCentral()
    jcenter()

}



repositories {
    maven { url "https://jitpack.io" }
}

}

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

testCompile 'junit:junit:4.12'
compile files('libs/volley.jar')
compile files('libs/achartengine-1.0.0.jar')
compile files('libs/gson-1.7.jar')
compile 'com.github.florent37:materialtextfield:1.0.5'
compile files('libs/activation.jar')
compile files('libs/additionnal.jar')
compile 'com.android.support:cardview-v7:23.4.0'
compile 'com.android.support:recyclerview-v7:23.4.0'
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.android.support:support-v4:23.4.0'
compile 'com.felipecsl.asymmetricgridview:library:2.0.1'
compile files('libs/mail.jar')
compile 'com.github.PhilJay:MPAndroidChart:v2.2.4'
compile 'com.intuit.sdp:sdp-android:1.0.4'
compile 'com.squareup.picasso:picasso:2.5.2'
implementation project(':learncodings')

}

这是我的模块应用程序的Gradle

android {
compileSdkVersion 23
buildToolsVersion '26.0.2'
aaptOptions {
    cruncherEnabled = false
}
defaultConfig {
    applicationId "com.whalts.learncoding"
    minSdkVersion 15
    targetSdkVersion 23
    versionCode 1
    versionName "1.0"
    multiDexEnabled true
}
buildTypes {

    release {
        minifyEnabled false
        proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
    }
}

}

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

compile 'de.hdodenhof:circleimageview:2.0.0'

compile 'com.android.support:cardview-v7:23.4.0'
compile 'com.android.support:recyclerview-v7:23.4.0'
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.android.support:design:23.4.0'
compile 'com.android.support:support-v4:23.4.0'
compile 'com.google.android.gms:play-services-gcm:9.2.0'
compile 'com.google.android.gms:play-services-ads:9.2.0'

}

1 个答案:

答案 0 :(得分:4)

转到文件\设置\ Gradle。取消选中“离线工作”框。 如果这不起作用尝试使缓存/重新启动无效