From f4f20d3bc6ff34714ef74496d5ab84751eadc3b4 Mon Sep 17 00:00:00 2001 From: Gildenio Neto Date: Fri, 18 Mar 2022 09:15:01 -0300 Subject: [PATCH 1/3] Update gitigonore --- .gitignore | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.gitignore b/.gitignore index 2b75303ac..5cd58a667 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,14 @@ /build /captures .externalNativeBuild +*.idea + +# IntelliJ +.idea/workspace.xml +.idea/tasks.xml +.idea/gradle.xml +.idea/assetWizardSettings.xml +.idea/dictionaries +.idea/libraries +.idea/caches +/.idea/ From de580825ac1bbbab9761c29dfbf033a49c4a6377 Mon Sep 17 00:00:00 2001 From: Gildenio Neto Date: Fri, 18 Mar 2022 09:56:10 -0300 Subject: [PATCH 2/3] Config build gradle, update version gradle and AndroidManifest --- app/build.gradle | 37 ++++++++++------------- app/src/main/AndroidManifest.xml | 7 +++-- build.gradle | 38 ++++++++++++------------ gradle/wrapper/gradle-wrapper.properties | 2 +- 4 files changed, 41 insertions(+), 43 deletions(-) diff --git a/app/build.gradle b/app/build.gradle index a7fbdc0e9..fc25a7372 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -1,24 +1,25 @@ -apply plugin: 'com.android.application' - -apply plugin: 'kotlin-android' - -apply plugin: 'kotlin-android-extensions' - -apply plugin: 'kotlin-kapt' +plugins { + id 'com.android.application' + id 'kotlin-android' + id 'kotlin-kapt' + id 'kotlin-parcelize' +} android { - compileSdkVersion 29 + compileSdkVersion 32 defaultConfig { applicationId "com.picpay.desafio.android" minSdkVersion 21 - targetSdkVersion 29 + targetSdkVersion 32 versionCode 1 versionName "1.0" + } - vectorDrawables.useSupportLibrary = true - - testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" + viewBinding.enabled = true + testOptions { + unitTests.returnDefaultValues = true } + buildTypes { debug {} @@ -30,8 +31,8 @@ android { } compileOptions { - sourceCompatibility 1.8 - targetCompatibility 1.8 + sourceCompatibility JavaVersion.VERSION_1_8 + targetCompatibility JavaVersion.VERSION_1_8 } kotlinOptions { @@ -45,19 +46,16 @@ dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" implementation "androidx.core:core-ktx:$core_ktx_version" + implementation "androidx.fragment:fragment-ktx:$fragment_ktx_version" implementation "androidx.appcompat:appcompat:$appcompat_version" implementation "androidx.constraintlayout:constraintlayout:$constraintlayout_version" - implementation "com.google.android.material:material:$material_version" implementation "org.koin:koin-core:$koin_version" implementation "org.koin:koin-android:$koin_version" implementation "org.koin:koin-androidx-viewmodel:$koin_version" - implementation "com.google.dagger:dagger:$dagger_version" - kapt "com.google.dagger:dagger-compiler:$dagger_version" - implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:$lifecycle_version" implementation "androidx.lifecycle:lifecycle-livedata-ktx:$lifecycle_version" implementation "androidx.lifecycle:lifecycle-runtime-ktx:$lifecycle_version" @@ -66,9 +64,6 @@ dependencies { implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:$coroutines_version" testImplementation "org.jetbrains.kotlinx:kotlinx-coroutines-test:$coroutines_version" - implementation "io.reactivex.rxjava2:rxjava:$rxjava_version" - implementation "io.reactivex.rxjava2:rxandroid:$rxandroid_version" - implementation 'com.google.code.gson:gson:2.8.6' implementation "com.squareup.retrofit2:retrofit:$retrofit_version" diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 7bdf2ce38..f61fc9b87 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -13,14 +13,17 @@ android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" android:theme="@style/AppTheme" - tools:ignore="AllowBackup,GoogleAppIndexingWarning"> - + tools:ignore="AllowBackup,GoogleAppIndexingWarning,UnusedAttribute"> + + + \ No newline at end of file diff --git a/build.gradle b/build.gradle index 7d1b94f34..c986d2bb6 100644 --- a/build.gradle +++ b/build.gradle @@ -2,43 +2,44 @@ buildscript { ext { - kotlin_version = '1.3.61' + kotlin_version = '1.6.10' - appcompat_version = '1.1.0' - core_ktx_version = '1.2.0' + appcompat_version = '1.4.1' + core_ktx_version = '1.7.0' + fragment_ktx_version = "1.4.1" core_testing_version = '2.1.0' - constraintlayout_version = '1.1.3' - material_version = "1.1.0" + constraintlayout_version = '2.1.3' + material_version = "1.5.0" moshi_version = '1.8.0' - retrofit_version = '2.7.1' - okhttp_version = '4.3.1' + retrofit_version = '2.9.0' + okhttp_version = '4.9.2' picasso_version = '2.71828' circleimageview_version = '3.0.0' - junit_version = '4.12' - mockito_version = '2.27.0' + junit_version = '4.13.2' + mockito_version = '4.0.0' mockito_kotlin_version = '2.1.0' - test_runner_version = '1.1.1' - espresso_version = '3.1.1' + test_runner_version = '1.4.0' + espresso_version = '3.4.0' koin_version = "2.0.1" - dagger_version = "2.23.2" - lifecycle_version = "2.2.0" - coroutines_version = "1.3.3" + dagger_version = "2.28.3" + lifecycle_version = "2.4.1" + coroutines_version = "1.5.2" rxjava_version = "2.2.17" rxandroid_version = "2.1.1" - core_ktx_test_version = "1.2.0" + core_ktx_test_version = "1.4.0" } repositories { google() jcenter() - } + dependencies { - classpath 'com.android.tools.build:gradle:3.5.3' - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" + classpath 'com.android.tools.build:gradle:7.1.2' + classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.6.10" // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files } @@ -48,7 +49,6 @@ allprojects { repositories { google() jcenter() - } } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 31680f1d6..406030638 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-5.4.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.2-all.zip From 11dffc5eef394e6604416902575279659fb88f6a Mon Sep 17 00:00:00 2001 From: Gildenio Neto Date: Fri, 18 Mar 2022 10:20:52 -0300 Subject: [PATCH 3/3] Update kotlinx.android.parcel.Parcelize to kotlinx.parcelize.Parcelize --- app/src/main/java/com/picpay/desafio/android/User.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/com/picpay/desafio/android/User.kt b/app/src/main/java/com/picpay/desafio/android/User.kt index aa28171c9..afd231469 100644 --- a/app/src/main/java/com/picpay/desafio/android/User.kt +++ b/app/src/main/java/com/picpay/desafio/android/User.kt @@ -2,7 +2,7 @@ package com.picpay.desafio.android import android.os.Parcelable import com.google.gson.annotations.SerializedName -import kotlinx.android.parcel.Parcelize +import kotlinx.parcelize.Parcelize @Parcelize data class User(