Skip to content

Commit

Permalink
Merge pull request #2145 from dhis2/version-1.10.0
Browse files Browse the repository at this point in the history
[VERSION-1.10.0] Release 1.10.0
  • Loading branch information
vgarciabnz authored May 9, 2024
2 parents ac711cf + 6c7c539 commit 985e9be
Show file tree
Hide file tree
Showing 583 changed files with 16,442 additions and 2,821 deletions.
15 changes: 13 additions & 2 deletions .idea/gradle.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@ pipeline {
label "ec2-android"
}

options {
disableConcurrentBuilds(abortPrevious: true)
}

stages{
stage('Change to JAVA 17') {
steps {
Expand Down
5 changes: 3 additions & 2 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@ buildscript {
classpath(libs.gradle)
classpath(libs.kotlin)
classpath(libs.ktlint)
classpath(libs.jacoco)
}
}

plugins {
alias(libs.plugins.sonarqube)
alias(libs.plugins.dokka)
}

sonarqube {
Expand Down Expand Up @@ -53,12 +53,13 @@ allprojects {
}

tasks.register("clean", Delete::class) {
delete(rootProject.buildDir)
delete(rootProject.layout.buildDirectory)
}


subprojects {
apply(plugin = "org.jlleitschuh.gradle.ktlint")
apply(plugin = "org.jetbrains.dokka")

//group = GROUP
//version = VERSION_NAME
Expand Down
36 changes: 36 additions & 0 deletions buildSrc/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
/*
* Copyright (c) 2004-2024, University of Oslo
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* Neither the name of the HISP project nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

plugins {
`kotlin-dsl`
}

repositories {
mavenCentral()
gradlePluginPortal()
}
35 changes: 35 additions & 0 deletions buildSrc/settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
/*
* Copyright (c) 2004-2024, University of Oslo
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* Neither the name of the HISP project nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

dependencyResolutionManagement {
versionCatalogs {
create("libs") {
from(files("../gradle/libs.versions.toml"))
}
}
}
44 changes: 44 additions & 0 deletions buildSrc/src/main/kotlin/Props.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
/*
* Copyright (c) 2004-2024, University of Oslo
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* Neither the name of the HISP project nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

object Props {
val GROUP = "org.hisp.dhis"
val POM_NAME = "Core"
val POM_ARTIFACT_ID = "android-core"
val POM_PACKAGING = "aar"
val POM_DESCRIPTION = "Android SDK for DHIS 2."
val POM_URL = "https://github.com/dhis2/dhis2-android-sdk"
val POM_SCM_URL = "https://github.com/dhis2/dhis2-android-sdk"
val POM_SCM_CONNECTION = "scm:git:git://github.com/dhis2/dhis2-android-sdk.git"
val POM_SCM_DEV_CONNECTION = "scm:git:ssh://[email protected]/dhis2/dhis2-android-sdk.git"
val POM_LICENCE_NAME = "BSD"
val POM_LICENCE_URL = "https://opensource.org/licenses/BSD-3-Clause"
val POM_LICENCE_DIST = "repo"
val POM_DEVELOPER_ID = "DHIS 2"
val POM_DEVELOPER_NAME = "DHIS 2"
}
Original file line number Diff line number Diff line change
@@ -1,3 +1,33 @@
/*
* Copyright (c) 2004-2024, University of Oslo
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice, this
* list of conditions and the following disclaimer.
*
* Redistributions in binary form must reproduce the above copyright notice,
* this list of conditions and the following disclaimer in the documentation
* and/or other materials provided with the distribution.
* Neither the name of the HISP project nor the names of its contributors may
* be used to endorse or promote products derived from this software without
* specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
* ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

import org.gradle.testing.jacoco.tasks.JacocoReport

/*
* Copyright (c) 2004-2022, University of Oslo
* All rights reserved.
Expand Down Expand Up @@ -26,15 +56,21 @@
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/

apply(plugin = "jacoco")
plugins {
jacoco
}

jacoco {
toolVersion = "0.8.11"
}

tasks.register("jacocoReport", JacocoReport::class) {
group = "Coverage"
description = "Generate XML/HTML code coverage reports for coverage.ec"

sourceDirectories.setFrom("${project.projectDir}/src/main/java")

val excludes = mutableSetOf<String>(
val excludes = mutableSetOf(
// data binding
"android/databinding/**/*.class",
"**/android/databinding/*Binding.class",
Expand Down Expand Up @@ -84,10 +120,10 @@ tasks.register("jacocoReport", JacocoReport::class) {
"**/*AutoValue_*.*"
)

val javaClasses = fileTree("${buildDir}/intermediates/javac/debug") {
val javaClasses = fileTree(layout.buildDirectory.file("intermediates/javac/debug")) {
exclude(excludes)
}
val kotlinClasses = fileTree("${buildDir}/tmp/kotlin-classes/debug") {
val kotlinClasses = fileTree(layout.buildDirectory.file("tmp/kotlin-classes/debug")) {
exclude(excludes)
}

Expand All @@ -100,10 +136,10 @@ tasks.register("jacocoReport", JacocoReport::class) {
)
)

val unitTestsData = fileTree("${buildDir}/jacoco") {
val unitTestsData = fileTree(layout.buildDirectory.file("jacoco")) {
include("*.exec")
}
val androidTestsData = fileTree("${buildDir}/outputs/code_coverage") {
val androidTestsData = fileTree(layout.buildDirectory.file("outputs/code_coverage")) {
include(listOf("**/*.ec"))
}

Expand All @@ -118,10 +154,10 @@ tasks.register("jacocoReport", JacocoReport::class) {

fun JacocoReportsContainer.reports() {
xml.required.set(true)
xml.outputLocation.set(file("${buildDir}/coverage-report/jacocoTestReport.xml"))
xml.outputLocation.set(layout.buildDirectory.file("coverage-report/jacocoTestReport.xml"))

html.required.set(true)
html.outputLocation.set(file("${buildDir}/coverage-report"))
html.outputLocation.set(layout.buildDirectory.file("coverage-report").get().asFile)
}

reports {
Expand Down
Loading

0 comments on commit 985e9be

Please sign in to comment.