diff --git a/app/build.gradle b/app/build.gradle index 44834951b..d769b618c 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -51,6 +51,22 @@ dependencies { implementation 'com.karumi:dexter:5.0.0' implementation 'androidx.lifecycle:lifecycle-extensions:2.2.0' + // Jetpack Compose + def composeBom = platform('androidx.compose:compose-bom:2024.08.00') + + implementation "androidx.appcompat:appcompat:1.7.0" + implementation "androidx.activity:activity-compose:1.9.1" + implementation "androidx.lifecycle:lifecycle-runtime-ktx:2.8.4" + implementation (composeBom) + implementation "androidx.compose.runtime:runtime" + implementation "androidx.compose.ui:ui" + implementation "androidx.compose.ui:ui-graphics" + implementation "androidx.compose.ui:ui-tooling" + implementation "androidx.compose.foundation:foundation" + implementation "androidx.compose.foundation:foundation-layout" + implementation "androidx.compose.material3:material3" + androidTestImplementation(composeBom) + implementation "com.hannesdorfmann:adapterdelegates4-kotlin-dsl-viewbinding:$ADAPTER_DELEGATES_VERSION" implementation "com.hannesdorfmann:adapterdelegates4-pagination:$ADAPTER_DELEGATES_VERSION" implementation "androidx.paging:paging-runtime-ktx:$PAGING_VERSION" @@ -186,7 +202,7 @@ project.gradle.taskGraph.whenReady { } android { - compileSdkVersion 33 + compileSdkVersion 34 defaultConfig { //applicationId 'fr.free.nrw.commons' @@ -196,7 +212,7 @@ android { setProperty("archivesBaseName", "app-commons-v$versionName-" + getBranchName()) minSdkVersion 21 - targetSdkVersion 33 + targetSdkVersion 34 testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" testInstrumentationRunnerArguments clearPackageData: 'true' @@ -253,11 +269,12 @@ android { } } debug { - testCoverageEnabled true minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt' testProguardFile 'test-proguard-rules.txt' versionNameSuffix "-debug-" + getBranchName() + enableUnitTestCoverage true + enableAndroidTestCoverage true } } @@ -354,13 +371,17 @@ android { targetCompatibility JavaVersion.VERSION_11 } kotlinOptions { - jvmTarget = "1.8" + jvmTarget = "11" } buildToolsVersion buildToolsVersion buildFeatures { viewBinding true + compose true + } + composeOptions { + kotlinCompilerExtensionVersion '1.3.2' } namespace 'fr.free.nrw.commons' lint { diff --git a/build.gradle b/build.gradle index 242b06429..ec3d4f617 100644 --- a/build.gradle +++ b/build.gradle @@ -6,7 +6,7 @@ buildscript { maven { url "https://plugins.gradle.org/m2/" } } dependencies { - classpath 'com.android.tools.build:gradle:8.0.2' + classpath 'com.android.tools.build:gradle:8.5.0' classpath 'com.getkeepsafe.dexcount:dexcount-gradle-plugin:0.8.2' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$KOTLIN_VERSION" classpath 'org.codehaus.groovy:groovy-all:2.4.15' diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index d2e417be9..fb6a72053 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,6 +1,6 @@ #Sun Apr 23 18:22:54 IST 2023 distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists \ No newline at end of file