plugins {
    alias(libs.plugins.android.application)
    alias(libs.plugins.kotlin.android)
}

android {
    namespace 'com.che.zwiftplayhost'
    compileSdk 34

    defaultConfig {
        applicationId "com.che.zwiftplayhost"
        minSdk 31
        targetSdk 33
        versionCode 1
        versionName "1.0"

        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    kotlinOptions {
        jvmTarget = '1.8'
    }
    buildFeatures {
        viewBinding true
    }
}

dependencies {

    implementation project(path: ':zaplibrary')
    implementation project(path: ':commonlibrary')

    // Default app stuff
    implementation(libs.bundles.base)
    implementation libs.androidx.constraintlayout
    implementation libs.jakewharton.timber

    // Nordic BLE library to avoid pain
    implementation libs.ble.ktx

    // Lifecycle coroutine scopes
    implementation libs.androidx.lifecycle.runtime.ktx

    // Test dependencies - unloved but aspirational :(
    testImplementation libs.testing.junit
    androidTestImplementation(libs.bundles.test)
}