diff --git a/app/build.gradle b/app/build.gradle deleted file mode 100644 index f789d8cc..00000000 --- a/app/build.gradle +++ /dev/null @@ -1,113 +0,0 @@ -plugins { - id 'com.android.application' - id 'kotlin-android' - id 'kotlin-parcelize' - id 'kotlin-kapt' - id 'dagger.hilt.android.plugin' -} -apply from: rootProject.file("gradle/git-tag-version.gradle") - -if (getGradle().getStartParameter().getTaskRequests().toString().contains("Release")){ - apply plugin: 'com.google.gms.google-services' - apply plugin: 'com.google.firebase.crashlytics' -} - -android { - namespace 'no.nordicsemi.android.nrftoolbox' - - compileSdk android_api_version - - defaultConfig { - applicationId "no.nordicsemi.android.nrftoolbox" - minSdk android_min_api_version - targetSdk android_api_version - versionCode getVersionCodeFromTags() - versionName getVersionNameFromTags() - - testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" - vectorDrawables { - useSupportLibrary true - } - } - - signingConfigs { - release { - storeFile file('../keystore') - storePassword System.env.KEYSTORE_PSWD - keyAlias System.env.KEYSTORE_ALIAS - keyPassword System.env.KEYSTORE_KEY_PSWD - } - } - - buildTypes { - release { - minifyEnabled true - shrinkResources true - signingConfig signingConfigs.release - proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' - } - } - - compileOptions { - sourceCompatibility JavaVersion.VERSION_1_8 - targetCompatibility JavaVersion.VERSION_1_8 - } - kotlinOptions { - jvmTarget = '1.8' - useIR = true - } - buildFeatures { - compose true - } - composeOptions { - kotlinCompilerExtensionVersion compose_version - kotlinCompilerVersion kotlin_version - } - hilt { - enableExperimentalClasspathAggregation = true - } -} - -dependencies { - //Hilt requires to implement every module in the main app module - //https://github.com/google/dagger/issues/2123 - implementation project(':profile_bps') - implementation project(':profile_csc') - implementation project(':profile_cgms') - implementation project(':profile_gls') - implementation project(':profile_hrs') - implementation project(':profile_hts') - implementation project(':profile_prx') - implementation project(':profile_rscs') - - implementation project(':profile_uart') - - implementation project(":lib_analytics") - implementation project(':lib_ui') - implementation project(":lib_utils") - implementation project(":lib_service") - - implementation libs.nordic.theme - implementation libs.nordic.ble.common - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - implementation libs.nordic.analytics - - implementation libs.bundles.hilt - kapt libs.bundles.hiltkapt - - implementation libs.bundles.icons - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.test.junit - androidTestImplementation libs.android.test.junit - androidTestImplementation libs.android.test.espresso - androidTestImplementation libs.android.test.compose.ui - debugImplementation libs.android.test.compose.tooling -} diff --git a/app/build.gradle.kts b/app/build.gradle.kts new file mode 100644 index 00000000..9d423206 --- /dev/null +++ b/app/build.gradle.kts @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.application.compose) + alias(libs.plugins.nordic.hilt) +} + +if (getGradle().getStartParameter().getTaskRequests().toString().contains("Release")){ + apply(plugin = "com.google.gms.google-services") + apply(plugin = "com.google.firebase.crashlytics") +} + +android { + namespace = "no.nordicsemi.android.nrftoolbox" +} + +dependencies { + //Hilt requires to implement every module in the main app module + //https://github.com/google/dagger/issues/2123 + implementation(project(":profile_bps")) + implementation(project(":profile_csc")) + implementation(project(":profile_cgms")) + implementation(project(":profile_gls")) + implementation(project(":profile_hrs")) + implementation(project(":profile_hts")) + implementation(project(":profile_prx")) + implementation(project(":profile_rscs")) + + implementation(project(":profile_uart")) + + implementation(project(":lib_analytics")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + implementation(project(":lib_service")) + + implementation(libs.nordic.core) + implementation(libs.nordic.theme) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.uilogger) + implementation(libs.nordic.permission) + implementation(libs.nordic.analytics) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + + implementation(libs.androidx.hilt.navigation.compose) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) +} diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index b076db59..f51aa1b0 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -49,14 +49,14 @@ android:label="@string/app_name" android:roundIcon="@mipmap/ic_launcher_round" android:supportsRtl="true" - android:theme="@style/AppTheme"> + android:theme="@style/NordicTheme"> + android:theme="@style/NordicTheme.SplashScreen"> diff --git a/build.gradle b/build.gradle deleted file mode 100644 index 5e2a4a16..00000000 --- a/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -// Top-level build file where you can add configuration options common to all sub-projects/modules. -buildscript { - ext { - compose_version = '1.1.0-rc01' - kotlin_version = '1.6.0' - android_api_version = 31 - android_min_api_version = 21 - } - repositories { - google() - mavenCentral() - } - dependencies { - classpath 'com.android.tools.build:gradle:7.4.0-alpha05' - classpath 'com.google.gms:google-services:4.3.10' - classpath 'com.google.firebase:firebase-crashlytics-gradle:2.8.1' - classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" - classpath "io.spring.gradle:dependency-management-plugin:1.0.11.RELEASE" - classpath "com.google.dagger:hilt-android-gradle-plugin:2.40.4" - classpath 'com.google.protobuf:protobuf-gradle-plugin:0.8.18' - - // NOTE: Do not place your application dependencies here; they belong - // in the individual module build.gradle files - } -} - -apply plugin: "io.spring.dependency-management" - -task clean(type: Delete) { - delete rootProject.buildDir -} \ No newline at end of file diff --git a/build.gradle.kts b/build.gradle.kts new file mode 100644 index 00000000..e8a17fd3 --- /dev/null +++ b/build.gradle.kts @@ -0,0 +1,47 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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. + */ + +// Top-level build file where you can add configuration options common to all sub-projects/modules. +plugins { + alias(libs.plugins.android.application) apply false + alias(libs.plugins.kotlin.jvm) apply false + alias(libs.plugins.kotlin.kapt) apply true + alias(libs.plugins.kotlin.serialization) apply false + alias(libs.plugins.hilt) apply false + alias(libs.plugins.secrets) apply false + alias(libs.plugins.protobuf) apply false + alias(libs.plugins.nordic.application) apply false + alias(libs.plugins.nordic.application.compose) apply false + alias(libs.plugins.nordic.library) apply false + alias(libs.plugins.nordic.library.compose) apply false + alias(libs.plugins.nordic.hilt) apply false + alias(libs.plugins.nordic.feature) apply false +} diff --git a/gradle/git-tag-version.gradle b/gradle/git-tag-version.gradle deleted file mode 100644 index d65632ef..00000000 --- a/gradle/git-tag-version.gradle +++ /dev/null @@ -1,27 +0,0 @@ -ext.getVersionCodeFromTags = { -> - try { - def code = new ByteArrayOutputStream() - exec { - commandLine 'git', 'log' - standardOutput = code - } - return code.toString().split("\n").size() - } - catch (ignored) { - return -1 - } -} - -ext.getVersionNameFromTags = { -> - try { - def stdout = new ByteArrayOutputStream() - exec { - commandLine 'git', 'describe', '--tags', '--abbrev=0' - standardOutput = stdout - } - return stdout.toString().trim().split("%")[0] - } - catch (ignored) { - return null - } -} diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 4ef00157..b49ef06f 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -31,7 +31,7 @@ #Mon Feb 14 14:46:55 CET 2022 distributionBase=GRADLE_USER_HOME -distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-rc-1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6-bin.zip distributionPath=wrapper/dists zipStorePath=wrapper/dists zipStoreBase=GRADLE_USER_HOME diff --git a/lib_analytics/build.gradle b/lib_analytics/build.gradle deleted file mode 100644 index f9eb3f3e..00000000 --- a/lib_analytics/build.gradle +++ /dev/null @@ -1,13 +0,0 @@ -apply from: rootProject.file("library.gradle") - -android { - namespace 'no.nordicsemi.android.analytics' -} - -dependencies { - implementation platform('com.google.firebase:firebase-bom:29.2.1') - implementation 'com.google.firebase:firebase-analytics' - implementation 'com.google.firebase:firebase-crashlytics' - - implementation libs.nordic.analytics -} diff --git a/lib_service/src/androidTest/java/no/nordicsemi/android/service/ExampleInstrumentedTest.kt b/lib_analytics/build.gradle.kts similarity index 69% rename from lib_service/src/androidTest/java/no/nordicsemi/android/service/ExampleInstrumentedTest.kt rename to lib_analytics/build.gradle.kts index 187e6af5..d18fe157 100644 --- a/lib_service/src/androidTest/java/no/nordicsemi/android/service/ExampleInstrumentedTest.kt +++ b/lib_analytics/build.gradle.kts @@ -29,25 +29,18 @@ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package no.nordicsemi.android.service +plugins { + alias(libs.plugins.nordic.library) +} -import androidx.test.ext.junit.runners.AndroidJUnit4 -import androidx.test.platform.app.InstrumentationRegistry -import org.junit.Assert.assertEquals -import org.junit.Test -import org.junit.runner.RunWith +android { + namespace = "no.nordicsemi.android.analytics" +} -/** - * Instrumented test, which will execute on an Android device. - * - * See [testing documentation](http://d.android.com/tools/testing). - */ -@RunWith(AndroidJUnit4::class) -class ExampleInstrumentedTest { - @Test - fun useAppContext() { - // Context of the app under test. - val appContext = InstrumentationRegistry.getInstrumentation().targetContext - assertEquals("no.nordicsemi.android.service.test", appContext.packageName) - } -} \ No newline at end of file +dependencies { + implementation(platform("com.google.firebase:firebase-bom:29.2.1")) + implementation("com.google.firebase:firebase-analytics") + implementation("com.google.firebase:firebase-crashlytics") + + implementation(libs.nordic.analytics) +} diff --git a/lib_service/build.gradle b/lib_service/build.gradle deleted file mode 100644 index 158da545..00000000 --- a/lib_service/build.gradle +++ /dev/null @@ -1,22 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.service' -} - -dependencies { - implementation project(':lib_ui') - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.ui.scanner - - implementation libs.lifecycle.service - implementation libs.localbroadcastmanager - - testImplementation libs.test.junit - androidTestImplementation libs.android.test.junit - androidTestImplementation libs.android.test.espresso - androidTestImplementation libs.android.test.compose.ui - debugImplementation libs.android.test.compose.tooling -} diff --git a/lib_service/build.gradle.kts b/lib_service/build.gradle.kts new file mode 100644 index 00000000..12f4709b --- /dev/null +++ b/lib_service/build.gradle.kts @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.service" +} + +dependencies { + implementation(project(":lib_ui")) + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.uiscanner) + + implementation(libs.androidx.lifecycle.service) + implementation(libs.androidx.localbroadcastmanager) +} diff --git a/lib_ui/build.gradle b/lib_ui/build.gradle deleted file mode 100644 index 4bbd1e8e..00000000 --- a/lib_ui/build.gradle +++ /dev/null @@ -1,18 +0,0 @@ -apply from: rootProject.file("library.gradle") - -android { - namespace 'no.nordicsemi.android.ui' -} - -dependencies { - implementation libs.nordic.ui.logger - - implementation libs.material - - implementation libs.nordic.theme - - implementation libs.bundles.compose - implementation libs.bundles.icons - implementation libs.compose.lifecycle - implementation libs.compose.activity -} diff --git a/lib_ui/build.gradle.kts b/lib_ui/build.gradle.kts new file mode 100644 index 00000000..81dcb564 --- /dev/null +++ b/lib_ui/build.gradle.kts @@ -0,0 +1,49 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) +} + +android { + namespace = "no.nordicsemi.android.ui" +} + +dependencies { + implementation(libs.nordic.uilogger) + + implementation(libs.nordic.theme) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) +} diff --git a/lib_utils/build.gradle b/lib_utils/build.gradle deleted file mode 100644 index bbb3d2d0..00000000 --- a/lib_utils/build.gradle +++ /dev/null @@ -1,11 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.utils' -} - -dependencies { - implementation libs.nordic.navigation - implementation libs.nordic.ui.scanner -} diff --git a/lib_service/src/test/java/no/nordicsemi/android/service/ExampleUnitTest.kt b/lib_utils/build.gradle.kts similarity index 81% rename from lib_service/src/test/java/no/nordicsemi/android/service/ExampleUnitTest.kt rename to lib_utils/build.gradle.kts index 17e49ed7..0e5490fb 100644 --- a/lib_service/src/test/java/no/nordicsemi/android/service/ExampleUnitTest.kt +++ b/lib_utils/build.gradle.kts @@ -29,19 +29,16 @@ * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ -package no.nordicsemi.android.service +plugins { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} -import org.junit.Assert.assertEquals -import org.junit.Test +android { + namespace = "no.nordicsemi.android.utils" +} -/** - * Example local unit test, which will execute on the development machine (host). - * - * See [testing documentation](http://d.android.com/tools/testing). - */ -class ExampleUnitTest { - @Test - fun addition_isCorrect() { - assertEquals(4, 2 + 2) - } -} \ No newline at end of file +dependencies { + implementation(libs.nordic.navigation) + implementation(libs.nordic.uiscanner) +} diff --git a/profile_bps/build.gradle b/profile_bps/build.gradle deleted file mode 100644 index d391ffc8..00000000 --- a/profile_bps/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.navigation - implementation libs.nordic.theme - implementation libs.nordic.ui.logger - - implementation libs.nordic.ui.scanner - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} - -android { - namespace 'no.nordicsemi.android.bps' -} diff --git a/profile_bps/build.gradle.kts b/profile_bps/build.gradle.kts new file mode 100644 index 00000000..47455844 --- /dev/null +++ b/profile_bps/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.bps" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.navigation) + implementation(libs.nordic.theme) + implementation(libs.nordic.uilogger) + + implementation(libs.nordic.uiscanner) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_cgms/build.gradle b/profile_cgms/build.gradle deleted file mode 100644 index bae6923b..00000000 --- a/profile_cgms/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.cgms' -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.ui.logger - - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} diff --git a/profile_cgms/build.gradle.kts b/profile_cgms/build.gradle.kts new file mode 100644 index 00000000..35413731 --- /dev/null +++ b/profile_cgms/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.cgms" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.uilogger) + + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_csc/build.gradle b/profile_csc/build.gradle deleted file mode 100644 index 51fd221b..00000000 --- a/profile_csc/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.ui.logger - - implementation libs.nordic.theme - implementation libs.nordic.navigation - implementation libs.nordic.ui.scanner - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} - -android { - namespace 'no.nordicsemi.android.csc' -} diff --git a/profile_csc/build.gradle.kts b/profile_csc/build.gradle.kts new file mode 100644 index 00000000..ba3678b7 --- /dev/null +++ b/profile_csc/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.csc" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.uilogger) + + implementation(libs.nordic.theme) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uiscanner) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_gls/build.gradle b/profile_gls/build.gradle deleted file mode 100644 index 5eaad407..00000000 --- a/profile_gls/build.gradle +++ /dev/null @@ -1,32 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.gls' -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.chart - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} diff --git a/profile_gls/build.gradle.kts b/profile_gls/build.gradle.kts new file mode 100644 index 00000000..182addfd --- /dev/null +++ b/profile_gls/build.gradle.kts @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.gls" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.chart) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_hrs/build.gradle b/profile_hrs/build.gradle deleted file mode 100644 index edfa4b9d..00000000 --- a/profile_hrs/build.gradle +++ /dev/null @@ -1,33 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.hrs' -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.chart - - implementation libs.nordic.theme - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - implementation libs.nordic.navigation - implementation libs.nordic.ui.scanner - implementation libs.nordic.ui.logger - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - implementation libs.kotlin.coroutines - - testImplementation libs.bundles.test -} diff --git a/profile_hrs/build.gradle.kts b/profile_hrs/build.gradle.kts new file mode 100644 index 00000000..090e9490 --- /dev/null +++ b/profile_hrs/build.gradle.kts @@ -0,0 +1,61 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.hrs" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.chart) + + implementation(libs.nordic.theme) + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_hts/build.gradle b/profile_hts/build.gradle deleted file mode 100644 index abf5d26b..00000000 --- a/profile_hts/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} - -android { - namespace 'no.nordicsemi.android.hts' -} diff --git a/profile_hts/build.gradle.kts b/profile_hts/build.gradle.kts new file mode 100644 index 00000000..8ad714a8 --- /dev/null +++ b/profile_hts/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.hts" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_prx/build.gradle b/profile_prx/build.gradle deleted file mode 100644 index 1ca58067..00000000 --- a/profile_prx/build.gradle +++ /dev/null @@ -1,32 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.prx' -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - - implementation libs.bundles.icons - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} diff --git a/profile_prx/build.gradle.kts b/profile_prx/build.gradle.kts new file mode 100644 index 00000000..b1d27ca1 --- /dev/null +++ b/profile_prx/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.prx" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_rscs/build.gradle b/profile_rscs/build.gradle deleted file mode 100644 index dc7b7637..00000000 --- a/profile_rscs/build.gradle +++ /dev/null @@ -1,31 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' - -android { - namespace 'no.nordicsemi.android.rscs' -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test -} diff --git a/profile_rscs/build.gradle.kts b/profile_rscs/build.gradle.kts new file mode 100644 index 00000000..e7e78129 --- /dev/null +++ b/profile_rscs/build.gradle.kts @@ -0,0 +1,60 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + id("kotlin-parcelize") +} + +android { + namespace = "no.nordicsemi.android.rscs" +} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) +} diff --git a/profile_uart/build.gradle b/profile_uart/build.gradle deleted file mode 100644 index c83b88d6..00000000 --- a/profile_uart/build.gradle +++ /dev/null @@ -1,62 +0,0 @@ -apply from: rootProject.file("library.gradle") -apply plugin: 'kotlin-parcelize' -apply plugin: 'com.google.protobuf' - -protobuf { - protoc { - artifact = 'com.google.protobuf:protoc:3.14.0' - } - - // Generates the java Protobuf-lite code for the Protobufs in this project. See - // https://github.com/google/protobuf-gradle-plugin#customizing-protobuf-compilation - // for more information. - generateProtoTasks { - all().each { task -> - task.builtins { - java { - option 'lite' - } - } - } - } - -} - -dependencies { - implementation project(":lib_analytics") - implementation project(":lib_service") - implementation project(':lib_ui') - implementation project(":lib_utils") - - implementation libs.room.runtime - implementation libs.room.ktx - kapt libs.room.compiler - - implementation libs.nordic.ble.common - implementation libs.nordic.ble.ktx - - implementation libs.nordic.theme - implementation libs.nordic.ui.scanner - implementation libs.nordic.navigation - implementation libs.nordic.ui.logger - - implementation libs.bundles.datastore - implementation libs.bundles.compose - implementation libs.androidx.core - implementation libs.material - implementation libs.lifecycle.activity - implementation libs.lifecycle.service - implementation libs.compose.lifecycle - implementation libs.compose.activity - - testImplementation libs.bundles.test - - implementation('org.simpleframework:simple-xml:2.7.1') { - exclude group: 'stax', module: 'stax-api' - exclude group: 'xpp3', module: 'xpp3' - } -} - -android { - namespace 'no.nordicsemi.android.uart' -} diff --git a/profile_uart/build.gradle.kts b/profile_uart/build.gradle.kts new file mode 100644 index 00000000..744931a5 --- /dev/null +++ b/profile_uart/build.gradle.kts @@ -0,0 +1,80 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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 { + alias(libs.plugins.nordic.library) + alias(libs.plugins.kotlin.serialization) +// id("com.google.protobuf") + alias(libs.plugins.kotlin.kapt) +} + +android { + namespace = "no.nordicsemi.android.uart" +} +// +//protobuf { +// protoc { +// artifact = "com.google.protobuf:protoc:3.14.0" +// } +//} + +dependencies { + implementation(project(":lib_analytics")) + implementation(project(":lib_service")) + implementation(project(":lib_ui")) + implementation(project(":lib_utils")) + + implementation(libs.room.runtime) + implementation(libs.room.ktx) + +// kapt(libs.room.compiler) + kapt("androidx.room:room-compiler:2.5.0") +// kapt("") + + implementation(libs.nordic.ble.common) + implementation(libs.nordic.ble.ktx) + + implementation(libs.nordic.theme) + implementation(libs.nordic.uiscanner) + implementation(libs.nordic.navigation) + implementation(libs.nordic.uilogger) + + implementation(libs.androidx.compose.material.iconsExtended) + implementation(libs.androidx.core.ktx) + implementation(libs.androidx.compose.material3) + implementation(libs.androidx.activity.compose) + implementation(libs.androidx.lifecycle.service) + + implementation("org.simpleframework:simple-xml:2.7.1") { + exclude(group = "stax", module = "stax-api") + exclude(group = "xpp3", module = "xpp3") + } +} diff --git a/profile_uart/src/main/java/no/nordicsemi/android/uart/db/XmlMacro.java b/profile_uart/src/main/java/no/nordicsemi/android/uart/db/XmlMacro.java index 726b9b34..202097bd 100644 --- a/profile_uart/src/main/java/no/nordicsemi/android/uart/db/XmlMacro.java +++ b/profile_uart/src/main/java/no/nordicsemi/android/uart/db/XmlMacro.java @@ -35,8 +35,9 @@ import org.simpleframework.xml.Attribute; import org.simpleframework.xml.Root; import org.simpleframework.xml.Text; -import no.nordicsemi.android.uart.data.MacroEol; -import no.nordicsemi.android.uart.data.MacroIcon; +//import no.nordicsemi.android.uart.data.MacroEol; +//import no.nordicsemi.android.uart.data.MacroIcon; +import no.nordicsemi.android.uart.data.*; @Root public class XmlMacro { diff --git a/settings.gradle b/settings.gradle deleted file mode 100644 index a34a244d..00000000 --- a/settings.gradle +++ /dev/null @@ -1,110 +0,0 @@ -dependencyResolutionManagement { - repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) - repositories { - google() - maven { url 'https://jitpack.io' } - mavenCentral() - mavenLocal() - } - - versionCatalogs { - libs { - library('nordic-ble-common', 'no.nordicsemi.android:ble-common:2.4.1') - library('nordic-ble-ktx', 'no.nordicsemi.android:ble-ktx:2.4.1') - library('nordic-scanner', 'no.nordicsemi.android.support.v18:scanner:1.6.0') - - library('nordic-log', 'no.nordicsemi.android:log:2.3.0') - - version('commonlibraries', '1.0.13') - library('nordic-ui-scanner', 'no.nordicsemi.android.common', 'uiscanner').versionRef('commonlibraries') - library('nordic-navigation', 'no.nordicsemi.android.common', 'navigation').versionRef('commonlibraries') - library('nordic-theme', 'no.nordicsemi.android.common', 'theme').versionRef('commonlibraries') - library('nordic-analytics', 'no.nordicsemi.android.common', 'analytics').versionRef('commonlibraries') - library('nordic-ui-logger', 'no.nordicsemi.android.common', 'uilogger').versionRef('commonlibraries') - - library('localbroadcastmanager', 'androidx.localbroadcastmanager:localbroadcastmanager:1.1.0') - library('material', 'com.google.android.material:material:1.6.0-rc01') - - version('lifecycle', '2.4.1') - library('lifecycle-activity', 'androidx.lifecycle', 'lifecycle-runtime-ktx').versionRef('lifecycle') - library('lifecycle-service', 'androidx.lifecycle', 'lifecycle-service').versionRef('lifecycle') - library('compose-lifecycle', 'androidx.lifecycle', 'lifecycle-viewmodel-compose').versionRef('lifecycle') - - library('androidx-core', 'androidx.core:core-ktx:1.7.0') - library('compose-activity', 'androidx.activity:activity-compose:1.4.0') - - version('datastore', '1.0.0') - library('datastore-core', 'androidx.datastore', 'datastore').versionRef('datastore') - library('datastore-prefs', 'androidx.datastore', 'datastore-preferences').versionRef('datastore') - library('datastore-protobuf', 'com.google.protobuf:protobuf-javalite:3.18.0') - bundle('datastore', ['datastore-core', 'datastore-prefs', 'datastore-protobuf']) - - version('compose', '1.2.0-alpha07') - library('compose-ui', 'androidx.compose.ui', 'ui').versionRef('compose') - library('compose-material', 'androidx.compose.material3:material3:1.0.0-alpha09') - library('compose-tooling-preview', 'androidx.compose.ui', 'ui-tooling-preview').versionRef('compose') - library('compose-navigation', 'androidx.navigation:navigation-compose:2.4.1') - bundle('compose', ['compose-ui', 'compose-material', 'compose-tooling-preview', 'compose-navigation']) - - library('material-icons', 'androidx.compose.material', 'material-icons-core').versionRef('compose') - library('material-icons-extended', 'androidx.compose.material', 'material-icons-extended').versionRef('compose') - bundle('icons', ['material-icons', 'material-icons-extended']) - - library('hilt-android', 'com.google.dagger:hilt-android:2.40.4') - library('hilt-compiler', 'com.google.dagger:hilt-compiler:2.40.4') - library('hilt-compose', 'androidx.hilt:hilt-navigation-compose:1.0.0') - library('hilt-lifecycle', 'androidx.hilt:hilt-lifecycle-viewmodel:1.0.0-alpha03') - library('hilt-lifecyclecompiler', 'androidx.hilt:hilt-compiler:1.0.0') - bundle('hilt', ['hilt-android', 'hilt-compose', 'hilt-lifecycle']) - bundle('hiltkapt', ['hilt-compiler', 'hilt-lifecyclecompiler']) - - library('kotlin-coroutines', 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.6.0') - library('google-permissions', 'com.google.accompanist:accompanist-permissions:0.20.0') - library('chart', 'com.github.PhilJay:MPAndroidChart:v3.1.0') - - version('room', '2.4.1') - library('room-runtime', 'androidx.room', 'room-runtime').versionRef('room') - library('room-ktx', 'androidx.room', 'room-ktx').versionRef('room') - library('room-compiler', 'androidx.room', 'room-compiler').versionRef('room') - - //-- Test ------------------------------------------------------------------------------ - library('test-junit', 'junit:junit:4.13.2') - library('android-test-junit', 'androidx.test.ext:junit:1.1.3') - library('android-test-espresso', 'androidx.test.espresso:espresso-core:3.4.0') - library('android-test-compose-ui', 'androidx.compose.ui', 'ui-test-junit4').versionRef('compose') - library('android-test-compose-tooling', 'androidx.compose.ui', 'ui-tooling').versionRef('compose') - - library('mockk-main', 'io.mockk:mockk:1.12.2') - library('mockk-jvm', 'io.mockk:mockk-agent-jvm:1.12.2') - library('test-coroutines', 'org.jetbrains.kotlinx:kotlinx-coroutines-test:1.6.0') - bundle('test', ['test-junit', 'android-test-junit', 'mockk-main', 'mockk-jvm', 'test-coroutines']) - } - } -} - -rootProject.name = "Android-nRF-Toolbox" - -include ':app' - -include ':profile_bps' -include ':profile_cgms' -include ':profile_csc' -include ':profile_gls' -include ':profile_hrs' -include ':profile_hts' -include ':profile_prx' -include ':profile_rscs' -include ':profile_uart' - -include ':lib_analytics' -include ':lib_service' -include ':lib_ui' -include ':lib_utils' - -if (file('../Android-Common-Libraries').exists()) { - includeBuild('../Android-Common-Libraries') -} - -if (file('../Android-BLE-Library').exists()) { - includeBuild('../Android-BLE-Library') -} diff --git a/settings.gradle.kts b/settings.gradle.kts new file mode 100644 index 00000000..9addc940 --- /dev/null +++ b/settings.gradle.kts @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2022, Nordic Semiconductor + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. 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. + * + * 3. Neither the name of the copyright holder 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 + * HOLDER 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. + */ + +pluginManagement { + repositories { + mavenLocal() + google() + mavenCentral() + gradlePluginPortal() + } +} + +dependencyResolutionManagement { + repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) + repositories { + mavenLocal() + google() + mavenCentral() + maven(url = "https://jitpack.io") + } + versionCatalogs { + create("libs") { + from("no.nordicsemi.android.gradle:version-catalog:1.2.2") + } + } +} + +rootProject.name = "Android-nRF-Toolbox" + +include(":app") + +include(":profile_bps") +include(":profile_cgms") +include(":profile_csc") +include(":profile_gls") +include(":profile_hrs") +include(":profile_hts") +include(":profile_prx") +include(":profile_rscs") +include(":profile_uart") + +include(":lib_analytics") +include(":lib_service") +include(":lib_ui") +include(":lib_utils") + +//if (file('../Android-Common-Libraries').exists()) { +// includeBuild('../Android-Common-Libraries') +//} +// +//if (file('../Android-BLE-Library').exists()) { +// includeBuild('../Android-BLE-Library') +//}