Skip to content

Commit

Permalink
Merge pull request #29 from marcellogalhardo/update-gradle
Browse files Browse the repository at this point in the history
Update Dependencies
  • Loading branch information
marcellogalhardo authored May 13, 2021
2 parents 9a61f36 + 8fd72c4 commit 559943a
Show file tree
Hide file tree
Showing 11 changed files with 140 additions and 107 deletions.
19 changes: 4 additions & 15 deletions build.gradle
Original file line number Diff line number Diff line change
@@ -1,38 +1,27 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
ext.kotlin_version = '1.4.31'
ext.lifecycle_version = '2.3.1'
ext.activity_version = '1.2.2'
ext.fragment_version = '1.3.3'
ext.compose_version = '1.0.0-beta02'
ext.navigation_compose_version = '1.0.0-alpha09'
ext.navigation_version = '2.3.4'
ext.viewmodel_version = '1.0.0-alpha03'
ext.junit_version = '4.13.2'
repositories {
google()
mavenCentral()
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:4.2.0-rc01'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath("org.jmailen.gradle:kotlinter-gradle:3.4.0")
classpath("name.remal:gradle-plugins:1.1.6")
classpath libs.gradle.plugin
classpath libs.gradle.kotlin
classpath libs.gradle.kotlinter
}
}

plugins {
id("com.autonomousapps.dependency-analysis") version "0.71.0"
id 'com.autonomousapps.dependency-analysis' version "0.73.0"
}

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

Expand Down
27 changes: 13 additions & 14 deletions compose/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ android {
}

composeOptions {
kotlinCompilerVersion kotlin_version
kotlinCompilerExtensionVersion compose_version
kotlinCompilerVersion libs.versions.kotlin.get()
kotlinCompilerExtensionVersion libs.versions.androidx.compose.get()
}
}

Expand All @@ -59,23 +59,22 @@ afterEvaluate {
}

dependencies {
api project(':core')
api projects.core

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-compose:$viewmodel_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate
implementation libs.androidx.viewmodel.compose

implementation "androidx.navigation:navigation-compose:$navigation_compose_version"

implementation "androidx.activity:activity-ktx:$activity_version"
implementation "androidx.fragment:fragment-ktx:$fragment_version"
implementation libs.androidx.navigation.compose
implementation libs.androidx.activity.core
implementation libs.androidx.fragment.core

// Unit Testing
testImplementation "junit:junit:$junit_version"
implementation libs.junit.core

// Android Testing
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation libs.androidx.test.junit
androidTestImplementation libs.androidx.test.espresso
}
26 changes: 13 additions & 13 deletions core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,23 +55,23 @@ afterEvaluate {
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation "androidx.activity:activity-ktx:$activity_version"
implementation libs.androidx.activity.core

// Unit Testing
testImplementation "junit:junit:$junit_version"
testImplementation "org.robolectric:robolectric:4.5.1"
testImplementation 'androidx.test:core-ktx:1.3.0'
testImplementation 'androidx.test:runner:1.3.0'
testImplementation 'androidx.test:rules:1.3.0'
testImplementation 'androidx.test.ext:junit:1.1.2'
testImplementation 'androidx.test.ext:truth:1.3.0'
testImplementation "com.google.truth:truth:1.1.2"
testImplementation libs.junit.core
testImplementation libs.robolectric.core
testImplementation libs.androidx.test.core
testImplementation libs.androidx.test.runner
testImplementation libs.androidx.test.rules
testImplementation libs.androidx.test.junit
testImplementation libs.androidx.test.truth
testImplementation libs.google.truth

// Android Testing
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation libs.androidx.test.junit
}
32 changes: 16 additions & 16 deletions fragment/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,27 +55,27 @@ afterEvaluate {
}

dependencies {
api project(':core')
api projects.core

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation "androidx.activity:activity-ktx:$activity_version"
implementation "androidx.fragment:fragment-ktx:$fragment_version"
implementation libs.androidx.activity.core
implementation libs.androidx.fragment.core

// Unit Testing
testImplementation "junit:junit:$junit_version"
testImplementation "org.robolectric:robolectric:4.5.1"
testImplementation 'androidx.test:core-ktx:1.3.0'
testImplementation 'androidx.test:runner:1.3.0'
testImplementation 'androidx.test:rules:1.3.0'
testImplementation 'androidx.test.ext:junit:1.1.2'
testImplementation 'androidx.test.ext:truth:1.3.0'
testImplementation "com.google.truth:truth:1.1.2"
testImplementation libs.junit.core
testImplementation libs.robolectric.core
testImplementation libs.androidx.test.core
testImplementation libs.androidx.test.runner
testImplementation libs.androidx.test.rules
testImplementation libs.androidx.test.junit
testImplementation libs.androidx.test.truth
testImplementation libs.google.truth

// Android Testing
debugImplementation "androidx.fragment:fragment-testing:$fragment_version"
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
debugImplementation libs.androidx.fragment.testing
androidTestImplementation libs.androidx.test.junit
}
34 changes: 34 additions & 0 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
[versions]
androidx-compose = '1.0.0-beta04'
androidx-fragment = "1.3.3"
androidx-lifecycle = "2.3.1"
androidx-test = "1.3.0"
kotlin = "1.4.32"
navigation = "2.3.4"

[libraries]
androidx-activity-core = { group = "androidx.activity", name = "activity-ktx", version = "1.2.3" }
androidx-appcompat-core = { group = "androidx.appcompat", name = "appcompat", version = "1.3.0-rc01" }
androidx-constraintlayout-core = { group = "androidx.constraintlayout", name = "constraintlayout", version = "2.0.4" }
androidx-core = { group = "androidx.core", name = "core", version = "1.3.2" }
androidx-fragment-core = { group = "androidx.fragment", name = "fragment-ktx", version.ref = "androidx-fragment" }
androidx-fragment-testing = { group = "androidx.fragment", name = "fragment-testing", version.ref = "androidx-fragment" }
androidx-navigation-compose = { group = "androidx.navigation", name = "navigation-compose", version = "1.0.0-alpha10" }
androidx-navigation-fragment = { group = "androidx.navigation", name = "navigation-fragment-ktx", version.ref = "navigation" }
androidx-navigation-runtime = { group = "androidx.navigation", name = "navigation-runtime-ktx", version.ref = "navigation" }
androidx-test-core = { group = "androidx.test", name = "core-ktx", version.ref = "androidx-test" }
androidx-test-espresso = { group = "androidx.test.espresso", name = "espresso-core", version = "3.3.0" }
androidx-test-junit = { group = "androidx.test.ext", name = "junit", version = "1.1.2" }
androidx-test-rules = { group = "androidx.test", name = "rules", version.ref = "androidx-test" }
androidx-test-runner = { group = "androidx.test", name = "runner", version.ref = "androidx-test" }
androidx-test-truth = { group = "androidx.test.ext", name = "truth", version = "1.3.0" }
androidx-viewmodel-compose = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-compose", version = "1.0.0-alpha04" }
androidx-viewmodel-core = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-ktx", version.ref = "androidx-lifecycle" }
androidx-viewmodel-savedstate = { group = "androidx.lifecycle", name = "lifecycle-viewmodel-savedstate", version.ref = "androidx-lifecycle" }
google-truth = { group = "com.google.truth", name = "truth", version = "1.1.2" }
gradle-kotlin = { group = "org.jetbrains.kotlin", name = "kotlin-gradle-plugin", version.ref = "kotlin" }
gradle-kotlinter = { group = "org.jmailen.gradle", name = "kotlinter-gradle", version = "3.4.0" }
gradle-plugin = { group = "com.android.tools.build", name = "gradle", version = "4.2.0" }
junit-core = { group = "junit", name = "junit", version = "4.13.2" }
kotlin-stdlib = { group = "org.jetbrains.kotlin", name = "kotlin-stdlib-jdk8", version.ref = "kotlin" }
robolectric-core = { group = "org.robolectric", name = "robolectric", version = "4.5.1" }
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.8.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-7.0.1-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
35 changes: 19 additions & 16 deletions navigation-fragment/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -55,27 +55,30 @@ afterEvaluate {
}

dependencies {
api project(':core')
api projects.core

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation "androidx.fragment:fragment-ktx:$fragment_version"
implementation "androidx.navigation:navigation-fragment-ktx:$navigation_version"
implementation libs.androidx.activity.core
implementation libs.androidx.fragment.core

// Unit Testing
testImplementation "junit:junit:$junit_version"
testImplementation "org.robolectric:robolectric:4.5.1"
testImplementation 'androidx.test:core:1.3.0'
testImplementation 'androidx.test:runner:1.3.0'
testImplementation 'androidx.test:rules:1.3.0'
testImplementation 'androidx.test.ext:junit:1.1.2'
testImplementation 'androidx.test.ext:truth:1.3.0'
testImplementation "com.google.truth:truth:1.1.2"
testImplementation libs.junit.core
testImplementation libs.robolectric.core
testImplementation libs.androidx.test.core
testImplementation libs.androidx.test.runner
testImplementation libs.androidx.test.rules
testImplementation libs.androidx.test.junit
testImplementation libs.androidx.test.truth
testImplementation libs.google.truth

// Android Testing
debugImplementation "androidx.fragment:fragment-testing:$fragment_version"
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
debugImplementation libs.androidx.fragment.testing
androidTestImplementation libs.androidx.test.junit

implementation libs.androidx.navigation.fragment

}
16 changes: 8 additions & 8 deletions navigation-view/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,19 @@ afterEvaluate {
}

dependencies {
api project(':core')
api projects.core

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation "androidx.navigation:navigation-runtime-ktx:$navigation_version"
implementation libs.androidx.navigation.runtime

// Unit Testing
testImplementation "junit:junit:$junit_version"
testImplementation libs.junit.core

// Android Testing
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation libs.androidx.test.junit
androidTestImplementation libs.androidx.test.espresso
}
34 changes: 19 additions & 15 deletions sample/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,23 +33,27 @@ android {
}

dependencies {
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
implementation 'androidx.appcompat:appcompat:1.3.0-rc01'
implementation 'androidx.core:core-ktx:1.3.2'
implementation "androidx.fragment:fragment-ktx:$fragment_version"
implementation 'androidx.constraintlayout:constraintlayout:2.0.4'
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"

implementation project(':core')
implementation project(':fragment')
implementation project(':compose')
implementation project(':view')
implementation projects.core
implementation projects.fragment
implementation projects.compose
implementation projects.view

implementation libs.kotlin.stdlib

implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation libs.androidx.activity.core
implementation libs.androidx.fragment.core

implementation libs.androidx.appcompat.core
implementation libs.androidx.core
implementation libs.androidx.constraintlayout.core

// Unit Testing
testImplementation 'junit:junit:4.13.1'
testImplementation libs.junit.core

// Android Testing
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation libs.androidx.test.junit
androidTestImplementation libs.androidx.test.espresso
}
3 changes: 3 additions & 0 deletions settings.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
enableFeaturePreview("TYPESAFE_PROJECT_ACCESSORS")
enableFeaturePreview("VERSION_CATALOGS")

include ':sample'
include ':core'
include ':fragment'
Expand Down
19 changes: 10 additions & 9 deletions view/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -49,20 +49,21 @@ afterEvaluate {
}

dependencies {
api project(':core')
api projects.core

implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
implementation libs.kotlin.stdlib

implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-viewmodel-savedstate:$lifecycle_version"
implementation libs.androidx.viewmodel.core
implementation libs.androidx.viewmodel.savedstate

implementation "androidx.fragment:fragment-ktx:$fragment_version"
implementation "androidx.navigation:navigation-runtime-ktx:$navigation_version"
implementation libs.androidx.activity.core
implementation libs.androidx.fragment.core
implementation libs.androidx.navigation.runtime

// Unit Testing
testImplementation "junit:junit:$junit_version"
testImplementation libs.junit.core

// Android Testing
androidTestImplementation 'androidx.test.ext:junit:1.1.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation libs.androidx.test.junit
androidTestImplementation libs.androidx.test.espresso
}

0 comments on commit 559943a

Please sign in to comment.