I've the following app build.gradle
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
applicationId "io.gresse.hugo.anecdote"
minSdkVersion 16
targetSdkVersion 23
versionCode 12
versionName "1.0.0"
}
buildTypes {
release {
archivesBaseName = "anecdote-" + defaultConfig.versionName
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
archivesBaseName = "anecdote-DEBUGDEBUGDEBUG-"
}
}
}
When I execute ./gradlew assembleRelease assembleDebug
The output .apk are:
- anecdote-DEBUGDEBUGDEBUG-debug-unaligned.apk
- anecdote-DEBUGDEBUGDEBUG-debug.apk
- anecdote-DEBUGDEBUGDEBUG-release-unaligned.apk
- anecdote-DEBUGDEBUGDEBUG-release.apk
What I wanted:
- anecdote-DEBUGDEBUGDEBUG-debug-unaligned.apk
- anecdote-DEBUGDEBUGDEBUG-debug.apk
- anecdote-1.0.0-release-unaligned.apk
- anecdote-1.0.0-release.apk
Is there any way to apply the archiveBaseName to a specific build types or is it a bug?
Thanks,