每个构建计数方法引用(Dexcount Gradle 插件)

dexcount 插件统计创建成功后,方法和类的资源计数。

app/build.gradle 中添加插件:

apply plugin: 'com.android.application'

buildscript {
    repositories {
        mavenCentral() // or jcenter()
    }

    dependencies {
        classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.5.5'
    }
}

app/build.gradle 文件中应用插件:

apply plugin: 'com.getkeepsafe.dexcount'

查找插件生成的输出数据:

../app/build/outputs/dexcount

特别有用的是 .html 图表:

../app/build/outputs/dexcount/debugChart/index.html