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

android {
    compileSdkVersion 25
    buildToolsVersion rootProject.ext.buildToolsVersion
    defaultConfig {
        applicationId "net.danlew.counter"
        minSdkVersion 23
        targetSdkVersion 25
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
        exclude group: 'com.android.support', module: 'support-annotations'
    })
    implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}"
    implementation "com.android.support:recyclerview-v7:${rootProject.ext.supportLibVersion}"
    implementation "com.android.support:design:${rootProject.ext.supportLibVersion}"
    implementation "com.android.support:cardview-v7:${rootProject.ext.supportLibVersion}"
    implementation 'com.android.support.constraint:constraint-layout:1.1.3'
    testImplementation 'junit:junit:4.12'

    implementation "android.arch.lifecycle:extensions:${rootProject.archLifecycleVersion}"
    implementation "android.arch.persistence.room:runtime:${rootProject.archRoomVersion}"
    implementation "android.arch.persistence.room:rxjava2:${rootProject.archRoomVersion}"
    kapt "android.arch.lifecycle:compiler:${rootProject.archLifecycleVersion}"
    kapt "android.arch.persistence.room:compiler:${rootProject.archRoomVersion}"
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"

    String butterKnifeVersion = '8.5.1'
    implementation "com.jakewharton:butterknife:$butterKnifeVersion"
    kapt "com.jakewharton:butterknife-compiler:$butterKnifeVersion"

    implementation 'io.reactivex.rxjava2:rxjava:2.1.0'

    String daggerVersion = '2.10'
    implementation "com.google.dagger:dagger:$daggerVersion"
    kapt "com.google.dagger:dagger-compiler:$daggerVersion"

    String rxBindingVersion = '2.0.0'
    implementation "com.jakewharton.rxbinding2:rxbinding:$rxBindingVersion"
    implementation "com.jakewharton.rxbinding2:rxbinding-kotlin:$rxBindingVersion"

    implementation 'com.jakewharton.timber:timber:4.5.1'

    implementation 'com.jakewharton.rxrelay2:rxrelay:2.0.0'
}

repositories {
    mavenCentral()
}
