I've a core
module that is the base of my app. This module have 2 flavors. When I try import it in my app
module that has no flavor, I receive the following error:
> Could not resolve all task dependencies for configuration ':app:releaseRuntimeClasspath'.
> Could not resolve project :core.
Required by:
project :app
> Project :app declares a dependency from configuration 'implementation' to configuration 'internalRelease' which is not declared in the descriptor for project :core.
That's my core build.gradle configuration:
android {
compileSdkVersion 27
publishNonDefault true
defaultConfig {
minSdkVersion 16
targetSdkVersion 27
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
flavorDimensions 'target'
productFlavors {
internal {
dimension "target"
}
external {
dimension "target"
}
}
dexOptions { preDexLibraries true }
}
And here is how i'm importing this module in my app module build.gradle:
implementation project(path: ':core', configuration: 'internalRelease')