From 2475d8cf5bb11a32e21b365eda275dc4f4bbc16b Mon Sep 17 00:00:00 2001 From: divyanshu Date: Tue, 11 Sep 2018 10:32:25 +0530 Subject: [PATCH] Update gradle --- .idea/misc.xml | 25 +++++++++++++++++ .idea/vcs.xml | 6 +++++ app/build.gradle | 16 +++++------ .../ExampleInstrumentedTest.kt | 24 ----------------- .../colorseekbardemo/ExampleUnitTest.kt | 17 ------------ bintray/properties.kts | 1 + build.gradle | 17 +++++++++--- colorseekbar/build.gradle | 14 ++++------ .../colorseekbar/ExampleInstrumentedTest.java | 27 ------------------- .../colorseekbar/ExampleUnitTest.java | 17 ------------ 10 files changed, 58 insertions(+), 106 deletions(-) create mode 100644 .idea/vcs.xml delete mode 100644 app/src/androidTest/java/com/divyanshu/colorseekbardemo/ExampleInstrumentedTest.kt delete mode 100644 app/src/test/java/com/divyanshu/colorseekbardemo/ExampleUnitTest.kt create mode 100644 bintray/properties.kts delete mode 100644 colorseekbar/src/androidTest/java/com/divyanshu/colorseekbar/ExampleInstrumentedTest.java delete mode 100644 colorseekbar/src/test/java/com/divyanshu/colorseekbar/ExampleUnitTest.java diff --git a/.idea/misc.xml b/.idea/misc.xml index af0bbdd..9766204 100644 --- a/.idea/misc.xml +++ b/.idea/misc.xml @@ -5,6 +5,31 @@ + + + + diff --git a/.idea/vcs.xml b/.idea/vcs.xml new file mode 100644 index 0000000..94a25f7 --- /dev/null +++ b/.idea/vcs.xml @@ -0,0 +1,6 @@ + + + + + + \ No newline at end of file diff --git a/app/build.gradle b/app/build.gradle index c3be314..e650879 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -5,12 +5,13 @@ apply plugin: 'kotlin-android' apply plugin: 'kotlin-android-extensions' android { - compileSdkVersion 28 - buildToolsVersion "28.0.1" + compileSdkVersion rootProject.ext.compileSdkVersion + buildToolsVersion rootProject.ext.buildToolsVersion + defaultConfig { applicationId "com.divyanshu.colorseekbardemo" - minSdkVersion 14 - targetSdkVersion 28 + minSdkVersion rootProject.ext.minSdkVersion + targetSdkVersion rootProject.ext.targetSdkVersion versionCode 1 versionName "1.0" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" @@ -26,10 +27,7 @@ android { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" - implementation 'androidx.appcompat:appcompat:1.0.0-beta01' - implementation 'androidx.constraintlayout:constraintlayout:1.1.2' - testImplementation 'junit:junit:4.12' - androidTestImplementation 'androidx.test:runner:1.1.0-alpha4' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0-alpha4' + implementation "androidx.appcompat:appcompat:$rootProject.ext.supportLibraryVersion" + implementation "androidx.constraintlayout:constraintlayout:$rootProject.ext.constraintlayout" implementation project(path: ':colorseekbar') } diff --git a/app/src/androidTest/java/com/divyanshu/colorseekbardemo/ExampleInstrumentedTest.kt b/app/src/androidTest/java/com/divyanshu/colorseekbardemo/ExampleInstrumentedTest.kt deleted file mode 100644 index bea6145..0000000 --- a/app/src/androidTest/java/com/divyanshu/colorseekbardemo/ExampleInstrumentedTest.kt +++ /dev/null @@ -1,24 +0,0 @@ -package com.divyanshu.colorseekbardemo - -import androidx.test.InstrumentationRegistry -import androidx.test.runner.AndroidJUnit4 - -import org.junit.Test -import org.junit.runner.RunWith - -import org.junit.Assert.* - -/** - * Instrumented test, which will execute on an Android device. - * - * See [testing documentation](http://d.android.com/tools/testing). - */ -@RunWith(AndroidJUnit4::class) -class ExampleInstrumentedTest { - @Test - fun useAppContext() { - // Context of the app under test. - val appContext = InstrumentationRegistry.getTargetContext() - assertEquals("com.divyanshu.colorseekbardemo", appContext.packageName) - } -} diff --git a/app/src/test/java/com/divyanshu/colorseekbardemo/ExampleUnitTest.kt b/app/src/test/java/com/divyanshu/colorseekbardemo/ExampleUnitTest.kt deleted file mode 100644 index 69e3329..0000000 --- a/app/src/test/java/com/divyanshu/colorseekbardemo/ExampleUnitTest.kt +++ /dev/null @@ -1,17 +0,0 @@ -package com.divyanshu.colorseekbardemo - -import org.junit.Test - -import org.junit.Assert.* - -/** - * Example local unit test, which will execute on the development machine (host). - * - * See [testing documentation](http://d.android.com/tools/testing). - */ -class ExampleUnitTest { - @Test - fun addition_isCorrect() { - assertEquals(4, 2 + 2) - } -} diff --git a/bintray/properties.kts b/bintray/properties.kts new file mode 100644 index 0000000..de31ce2 --- /dev/null +++ b/bintray/properties.kts @@ -0,0 +1 @@ +bintray.properties \ No newline at end of file diff --git a/build.gradle b/build.gradle index de6193b..586f982 100644 --- a/build.gradle +++ b/build.gradle @@ -1,14 +1,13 @@ // Top-level build file where you can add configuration options common to all sub-projects/modules. buildscript { - ext.kotlin_version = '1.2.60' - ext.kotlin_version = '1.2.50' + ext.kotlin_version = '1.2.61' repositories { google() jcenter() } dependencies { - classpath 'com.android.tools.build:gradle:3.3.0-alpha06' + classpath 'com.android.tools.build:gradle:3.3.0-alpha08' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.4' classpath 'com.github.dcendents:android-maven-gradle-plugin:2.1' @@ -30,4 +29,16 @@ allprojects { task clean(type: Delete) { delete rootProject.buildDir +} + +ext { + // Sdk and tools + minSdkVersion = 14 + targetSdkVersion = 28 + compileSdkVersion = 28 + buildToolsVersion = '28.0.2' + + // App dependencies + supportLibraryVersion = '1.0.0-rc02' + constraintlayout = '1.1.3' } \ No newline at end of file diff --git a/colorseekbar/build.gradle b/colorseekbar/build.gradle index fcb7222..86fadf7 100644 --- a/colorseekbar/build.gradle +++ b/colorseekbar/build.gradle @@ -26,13 +26,12 @@ ext { } android { - compileSdkVersion 28 - buildToolsVersion "28.0.1" - + compileSdkVersion rootProject.ext.compileSdkVersion + buildToolsVersion rootProject.ext.buildToolsVersion defaultConfig { - minSdkVersion 14 - targetSdkVersion 28 + minSdkVersion rootProject.ext.minSdkVersion + targetSdkVersion rootProject.ext.targetSdkVersion versionCode 1 versionName "1.0" @@ -52,10 +51,7 @@ android { dependencies { implementation fileTree(dir: 'libs', include: ['*.jar']) - implementation 'androidx.appcompat:appcompat:1.0.0-beta01' - testImplementation 'junit:junit:4.12' - androidTestImplementation 'androidx.test:runner:1.1.0-alpha4' - androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0-alpha4' + implementation "androidx.appcompat:appcompat:$rootProject.ext.supportLibraryVersion" implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" } repositories { diff --git a/colorseekbar/src/androidTest/java/com/divyanshu/colorseekbar/ExampleInstrumentedTest.java b/colorseekbar/src/androidTest/java/com/divyanshu/colorseekbar/ExampleInstrumentedTest.java deleted file mode 100644 index f4cee47..0000000 --- a/colorseekbar/src/androidTest/java/com/divyanshu/colorseekbar/ExampleInstrumentedTest.java +++ /dev/null @@ -1,27 +0,0 @@ -package com.divyanshu.colorseekbar; - -import android.content.Context; - -import androidx.test.InstrumentationRegistry; -import androidx.test.runner.AndroidJUnit4; - -import org.junit.Test; -import org.junit.runner.RunWith; - -import static org.junit.Assert.*; - -/** - * Instrumented test, which will execute on an Android device. - * - * @see Testing documentation - */ -@RunWith(AndroidJUnit4.class) -public class ExampleInstrumentedTest { - @Test - public void useAppContext() { - // Context of the app under test. - Context appContext = InstrumentationRegistry.getTargetContext(); - - assertEquals("com.divyanshu.colorseekbar.test", appContext.getPackageName()); - } -} diff --git a/colorseekbar/src/test/java/com/divyanshu/colorseekbar/ExampleUnitTest.java b/colorseekbar/src/test/java/com/divyanshu/colorseekbar/ExampleUnitTest.java deleted file mode 100644 index c0bed1e..0000000 --- a/colorseekbar/src/test/java/com/divyanshu/colorseekbar/ExampleUnitTest.java +++ /dev/null @@ -1,17 +0,0 @@ -package com.divyanshu.colorseekbar; - -import org.junit.Test; - -import static org.junit.Assert.*; - -/** - * Example local unit test, which will execute on the development machine (host). - * - * @see Testing documentation - */ -public class ExampleUnitTest { - @Test - public void addition_isCorrect() { - assertEquals(4, 2 + 2); - } -} \ No newline at end of file