Skip to content

Instantly share code, notes, and snippets.

@uzuki-P
Last active June 7, 2018 04:04
Show Gist options
  • Save uzuki-P/ab5a3f449bffc11c28c3d5b112ed3d93 to your computer and use it in GitHub Desktop.
Save uzuki-P/ab5a3f449bffc11c28c3d5b112ed3d93 to your computer and use it in GitHub Desktop.

Material Color .xml

gradle.build (project level):

buildscript {
    ext.kotlin_version = '1.2.41'
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.2.0-alpha15'
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
        classpath "org.jetbrains.kotlin:kotlin-android-extensions:$kotlin_version"

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()
        maven { url 'https://jitpack.io' }
        maven { url "https://maven.google.com" }
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

gradle.build (app level):

apply plugin: 'com.android.application'

apply plugin: 'kotlin-android'

apply plugin: 'kotlin-android-extensions'

android {
    compileSdkVersion 27
    defaultConfig {
        applicationId "com.example.appId"
        minSdkVersion 17
        targetSdkVersion 27
        versionCode 1
        versionName "1.0"
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
        vectorDrawables {
            useSupportLibrary = true
        }
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
}

ext.android_support_version = "27.1.1"
ext.google_service_version = "15.0.1"

dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')
    implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
    implementation "com.android.support:appcompat-v7:$android_support_version"
    implementation "com.android.support:design:$android_support_version"
    implementation "com.android.support:recyclerview-v7:$android_support_version"
    implementation "com.android.support:cardview-v7:$android_support_version"
    implementation "com.android.support:palette-v7:$android_support_version"
    implementation "com.google.android.gms:play-services-maps:$google_service_version"
    implementation "com.google.android.gms:play-services-location:$google_service_version"
    implementation 'com.android.support.constraint:constraint-layout:1.1.0'
    implementation 'com.google.android:flexbox:0.3.2'

    implementation 'org.jetbrains.anko:anko:0.10.4'
    implementation 'com.github.hotchemi:khronos:0.9.0'
    implementation 'com.google.code.gson:gson:2.8.4'
    implementation 'com.squareup.okhttp3:okhttp:3.10.0'

    implementation 'io.supercharge:shimmerlayout:2.1.0'
    implementation 'com.github.medyo:fancybuttons:1.8.4'
    implementation 'com.otaliastudios:autocomplete:1.0.2'

    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}

kotlin {
    experimental {
        coroutines "enable"
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment