plugins {
    id 'com.android.application'
}

apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'

android {

    compileSdkVersion 31

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }

    def versionPrefix = "1.3"
    defaultConfig {
        applicationId "ca.fuwafuwa.kaku"
        minSdkVersion 21
        targetSdkVersion 31
        versionCode 78
        versionName "$versionPrefix.$versionCode"
    }

    buildFeatures {
        viewBinding true
    }

    buildTypes {
        release {
            debuggable false
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
        debug {
            debuggable true
        }
    }
    packagingOptions {
        resources {
            excludes += ['META-INF/DEPENDENCIES', 'META-INF/LICENSE', 'META-INF/LICENSE.txt', 'META-INF/license.txt', 'META-INF/NOTICE', 'META-INF/NOTICE.txt', 'META-INF/notice.txt', 'META-INF/ASL2.0', 'META-INF/CONTRIBUTORS.md', 'META-INF/LICENSE.md']
        }
    }


    testOptions {
        unitTests.returnDefaultValues = true
    }
}

dependencies {
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    implementation 'com.rmtheis:tess-two:9.0.0'
    implementation 'com.google.guava:guava:31.0.1-android'
    implementation 'com.google.code.gson:gson:2.8.9'
    implementation 'androidx.appcompat:appcompat:1.4.1'
    implementation 'com.google.android.material:material:1.6.0'
    implementation 'com.j256.ormlite:ormlite-android:5.1'
    implementation 'com.google.android.gms:play-services-ads:20.6.0'
    implementation 'com.atilika.kuromoji:kuromoji-core:0.9.0'
    implementation 'com.atilika.kuromoji:kuromoji-ipadic:0.9.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.1.3'
    implementation 'androidx.legacy:legacy-support-v4:1.0.0'
    testImplementation 'junit:junit:4.13.2'
    // Probably just delete all these was trying to get GenerateDictionary to work as a Unit Test
    testImplementation 'com.j256.ormlite:ormlite-core:5.1'
    testImplementation 'com.j256.ormlite:ormlite-jdbc:5.1'
    testImplementation 'org.xerial:sqlite-jdbc:3.25.2'
    testImplementation 'xmlpull:xmlpull:1.1.3.1'
    testImplementation 'kxml2:kxml2:2.3.0'
}