diff --git a/app/build.gradle b/app/build.gradle index 2345be40f5..dc3a7e1e60 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -16,11 +16,11 @@ import org.gradle.internal.jvm.Jvm buildscript { dependencies { classpath "com.android.tools.build:gradle:$androidPluginVersion" - classpath 'com.github.spotbugs.snom:spotbugs-gradle-plugin:6.1.7' + classpath "com.github.spotbugs.snom:spotbugs-gradle-plugin:6.1.7" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "io.gitlab.arturbosch.detekt:detekt-gradle-plugin:1.23.8" classpath "commons-httpclient:commons-httpclient:3.1@jar" // remove after entire switch to lib v2 - classpath 'com.karumi:shot:6.1.0' + classpath "com.karumi:shot:6.1.0" classpath "org.jacoco:org.jacoco.core:$jacoco_version" classpath "org.jacoco:org.jacoco.report:$jacoco_version" classpath "org.jacoco:org.jacoco.agent:$jacoco_version" @@ -31,36 +31,36 @@ plugins { id "org.jetbrains.kotlin.plugin.compose" version "2.1.10" id "com.diffplug.spotless" version "6.25.0" id "org.jetbrains.kotlin.kapt" version "2.1.10" - id 'com.google.devtools.ksp' version '2.1.10-1.0.31' apply false + id "com.google.devtools.ksp" version "2.1.10-1.0.31" apply false } -apply plugin: 'com.android.application' +apply plugin: "com.android.application" -apply plugin: 'kotlin-android' -apply plugin: 'kotlin-parcelize' -apply plugin: 'checkstyle' -apply plugin: 'pmd' +apply plugin: "kotlin-android" +apply plugin: "kotlin-parcelize" +apply plugin: "checkstyle" +apply plugin: "pmd" apply from: "$rootProject.projectDir/jacoco.gradle" -apply plugin: 'com.github.spotbugs' -apply plugin: 'io.gitlab.arturbosch.detekt' +apply plugin: "com.github.spotbugs" +apply plugin: "io.gitlab.arturbosch.detekt" // needed to make renovate run without shot, as shot requires Android SDK // https://github.com/pedrovgs/Shot/issues/300 if (shotTest) { - apply plugin: 'shot' + apply plugin: "shot" } -apply plugin: 'com.google.devtools.ksp' +apply plugin: "com.google.devtools.ksp" println "Gradle uses Java ${Jvm.current()}" configurations { configureEach { - exclude group: 'org.jetbrains', module: 'annotations-java5' // via prism4j, already using annotations explicitly + exclude group: "org.jetbrains", module: "annotations-java5" // via prism4j, already using annotations explicitly // check for updates every build resolutionStrategy { - cacheChangingModulesFor 0, 'seconds' + cacheChangingModulesFor 0, "seconds" exclude group: "org.jetbrains.kotlinx", module: "kotlinx-coroutines-debug" } } @@ -85,18 +85,18 @@ def versionBuild = 0 // 0-50=Alpha / 51-98=RC / 90-99=stable def ndkEnv = new HashMap() file("$project.rootDir/ndk.env").readLines().each() { - def (key, value) = it.tokenize('=') + def (key, value) = it.tokenize("=") ndkEnv.put(key, value) } -def perfAnalysis = project.hasProperty('perfAnalysis') +def perfAnalysis = project.hasProperty("perfAnalysis") android { // install this NDK version and Cmake to produce smaller APKs. Build will still work if not installed ndkVersion "${ndkEnv.get("NDK_VERSION")}" - namespace 'com.owncloud.android' + namespace "com.owncloud.android" testNamespace "${namespace}.test" androidResources { @@ -109,8 +109,8 @@ android { targetSdkVersion 35 compileSdk 35 - buildConfigField 'boolean', 'CI', ciBuild.toString() - buildConfigField 'boolean', 'RUNTIME_PERF_ANALYSIS', perfAnalysis.toString() + buildConfigField "boolean", "CI", ciBuild.toString() + buildConfigField "boolean", "RUNTIME_PERF_ANALYSIS", perfAnalysis.toString() javaCompileOptions { annotationProcessorOptions { @@ -127,7 +127,7 @@ android { testInstrumentationRunnerArgument "TEST_SERVER_URL", "${NC_TEST_SERVER_BASEURL}" testInstrumentationRunnerArgument "TEST_SERVER_USERNAME", "${NC_TEST_SERVER_USERNAME}" testInstrumentationRunnerArgument "TEST_SERVER_PASSWORD", "${NC_TEST_SERVER_PASSWORD}" - testInstrumentationRunnerArguments disableAnalytics: 'true' + testInstrumentationRunnerArguments disableAnalytics: "true" versionCode versionMajor * 10000000 + versionMinor * 10000 + versionPatch * 100 + versionBuild @@ -146,7 +146,7 @@ android { buildTypes { debug { - testCoverageEnabled(project.hasProperty('coverage')) + testCoverageEnabled(project.hasProperty("coverage")) resConfigs "xxxhdpi" } } @@ -158,17 +158,17 @@ android { productFlavors { // used for f-droid generic { - applicationId 'com.nextcloud.client' + applicationId "com.nextcloud.client" dimension "default" } gplay { - applicationId 'com.nextcloud.client' + applicationId "com.nextcloud.client" dimension "default" } huawei { - applicationId 'com.nextcloud.client' + applicationId "com.nextcloud.client" dimension "default" } @@ -197,18 +197,18 @@ android { // see http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Configuring-the-Structure packagingOptions { resources { - excludes += 'META-INF/LICENSE*' - excludes += 'META-INF/versions/9/OSGI-INF/MANIFEST*' - pickFirst 'MANIFEST.MF' // workaround for duplicated manifest on some dependencies + excludes += "META-INF/LICENSE*" + excludes += "META-INF/versions/9/OSGI-INF/MANIFEST*" + pickFirst "MANIFEST.MF" // workaround for duplicated manifest on some dependencies } } tasks.register("checkstyle", Checkstyle) { configFile = file("${rootProject.projectDir}/checkstyle.xml") configProperties.checkstyleSuppressionsPath = file("${project.rootDir}/config/quality/checkstyle/suppressions.xml").absolutePath - source 'src' - include '**/*.java' - exclude '**/gen/**' + source "src" + include "**/*.java" + exclude "**/gen/**" classpath = files() } @@ -217,9 +217,9 @@ android { ignoreFailures = true // should continue checking ruleSets = [] - source 'src' - include '**/*.java' - exclude '**/gen/**' + source "src" + include "**/*.java" + exclude "**/gen/**" reports { xml { @@ -231,7 +231,7 @@ android { } } - check.dependsOn 'checkstyle', 'spotbugsGplayDebug', 'pmd', 'lint', 'spotlessKotlinCheck', 'detekt' + check.dependsOn "checkstyle", "spotbugsGplayDebug", "pmd", "lint", "spotlessKotlinCheck", "detekt" buildFeatures { dataBinding true @@ -252,7 +252,7 @@ android { lint { abortOnError false checkGeneratedSources true - disable 'MissingTranslation', 'GradleDependency', 'VectorPath', 'IconMissingDensityFolder', 'IconDensities', 'GoogleAppIndexingWarning', 'MissingDefaultResource', 'InvalidPeriodicWorkRequestInterval', 'StringFormatInvalid', 'MissingQuantity' + disable "MissingTranslation", "GradleDependency", "VectorPath", "IconMissingDensityFolder", "IconDensities", "GoogleAppIndexingWarning", "MissingDefaultResource", "InvalidPeriodicWorkRequestInterval", "StringFormatInvalid", "MissingQuantity" htmlOutput file("$project.buildDir/reports/lint/lint.html") htmlReport true } @@ -269,7 +269,7 @@ android { dependencies { implementation("com.github.nextcloud:android-library:$androidLibraryVersion") { - exclude group: 'org.ogce', module: 'xpp3' // unused in Android and brings wrong Junit version + exclude group: "org.ogce", module: "xpp3" // unused in Android and brings wrong Junit version } // Jetpack Compose @@ -280,51 +280,51 @@ dependencies { debugImplementation("androidx.compose.ui:ui-tooling") implementation("androidx.compose.ui:ui-tooling-preview") - compileOnly 'org.jbundle.util.osgi.wrapped:org.jbundle.util.osgi.wrapped.org.apache.http.client:4.1.2' + compileOnly "org.jbundle.util.osgi.wrapped:org.jbundle.util.osgi.wrapped.org.apache.http.client:4.1.2" // remove after entire switch to lib v2 implementation "commons-httpclient:commons-httpclient:3.1@jar" // remove after entire switch to lib v2 - implementation 'org.apache.jackrabbit:jackrabbit-webdav:2.13.5' // remove after entire switch to lib v2 - implementation 'androidx.constraintlayout:constraintlayout:2.2.1' - implementation 'androidx.legacy:legacy-support-v4:1.0.0' - implementation 'com.google.android.material:material:1.12.0' - implementation 'com.jakewharton:disklrucache:2.0.2' + implementation "org.apache.jackrabbit:jackrabbit-webdav:2.13.5" // remove after entire switch to lib v2 + implementation "androidx.constraintlayout:constraintlayout:2.2.1" + implementation "androidx.legacy:legacy-support-v4:1.0.0" + implementation "com.google.android.material:material:1.12.0" + implementation "com.jakewharton:disklrucache:2.0.2" implementation "androidx.appcompat:appcompat:$appCompatVersion" - implementation 'androidx.webkit:webkit:1.12.1' - implementation 'androidx.cardview:cardview:1.0.0' - implementation 'androidx.exifinterface:exifinterface:1.4.0' + implementation "androidx.webkit:webkit:1.12.1" + implementation "androidx.cardview:cardview:1.0.0" + implementation "androidx.exifinterface:exifinterface:1.4.0" implementation "androidx.lifecycle:lifecycle-viewmodel-ktx:2.8.7" implementation "androidx.lifecycle:lifecycle-service:2.8.7" implementation "androidx.work:work-runtime:$workRuntime" implementation "androidx.work:work-runtime-ktx:$workRuntime" implementation "androidx.fragment:fragment-ktx:1.8.6" - implementation 'com.github.albfernandez:juniversalchardet:2.0.3' // need this version for Android <7 - compileOnly 'com.google.code.findbugs:annotations:3.0.1u2' - implementation 'commons-io:commons-io:2.18.0' - implementation 'org.greenrobot:eventbus:3.3.1' - implementation 'com.googlecode.ez-vcard:ez-vcard:0.12.1' - implementation 'org.lukhnos:nnio:0.3.1' - implementation 'org.bouncycastle:bcpkix-jdk18on:1.80' - implementation 'com.google.code.gson:gson:2.12.1' - implementation 'com.github.nextcloud-deps:sectioned-recyclerview:0.6.1' - implementation 'com.github.chrisbanes:PhotoView:2.3.0' - implementation 'pl.droidsonroids.gif:android-gif-drawable:1.2.29' - implementation 'com.github.nextcloud-deps:qrcodescanner:0.1.2.4' // 'com.github.blikoon:QRCodeScanner:0.1.2' - implementation 'com.google.android.flexbox:flexbox:3.0.0' - implementation('com.github.bumptech.glide:glide:3.8.0') { + implementation "com.github.albfernandez:juniversalchardet:2.0.3" // need this version for Android <7 + compileOnly "com.google.code.findbugs:annotations:3.0.1u2" + implementation "commons-io:commons-io:2.18.0" + implementation "org.greenrobot:eventbus:3.3.1" + implementation "com.googlecode.ez-vcard:ez-vcard:0.12.1" + implementation "org.lukhnos:nnio:0.3.1" + implementation "org.bouncycastle:bcpkix-jdk18on:1.80" + implementation "com.google.code.gson:gson:2.12.1" + implementation "com.github.nextcloud-deps:sectioned-recyclerview:0.6.1" + implementation "com.github.chrisbanes:PhotoView:2.3.0" + implementation "pl.droidsonroids.gif:android-gif-drawable:1.2.29" + implementation "com.github.nextcloud-deps:qrcodescanner:0.1.2.4" // "com.github.blikoon:QRCodeScanner:0.1.2" + implementation "com.google.android.flexbox:flexbox:3.0.0" + implementation("com.github.bumptech.glide:glide:3.8.0") { exclude group: "com.android.support" } - implementation 'com.caverock:androidsvg:1.4' - implementation 'androidx.annotation:annotation:1.9.1' - implementation 'com.vanniktech:emoji-google:0.21.0' + implementation "com.caverock:androidsvg:1.4" + implementation "androidx.annotation:annotation:1.9.1" + implementation "com.vanniktech:emoji-google:0.21.0" implementation("androidx.lifecycle:lifecycle-runtime-ktx:2.8.7") // document scanner not available on FDroid (generic) due to OpenCV binaries - gplayImplementation project(':appscan') - huaweiImplementation project(':appscan') - qaImplementation project(':appscan') + gplayImplementation project(":appscan") + huaweiImplementation project(":appscan") + qaImplementation project(":appscan") - spotbugsPlugins 'com.h3xstream.findsecbugs:findsecbugs-plugin:1.13.0' - spotbugsPlugins 'com.mebigfatguy.fb-contrib:fb-contrib:7.6.9' + spotbugsPlugins "com.h3xstream.findsecbugs:findsecbugs-plugin:1.13.0" + spotbugsPlugins "com.mebigfatguy.fb-contrib:fb-contrib:7.6.9" implementation "com.google.dagger:dagger:$daggerVersion" implementation "com.google.dagger:dagger-android:$daggerVersion" @@ -332,17 +332,17 @@ dependencies { kapt "com.google.dagger:dagger-compiler:$daggerVersion" kapt "com.google.dagger:dagger-android-processor:$daggerVersion" - implementation 'org.conscrypt:conscrypt-android:2.5.3' + implementation "org.conscrypt:conscrypt-android:2.5.3" implementation "androidx.media3:media3-ui:$androidxMediaVersion" implementation "androidx.media3:media3-session:$androidxMediaVersion" implementation "androidx.media3:media3-exoplayer:$androidxMediaVersion" implementation "androidx.media3:media3-datasource-okhttp:$androidxMediaVersion" - implementation 'me.zhanghai.android.fastscroll:library:1.3.0' + implementation "me.zhanghai.android.fastscroll:library:1.3.0" // Shimmer animation - implementation 'io.github.elye:loaderviewlibrary:3.0.0' + implementation "io.github.elye:loaderviewlibrary:3.0.0" // dependencies for markdown rendering implementation "io.noties.markwon:core:$markwonVersion" @@ -356,33 +356,33 @@ dependencies { kapt "io.noties:prism4j-bundler:$prismVersion" // dependencies for image cropping and rotation - implementation 'com.vanniktech:android-image-cropper:4.6.0' + implementation "com.vanniktech:android-image-cropper:4.6.0" - implementation 'org.osmdroid:osmdroid-android:6.1.20' + implementation "org.osmdroid:osmdroid-android:6.1.20" - implementation('org.mnode.ical4j:ical4j:3.0.0') { - ['org.apache.commons', 'commons-logging'].each { + implementation("org.mnode.ical4j:ical4j:3.0.0") { + ["org.apache.commons", "commons-logging"].each { exclude group: "$it" } } if (perfAnalysis) { - debugImplementation 'com.squareup.leakcanary:leakcanary-android:2.14' + debugImplementation "com.squareup.leakcanary:leakcanary-android:2.14" } // dependencies for local unit tests - testImplementation 'junit:junit:4.13.2' + testImplementation "junit:junit:4.13.2" testImplementation "org.mockito:mockito-core:$mockitoVersion" testImplementation "androidx.test:core:$androidxTestVersion" - testImplementation 'org.json:json:20250107' + testImplementation "org.json:json:20250107" testImplementation "org.mockito.kotlin:mockito-kotlin:$mockitoKotlinVersion" - testImplementation 'androidx.arch.core:core-testing:2.2.0' + testImplementation "androidx.arch.core:core-testing:2.2.0" testImplementation "io.mockk:mockk:$mockkVersion" testImplementation "io.mockk:mockk-android:$mockkVersion" // dependencies for instrumented tests // JUnit4 Rules - androidTestImplementation 'androidx.test.ext:junit:1.2.1' + androidTestImplementation "androidx.test.ext:junit:1.2.1" androidTestImplementation "androidx.test:rules:$androidxTestVersion" // Android JUnit Runner androidTestImplementation "androidx.test:runner:1.6.2" @@ -398,27 +398,27 @@ dependencies { androidTestImplementation "androidx.test.espresso:espresso-idling-resource:$espressoVersion" // Mocking support - androidTestImplementation 'com.github.tmurakami:dexopener:2.0.5' // required to allow mocking on API 27 and older + androidTestImplementation "com.github.tmurakami:dexopener:2.0.5" // required to allow mocking on API 27 and older androidTestImplementation "org.mockito.kotlin:mockito-kotlin:$mockitoKotlinVersion" androidTestImplementation "org.mockito:mockito-core:$mockitoVersion" androidTestImplementation("org.mockito:mockito-android:$mockitoVersion") androidTestImplementation "io.mockk:mockk-android:$mockkVersion" - androidTestImplementation 'androidx.arch.core:core-testing:2.2.0' + androidTestImplementation "androidx.arch.core:core-testing:2.2.0" androidTestImplementation "com.facebook.testing.screenshot:core:0.15.0" // UIAutomator - for cross-app UI tests, and to grant screen is turned on in Espresso tests - // androidTestImplementation 'androidx.test.uiautomator:uiautomator:2.2.0' + // androidTestImplementation "androidx.test.uiautomator:uiautomator:2.2.0" // fix conflict in dependencies; see http://g.co/androidstudio/app-test-app-conflict for details //androidTestImplementation "com.android.support:support-annotations:${supportLibraryVersion}" - androidTestImplementation 'tools.fastlane:screengrab:2.1.1' + androidTestImplementation "tools.fastlane:screengrab:2.1.1" implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version" implementation "com.github.stateless4j:stateless4j:2.6.0" // upon each update first test: new registration, receive push gplayImplementation "com.google.firebase:firebase-messaging:24.1.0" - gplayImplementation 'com.google.android.gms:play-services-base:18.5.0' - gplayImplementation 'com.google.android.play:review-ktx:2.0.2' + gplayImplementation "com.google.android.gms:play-services-base:18.5.0" + gplayImplementation "com.google.android.play:review-ktx:2.0.2" implementation "com.github.nextcloud.android-common:ui:$androidCommonLibraryVersion" @@ -429,15 +429,15 @@ dependencies { implementation "io.coil-kt:coil:2.7.0" // splash screen dependency ref: https://developer.android.com/develop/ui/views/launch/splash-screen/migrate - implementation 'androidx.core:core-splashscreen:1.0.1' + implementation "androidx.core:core-splashscreen:1.0.1" } configurations.configureEach { resolutionStrategy { - cacheChangingModulesFor 0, 'seconds' - force 'org.objenesis:objenesis:3.4' + cacheChangingModulesFor 0, "seconds" + force "org.objenesis:objenesis:3.4" eachDependency { details -> - if ('org.jacoco' == details.requested.group) { + if ("org.jacoco" == details.requested.group) { details.useVersion "$jacoco_version" } } @@ -483,7 +483,7 @@ jacoco { spotbugs { ignoreFailures = true // should continue checking effort = Effort.MAX - reportLevel = Confidence.valueOf('MEDIUM') + reportLevel = Confidence.valueOf("MEDIUM") } tasks.withType(SpotBugsTask){task -> @@ -500,11 +500,11 @@ tasks.withType(SpotBugsTask){task -> html { required = true outputLocation = file("$project.buildDir/reports/spotbugs/spotbugs.html") - stylesheet = 'fancy.xsl' + stylesheet = "fancy.xsl" } } } ksp { - arg('room.schemaLocation', "$projectDir/schemas") + arg("room.schemaLocation", "$projectDir/schemas") } diff --git a/appscan/.gitignore b/appscan/.gitignore deleted file mode 100644 index a6de150487..0000000000 --- a/appscan/.gitignore +++ /dev/null @@ -1,3 +0,0 @@ -# SPDX-FileCopyrightText: 2023-2024 Nextcloud GmbH and Nextcloud contributors -# SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only -/build \ No newline at end of file diff --git a/appscan/build.gradle b/appscan/build.gradle index 228dab43be..012f63009c 100644 --- a/appscan/build.gradle +++ b/appscan/build.gradle @@ -14,11 +14,11 @@ buildscript { } } -apply plugin: 'com.android.library' -apply plugin: 'kotlin-android' +apply plugin: "com.android.library" +apply plugin: "kotlin-android" android { - namespace 'com.nextcloud.appscan' + namespace "com.nextcloud.appscan" defaultConfig { minSdk 25 @@ -40,7 +40,7 @@ android { } kotlinOptions { - jvmTarget = '17' + jvmTarget = "17" } } diff --git a/build.gradle b/build.gradle index 43b0dcb925..609aab67d9 100644 --- a/build.gradle +++ b/build.gradle @@ -12,16 +12,16 @@ buildscript { ext { androidLibraryVersion ="be43184f87164bd5ec4f1d2ed912665203433321" androidCommonLibraryVersion = "0.25.0" - androidPluginVersion = '8.9.0' - androidxMediaVersion = '1.5.1' + androidPluginVersion = "8.9.0" + androidxMediaVersion = "1.5.1" androidxTestVersion = "1.6.1" - appCompatVersion = '1.7.0' + appCompatVersion = "1.7.0" checkerVersion = "3.21.2" daggerVersion = "2.55" documentScannerVersion = "1.1.1" espressoVersion = "3.6.1" - jacoco_version = '0.8.12' - kotlin_version = '2.1.10' + jacoco_version = "0.8.12" + kotlin_version = "2.1.10" markwonVersion = "4.6.2" mockitoVersion = "4.11.0" mockitoKotlinVersion = "4.1.0" @@ -50,18 +50,18 @@ subprojects { } } -tasks.register('clean', Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } -tasks.register('installGitHooks', Copy) { +tasks.register("installGitHooks", Copy) { def sourceFolder = "${rootProject.projectDir}/scripts/hooks" def destFolder = "${rootProject.projectDir}/.git/hooks" description = "Install git hooks" from(sourceFolder) { - include '*' + include "*" } into destFolder diff --git a/jacoco.gradle b/jacoco.gradle index 0106717573..f3a7090b67 100644 --- a/jacoco.gradle +++ b/jacoco.gradle @@ -1,4 +1,4 @@ -apply plugin: 'jacoco' +apply plugin: "jacoco" jacoco { toolVersion = "$jacoco_version" @@ -10,7 +10,7 @@ subprojects { configurations.all { resolutionStrategy { eachDependency { details -> - if ('org.jacoco' == details.requested.group) { + if ("org.jacoco" == details.requested.group) { details.useVersion "$jacocoVersion" } } @@ -20,9 +20,9 @@ subprojects { project.afterEvaluate { project -> - tasks.withType(Test) { + tasks.withType(Test).configureEach { jacoco.includeNoLocationClasses = true - jacoco.excludes = ['jdk.internal.*'] + jacoco.excludes = ["jdk.internal.*"] } final flavor = "Gplay" @@ -39,57 +39,56 @@ project.afterEvaluate { project -> } final fileFilter = [ - // data binding - '**/databinding/*', - 'android/databinding/**/*.class', - '**/android/databinding/*Binding.class', - '**/android/databinding/*', - '**/androidx/databinding/*', - '**/BR.*', - // android - '**/R.class', - '**/R$*.class', - '**/BuildConfig.*', - '**/Manifest*.*', - '**/*Test*.*', - 'android/**/*.*', - // kotlin - '**/*MapperImpl*.*', - '**/*$ViewInjector*.*', - '**/*$ViewBinder*.*', - '**/BuildConfig.*', - '**/*Component*.*', - '**/*BR*.*', - '**/Manifest*.*', - '**/*$Lambda$*.*', - '**/*Companion*.*', - '**/*Module*.*', - '**/*Dagger*.*', - '**/*Hilt*.*', - '**/*MembersInjector*.*', - '**/*_MembersInjector.class', - '**/*_Factory*.*', - '**/*_Provide*Factory*.*', - '**/*Extensions*.*', - // sealed and data classes - '**/*$Result.*', - '**/*$Result$*.*', - // adapters generated by moshi - '**/*JsonAdapter.*', - // Hilt - '**/*Module.kt', - '**/di/**', - 'dagger.hilt.internal/*', - 'hilt_aggregated_deps/*', + // data binding + "**/databinding/*", + "android/databinding/**/*.class", + "**/android/databinding/*Binding.class", + "**/android/databinding/*", + "**/androidx/databinding/*", + "**/BR.*", + // android + "**/R.class", + "**/R\$*.class", + "**/BuildConfig.*", + "**/Manifest*.*", + "**/*Test*.*", + "android/**/*.*", + // kotlin + "**/*MapperImpl*.*", + "**/*\$ViewInjector*.*", + "**/*\$ViewBinder*.*", + "**/BuildConfig.*", + "**/*Component*.*", + "**/*BR*.*", + "**/Manifest*.*", + "**/*\$Lambda\$*.*", + "**/*Companion*.*", + "**/*Module*.*", + "**/*Dagger*.*", + "**/*Hilt*.*", + "**/*MembersInjector*.*", + "**/*_MembersInjector.class", + "**/*_Factory*.*", + "**/*_Provide*Factory*.*", + "**/*Extensions*.*", + // sealed and data classes + "**/*\$Result.*", + "**/*\$Result\$*.*", + // adapters generated by moshi + "**/*JsonAdapter.*", + // Hilt + "**/*Module.kt", + "**/di/**", + "dagger.hilt.internal/*", + "hilt_aggregated_deps/*", - '**/*$Result.*', /* filtering `sealed` and `data` classes */ - '**/*$Result$*.*',/* filtering `sealed` and `data` classes */ - '**/*Args*.*', /* filtering Navigation Component generated classes */ - '**/*Directions*.*', /* filtering Navigation Component generated classes */ - '**/*inlined*.class', /* filtering inlined classes */ - '**/composables/**' - /* INSERT ANY OTHER JUNK YOU WANT FILTERED OUT HERE */ - ] + "**/*\$Result.*", /* filtering `sealed` and `data` classes */ + "**/*\$Result\$*.*",/* filtering `sealed` and `data` classes */ + "**/*Args*.*", /* filtering Navigation Component generated classes */ + "**/*Directions*.*", /* filtering Navigation Component generated classes */ + "**/*inlined*.class", /* filtering inlined classes */ + "**/composables/**" + /* INSERT ANY OTHER JUNK YOU WANT FILTERED OUT HERE */] final androidKotlinTree = fileTree(dir: "${project.buildDir}/tmp/kotlin-classes/${variant}", excludes: fileFilter) final kotlinTree = fileTree(dir: "${project.buildDir}/classes/kotlin/main", excludes: fileFilter) @@ -101,9 +100,7 @@ project.afterEvaluate { project -> sourceDirectories.setFrom files([mainSrc, productFlavorSrc, buildTypeSrc]) classDirectories.setFrom files([androidKotlinTree, kotlinTree, javacTree]) - executionData.setFrom fileTree(dir: project.buildDir, includes: [ - "jacoco/test${variant.capitalize()}UnitTest.exec", - "outputs/unit_test_code_coverage/${variant}UnitTest/test${variant.capitalize()}UnitTest.exec", - ]) + executionData.setFrom fileTree(dir: project.buildDir, includes: ["jacoco/test${variant.capitalize()}UnitTest.exec", + "outputs/unit_test_code_coverage/${variant}UnitTest/test${variant.capitalize()}UnitTest.exec",]) } } diff --git a/settings.gradle b/settings.gradle index 352229bd93..3b761b63ff 100644 --- a/settings.gradle +++ b/settings.gradle @@ -4,19 +4,19 @@ * SPDX-FileCopyrightText: 2014-2024 Nextcloud GmbH and Nextcloud contributors * SPDX-License-Identifier: AGPL-3.0-or-later OR GPL-2.0-only */ -rootProject.name = 'Nextcloud' +rootProject.name = "Nextcloud" -include ':app' -include ':appscan' +include ":app" +include ":appscan" -//includeBuild('../android-common') { +//includeBuild("../android-common") { // dependencySubstitution { -// substitute module('com.github.nextcloud.android-common:ui') using project(':ui') +// substitute module("com.github.nextcloud.android-common:ui") using project(":ui") // } //} -//includeBuild('../android-library') { +//includeBuild("../android-library") { // dependencySubstitution { -// substitute module('com.github.nextcloud:android-library') using project(':library') +// substitute module("com.github.nextcloud:android-library") using project(":library") // } //}