Skip to content

Commit

Permalink
Update Kotlin + Android dependencies
Browse files Browse the repository at this point in the history
* Update Kotlin to 1.7.21
* Migrate Hilt to Gradle Plugin DSL and use updated package name
* Update dependencies
* Misc cleanup of build scripts
  • Loading branch information
nickbeth committed Feb 6, 2023
1 parent 5137d7d commit bac4ec2
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 15 deletions.
18 changes: 9 additions & 9 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ plugins {
id 'com.android.application'
id 'kotlin-android'
id 'kotlin-kapt'
id 'dagger.hilt.android.plugin'
id 'com.google.dagger.hilt.android'
id 'idea'
id 'org.jetbrains.kotlin.plugin.serialization' version "$kotlin_version"
}
Expand Down Expand Up @@ -153,24 +153,24 @@ android {

dependencies {
/* Google */
implementation 'androidx.core:core-ktx:1.8.0'
implementation 'androidx.appcompat:appcompat:1.5.0'
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.appcompat:appcompat:1.6.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.preference:preference-ktx:1.2.0'
implementation 'androidx.activity:activity-ktx:1.6.1'
implementation 'com.google.android.material:material:1.6.1'
implementation 'com.google.android.material:material:1.8.0'
implementation 'androidx.documentfile:documentfile:1.0.1'
implementation 'androidx.swiperefreshlayout:swiperefreshlayout:1.1.0'
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version"
implementation 'androidx.fragment:fragment-ktx:1.5.2'
implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.5.1"
implementation "androidx.lifecycle:lifecycle-livedata-ktx:2.5.1"
implementation 'androidx.fragment:fragment-ktx:1.5.5'
implementation "com.google.dagger:hilt-android:$hilt_version"
kapt "com.google.dagger:hilt-android-compiler:$hilt_version"
kapt "com.google.dagger:hilt-compiler:$hilt_version"
implementation 'com.google.android.flexbox:flexbox:3.0.0'

/* Kotlin */
implementation "org.jetbrains.kotlin:kotlin-reflect:$kotlin_version"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:$serialization_version"
implementation "org.jetbrains.kotlinx:kotlinx-serialization-json:1.4.1"

/* JetBrains */
implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk8:$kotlin_version"
Expand Down
13 changes: 7 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@

buildscript {
ext {
kotlin_version = '1.7.10'
serialization_version = '1.3.3'
lifecycle_version = '2.5.1'
hilt_version = '2.43.2'
kotlin_version = '1.7.21'
hilt_version = '2.44.2'
}

repositories {
Expand All @@ -16,20 +14,23 @@ buildscript {
dependencies {
classpath 'com.android.tools.build:gradle:7.2.2'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "com.google.dagger:hilt-android-gradle-plugin:$hilt_version"

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

plugins {
id 'com.google.dagger.hilt.android' version "$hilt_version" apply false
}

allprojects {
repositories {
google()
mavenCentral()
}
}

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

0 comments on commit bac4ec2

Please sign in to comment.