/*
 * Copyright (c) 2021 2bllw8
 * SPDX-License-Identifier: GPL-3.0-only
 */
buildscript {
    repositories {
        mavenCentral()
        google()
    }
    dependencies {
        classpath("com.android.tools.build:gradle:8.11.0")
    }
}

allprojects {
    repositories {
        mavenCentral()
        google()
    }
}

tasks.register("clean", Delete) {
    delete(rootProject.layout.buildDirectory)
}

final Properties localProps = new Properties()
if (file("local.properties").exists()) {
    localProps.load(file("local.properties").newDataInputStream())
}

ext {
    minSdkVersion = 26
    targetSdkVersion = 36

    versionCode = 17
    versionName = "2.7.0"

    namespace = "exe.bbllw8.anemo"

    sourceCompatibilityVersion = JavaVersion.VERSION_17
    targetCompatibilityVersion = JavaVersion.VERSION_17

    keyStoreFile = localProps.getProperty("androidStoreFile")
    if (keyStoreFile != null && keyStoreFile != "") {
        keyStoreFile = file(keyStoreFile)
    }
    keyStorePassword = localProps.getProperty("androidStorePassword")
    keyAlias = localProps.getProperty("androidKeyAlias")
    keyPassword = localProps.getProperty("androidKeyPassword")
}
