plugins {
    id 'com.android.application'
    id 'com.google.android.libraries.mapsplatform.secrets-gradle-plugin'
}

android {
    namespace 'de.droiddrone.control'
    compileSdk 34

    defaultConfig {
        applicationId "de.droiddrone.control"
        minSdk 26
        targetSdk 34
        versionCode 9
        versionName "2.3.0"

        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

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

    buildFeatures {
        buildConfig true
    }

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_11
        targetCompatibility JavaVersion.VERSION_11
    }
}

secrets {
    // The file "secrets.properties" does not exist in Git
    // Add the file in project root folder and write to it:
    // MAPS_API_KEY=YOUR_GOOGLE_MAPS_API_KEY
    // Maps SDK for Android should be active for the key
    propertiesFileName = "secrets.properties"
    defaultPropertiesFileName = "local.defaults.properties"
}

dependencies {
    implementation project(':Common')
    implementation 'androidx.appcompat:appcompat:1.7.0'
    implementation 'androidx.fragment:fragment:1.8.3'
    implementation 'androidx.preference:preference:1.2.1'
    implementation 'com.github.martin-stone:hsv-alpha-color-picker-android:3.1.0'
    implementation 'com.google.android.gms:play-services-maps:19.0.0'
    implementation 'com.google.android.material:material:1.12.0'
    testImplementation 'junit:junit:4.13.2'
    androidTestImplementation 'androidx.test.ext:junit:1.2.1'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1'
}