apply plugin: 'com.android.application'
// TODO: Uncomment to enable crashlytics
// apply plugin: 'io.fabric'
apply plugin: 'realm-android'
apply plugin: 'jacoco-android'

repositories {
    maven { url 'https://maven.fabric.io/public' }
}

android {
    compileSdkVersion 25
    buildToolsVersion "26.0.2"

    defaultConfig {
        applicationId "org.loklak.wok"
        minSdkVersion 18
        targetSdkVersion 25
        versionCode 1
        versionName "1"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
        vectorDrawables.useSupportLibrary = true
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }

    // This is important, it will run lint checks but won't abort build
    lintOptions {
        abortOnError false
    }

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }

    packagingOptions {
        exclude 'META-INF/rxjava.properties'
    }
}

dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')

    testImplementation 'junit:junit:4.12'
    testImplementation 'org.assertj:assertj-core:1.7.1'
    testImplementation 'org.mockito:mockito-core:2.8.47'
    testImplementation 'com.android.support:support-annotations:25.3.1'

    androidTestImplementation 'org.mockito:mockito-android:2.8.47'
    androidTestImplementation 'com.android.support:support-annotations:25.3.1'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:2.2.2'

    implementation 'com.android.support:appcompat-v7:25.3.1'
    implementation 'com.android.support:support-v4:25.3.1'
    implementation 'com.android.support:design:25.3.1'
    implementation 'com.android.support:cardview-v7:25.3.1'

    implementation 'org.joda:joda-convert:1.8'
    implementation 'joda-time:joda-time:2.9.4'

    implementation 'com.google.code.gson:gson:2.8.1'

    implementation 'com.squareup.retrofit2:retrofit:2.3.0'
    implementation 'com.squareup.retrofit2:converter-gson:2.3.0'
    implementation 'com.squareup.okhttp3:logging-interceptor:3.7.0'
    implementation 'com.squareup.retrofit2:adapter-rxjava2:2.3.0'

    implementation 'com.jakewharton:butterknife:8.6.0'
    annotationProcessor 'com.jakewharton:butterknife-compiler:8.6.0'

    implementation 'com.google.dagger:dagger:2.11'
    annotationProcessor 'com.google.dagger:dagger-compiler:2.11'

    implementation 'io.reactivex.rxjava2:rxjava:2.0.5'
    implementation 'io.reactivex.rxjava2:rxandroid:2.0.1'
    implementation 'com.jakewharton.rxbinding2:rxbinding:2.0.0'

    implementation 'com.github.LiquidPlayer:LiquidCore:0.2.2'

    implementation 'com.github.bumptech.glide:glide:3.7.0'

    implementation('com.crashlytics.sdk.android:crashlytics:2.6.8@aar') {
        transitive = true;
    }
}
