apply plugin: 'com.android.library'

def playStore = false
def materialVersion = '1.6.1'

android {
    namespace = 'com.rustamg.filedialogs'
    compileSdk 35

    defaultConfig {
        if (playStore) {
            minSdk 24
            materialVersion = '1.12.0'
        } else {
            multiDexEnabled true
            minSdk 14
        }

        targetSdk 35
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    compileOptions {
        // Flag to enable support for the new language APIs
//        coreLibraryDesugaringEnabled true

        // sourceCompatibility JavaVersion.VERSION_1_8
        // targetCompatibility JavaVersion.VERSION_1_8
    }
    lint {
        checkReleaseBuilds false
    }
}

tasks.withType(JavaCompile).configureEach {
    options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation"
}

dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')
    compileOnly group: 'com.google.code.findbugs', name: 'jsr305', version: '3.0.2'
    implementation "com.google.android.material:material:${materialVersion}"
}
