apply plugin: 'com.android.application'
apply plugin: 'com.analysys.android.plugin'

android {

    compileSdkVersion 28

    defaultConfig {
        minSdkVersion 15
        targetSdkVersion 28

        buildConfigField("String", "Build_Type", "\"${Build_Type}\"")


        applicationId "com.analysys.demo"
//        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

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

    dexOptions {
        preDexLibraries false
        maxProcessCount 8
        javaMaxHeapSize "4g"
    }

    aaptOptions {
        cruncherEnabled = false
        useNewCruncher = false
    }

    lintOptions {
        checkReleaseBuilds false
        abortOnError false
        warningsAsErrors false
        disable "UnusedResources"
        textOutput "stdout"
        textReport false
        disable 'RestrictedApi'
    }
    compileOptions {
        sourceCompatibility = JavaVersion.VERSION_1_8
        targetCompatibility = JavaVersion.VERSION_1_8
    }

    analysysConfig {
        lambdaEnabled = true
    }

    dataBinding {
        enabled = true
    }

}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.aar'])

    implementation 'androidx.appcompat:appcompat:1.0.2'
    implementation 'com.google.android.material:material:1.0.0'

}

// 忽略文档编译错误. 设置编码
tasks.withType(Javadoc) {
    options.addStringOption('Xdoclint:none', '-quiet')
    options.addStringOption('encoding', 'UTF-8')
    options.addStringOption('charSet', 'UTF-8')
}
