Skip to content

itshnegg/kotlin-cache-miss-demo

Repository files navigation

KotlinCompile Cache Miss Demo

variant filter affects an input (commonSourceSet) of KotlinCompile task

// root build.gradle

subprojects { project ->
    project.plugins.withId('com.android.application') {
        boolean ide = System.getProperty('idea.platform.prefix') != null
        if (ide) {
            android {
                variantFilter { variant ->
                    variant.ignore = variant.buildType.name != 'debug'
                }
            }
        }
    }
}

Steps to reproduce

  1. Build the project using cmd
./gradlew app:assembleDebug // 28 actionable tasks: 28 executed
  1. Clean
./gradlew clean
  1. Build the project in Android Studio

Expected:

28 actionable tasks: 3 executed, 25 from cache

Actual:

28 actionable tasks: 4 executed, 24 from cache

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages