// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
    ext {
        kotlin_version = "1.4.10"
        appcompat_version = "1.2.0"
        constraint_layout_version = "2.0.4"
        junit_version = "4.13.1"
        ext_version = "1.1.2"
        espresso_version = "3.3.0"
        coroutine_version = "1.3.9"
        lifecycle_extensions_version = "2.2.0"
        legacy_support_version = "1.0.0"
        android_material_version = "1.3.0"
        lifecycle_viewmodel_ktx_version = "2.2.0"
        navigation_fragment_ktx_version = "2.3.1"
        timber_version = "4.7.1"
        navigation_ui_ktx_version = "2.3.1"
        coroutine_android_version = "1.3.7"
        core_ktx_version = "1.5.0-rc01"
        hilt_version = '2.32-alpha'
        hilt_androidx_version = '1.0.0-alpha03'
        hilt_navigation_version = '1.0.0-alpha03'
        rxjava_version = "3.0.0"
        rxpermissions_version = "0.12"
        audio_record_view_version = "1.0.4"
        indicator_seekbar_version = "2.1.2"
        firebase_bom_version = "26.8.0"
    }
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath "com.android.tools.build:gradle:4.1.1"
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
        classpath "android.arch.navigation:navigation-safe-args-gradle-plugin:1.0.0"
        classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version"
        classpath 'com.google.gms:google-services:4.3.5'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()
        maven { url 'https://jitpack.io' }
        maven { url "https://oss.jfrog.org/libs-snapshot" }
    }
}

Properties properties = new Properties()
properties.load(project.rootProject.file('local.properties').newDataInputStream())

project.ext {
    useHWASAN = properties.getProperty("useHWASAN").toBoolean()
    useASAN = properties.getProperty("useASAN").toBoolean()
    ndkDir = properties.getProperty('ndk.dir')
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
