diff --git a/build.gradle b/build.gradle index 2d5b2abd..1da259bb 100644 --- a/build.gradle +++ b/build.gradle @@ -37,6 +37,7 @@ subprojects { apply from: "deploy.gradle" +// todo check warnings tasks.withType(JavaCompile) { options.compilerArgs += ["--release", "8"] } diff --git a/config.gradle b/config.gradle index 7a3c5bcb..06c90303 100644 --- a/config.gradle +++ b/config.gradle @@ -5,9 +5,9 @@ ext { buildConfig = [ "minSdk" : 21, - "compileSdk": 33, - "targetSdk" : 33, - "buildTools": "33.0.2" + "compileSdk": 34, + "targetSdk" : 34, + "buildTools": "34.0.0" ] releaseConfig = [ "group" : "com.infinum.sentinel", diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index b1c95cbd..70ef4e8e 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,23 +1,22 @@ [versions] sentinel = "1.3.2" -gradle = "8.0.2" -desugar = "2.0.3" -kotlin = "1.8.21" -coroutines = "1.7.1" +gradle = "8.3.0" +kotlin = "1.9.22" +coroutines = "1.7.3" json = "1.5.1" -core = "1.10.1" +core = "1.12.0" appcompat = "1.6.1" -activity = "1.7.2" -fragment = "1.5.7" -recycler = "1.3.0" -lifecycle = "2.6.1" -preference = "1.2.0" -room = "2.5.1" -workmanager = "2.8.1" +activity = "1.8.2" +fragment = "1.6.2" +recycler = "1.3.2" +lifecycle = "2.7.0" +preference = "1.2.1" +room = "2.6.1" +workmanager = "2.9.0" startup = "1.1.1" crypto = "1.1.0-alpha06" dynamicanimation = "1.0.0" -design = "1.9.0" +design = "1.11.0" inject = "0.6.1" timber = "5.0.1" detekt = "1.23.0" @@ -46,8 +45,6 @@ tooltimber = { module = "com.infinum.sentinel:tool-timber", version.ref = "senti tools-gradle = { module = "com.android.tools.build:gradle", version.ref = "gradle" } -desugar = { module = "com.android.tools:desugar_jdk_libs", version.ref = "desugar" } - kotlin-gradle = { module = "org.jetbrains.kotlin:kotlin-gradle-plugin", version.ref = "kotlin" } kotlin-core = { module = "org.jetbrains.kotlin:kotlin-stdlib-jdk8", version.ref = "kotlin" } kotlin-serialization = { module = "org.jetbrains.kotlin:kotlin-serialization", version.ref = "kotlin" } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index e1bef7e8..e411586a 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.2-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.4-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/sample/build.gradle b/sample/build.gradle index 452b2a59..d4617871 100644 --- a/sample/build.gradle +++ b/sample/build.gradle @@ -70,7 +70,7 @@ dependencies { // debugImplementation libs.library debugImplementation project(":sentinel") - releaseImplementation libs.librarynoop + releaseImplementation libs.librarynoop //todo test string collision without // debugImplementation libs.bundles.tools debugImplementation project(":tool-appgallery") diff --git a/sample/src/main/AndroidManifest.xml b/sample/src/main/AndroidManifest.xml index 82041cbd..704624af 100644 --- a/sample/src/main/AndroidManifest.xml +++ b/sample/src/main/AndroidManifest.xml @@ -2,6 +2,10 @@ + + diff --git a/sentinel-no-op/build.gradle b/sentinel-no-op/build.gradle index 5c57cde9..530751be 100644 --- a/sentinel-no-op/build.gradle +++ b/sentinel-no-op/build.gradle @@ -10,17 +10,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/sentinel/build.gradle b/sentinel/build.gradle index 391f47eb..5f76050d 100644 --- a/sentinel/build.gradle +++ b/sentinel/build.gradle @@ -1,8 +1,10 @@ +import org.jetbrains.kotlin.gradle.tasks.KotlinCompile + plugins { id "com.android.library" id "kotlin-android" id "org.jetbrains.kotlin.plugin.serialization" - id "com.google.devtools.ksp" version "1.8.21-1.0.11" + id "com.google.devtools.ksp" version "1.9.22-1.0.17" } apply from: "jacoco.gradle" @@ -14,8 +16,6 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" @@ -31,11 +31,9 @@ android { buildTypes { debug { testCoverageEnabled true - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } @@ -56,9 +54,7 @@ android { lint { disable "RtlEnabled", "VectorPath" } - compileOptions { - coreLibraryDesugaringEnabled true - } + kotlinOptions { freeCompilerArgs += [ "-opt-in=kotlin.ExperimentalStdlibApi", @@ -66,8 +62,19 @@ android { '-Xjvm-default=all' ] } + + tasks.withType(KotlinCompile).configureEach { + if (it.name.toLowerCase().contains("test")) { + kotlinOptions { + freeCompilerArgs -= [ + "-Xexplicit-api=strict", + ] + } + } + } testOptions { animationsDisabled = true + } sourceSets.each { @@ -93,7 +100,6 @@ dokkaJavadoc { } dependencies { - coreLibraryDesugaring libs.desugar implementation libs.kotlin.core implementation libs.kotlin.json implementation libs.coroutines @@ -104,21 +110,21 @@ dependencies { implementation libs.inject.runtime androidTestImplementation "junit:junit:4.13.2" - androidTestImplementation "androidx.arch.core:core-testing:2.1.0" - androidTestImplementation "androidx.test:core-ktx:1.4.0" - androidTestImplementation "androidx.test:rules:1.4.0" - androidTestImplementation "androidx.test:runner:1.4.0" - androidTestImplementation "androidx.test.ext:junit:1.1.3" - androidTestImplementation "androidx.security:security-crypto:1.1.0-alpha03" + androidTestImplementation "androidx.arch.core:core-testing:2.2.0" + androidTestImplementation "androidx.test:core-ktx:1.5.0" + androidTestImplementation "androidx.test:rules:1.5.0" + androidTestImplementation "androidx.test:runner:1.5.2" + androidTestImplementation "androidx.test.ext:junit:1.1.5" + androidTestImplementation "androidx.security:security-crypto:1.1.0-alpha06" androidTestImplementation "org.robolectric:shadowapi:4.5.1" - androidTestImplementation "androidx.test.espresso:espresso-core:3.4.0" - androidTestImplementation "androidx.test.espresso:espresso-intents:3.4.0" - androidTestImplementation "androidx.room:room-testing:2.4.0" - androidTestImplementation "androidx.fragment:fragment-ktx:1.4.0" - androidTestImplementation "androidx.fragment:fragment-testing:1.4.0" + androidTestImplementation "androidx.test.espresso:espresso-core:3.5.1" + androidTestImplementation "androidx.test.espresso:espresso-intents:3.5.1" + androidTestImplementation "androidx.room:room-testing:2.6.1" + androidTestImplementation "androidx.fragment:fragment-ktx:1.6.2" + androidTestImplementation "androidx.fragment:fragment-testing:1.6.2" testImplementation "junit:junit:4.13.2" - testImplementation "androidx.test.ext:junit:1.1.3" + testImplementation "androidx.test.ext:junit:1.1.5" } ksp { diff --git a/sentinel/src/androidTest/AndroidManifest.xml b/sentinel/src/androidTest/AndroidManifest.xml index 97ad80b6..9c93c8ed 100644 --- a/sentinel/src/androidTest/AndroidManifest.xml +++ b/sentinel/src/androidTest/AndroidManifest.xml @@ -1,6 +1,5 @@ diff --git a/sentinel/src/main/AndroidManifest.xml b/sentinel/src/main/AndroidManifest.xml index 5d3da567..a262259c 100644 --- a/sentinel/src/main/AndroidManifest.xml +++ b/sentinel/src/main/AndroidManifest.xml @@ -41,7 +41,8 @@ : FragmentActivity(), BaseVie @CallSuper override fun onPause() = super.onPause().run { + // todo overridePendingTransition(0, 0) } } diff --git a/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/BundleMonitorTool.kt b/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/BundleMonitorTool.kt index 0920479f..2c9b59b5 100644 --- a/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/BundleMonitorTool.kt +++ b/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/BundleMonitorTool.kt @@ -11,7 +11,7 @@ import com.infinum.sentinel.ui.bundles.BundlesActivity * Specific wrapper tool that monitors Bundle sizes for the application which implemented Sentinel. */ internal data class BundleMonitorTool( - @StringRes private val name: Int = R.string.sentinel_bundle_monitor, + @StringRes private val name: Int = R.string.sentinel_bundle_monitor_name, private val listener: View.OnClickListener = View.OnClickListener { it.context.startActivity( Intent( diff --git a/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/CrashMonitorTool.kt b/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/CrashMonitorTool.kt index 41ee8e6c..443fb98f 100644 --- a/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/CrashMonitorTool.kt +++ b/sentinel/src/main/kotlin/com/infinum/sentinel/ui/tools/CrashMonitorTool.kt @@ -14,7 +14,7 @@ import com.infinum.sentinel.ui.shared.Constants * Specific wrapper tool that monitors crashes for the application which implemented Sentinel. */ internal data class CrashMonitorTool( - @StringRes private val name: Int = R.string.sentinel_crash_monitor, + @StringRes private val name: Int = R.string.sentinel_crash_monitor_name, private val listener: View.OnClickListener = View.OnClickListener { it.context.startActivity( Intent( diff --git a/sentinel/src/main/res/layout/sentinel_fragment_bundle_details.xml b/sentinel/src/main/res/layout/sentinel_fragment_bundle_details.xml index 2b8170c7..2076f997 100644 --- a/sentinel/src/main/res/layout/sentinel_fragment_bundle_details.xml +++ b/sentinel/src/main/res/layout/sentinel_fragment_bundle_details.xml @@ -18,7 +18,7 @@ android:layout_height="wrap_content" android:minHeight="?attr/actionBarSize" app:navigationIcon="@drawable/sentinel_ic_back" - app:title="@string/sentinel_bundle_monitor" /> + app:title="@string/sentinel_bundle_monitor_name" /> diff --git a/sentinel/src/main/res/layout/sentinel_fragment_bundles.xml b/sentinel/src/main/res/layout/sentinel_fragment_bundles.xml index cfd46014..40f21dce 100644 --- a/sentinel/src/main/res/layout/sentinel_fragment_bundles.xml +++ b/sentinel/src/main/res/layout/sentinel_fragment_bundles.xml @@ -20,7 +20,7 @@ android:minHeight="?attr/actionBarSize" app:menu="@menu/sentinel_bundle_monitor" app:navigationIcon="@drawable/sentinel_ic_close" - app:title="@string/sentinel_bundle_monitor" /> + app:title="@string/sentinel_bundle_monitor_name" /> diff --git a/sentinel/src/main/res/layout/sentinel_fragment_crashes.xml b/sentinel/src/main/res/layout/sentinel_fragment_crashes.xml index e77fb5d3..e249cf94 100644 --- a/sentinel/src/main/res/layout/sentinel_fragment_crashes.xml +++ b/sentinel/src/main/res/layout/sentinel_fragment_crashes.xml @@ -20,7 +20,7 @@ android:minHeight="?attr/actionBarSize" app:menu="@menu/sentinel_crash_monitor" app:navigationIcon="@drawable/sentinel_ic_close" - app:title="@string/sentinel_crash_monitor" /> + app:title="@string/sentinel_crash_monitor_name" /> diff --git a/sentinel/src/main/res/layout/sentinel_fragment_settings.xml b/sentinel/src/main/res/layout/sentinel_fragment_settings.xml index 88da897e..ffc38c15 100644 --- a/sentinel/src/main/res/layout/sentinel_fragment_settings.xml +++ b/sentinel/src/main/res/layout/sentinel_fragment_settings.xml @@ -170,7 +170,7 @@ android:paddingStart="8dp" android:paddingEnd="8dp" android:paddingBottom="8dp" - android:text="@string/sentinel_bundle_monitor" + android:text="@string/sentinel_bundle_monitor_name" android:textAllCaps="true" android:textColor="@color/sentinel_primary" /> @@ -325,7 +325,7 @@ android:paddingStart="8dp" android:paddingEnd="8dp" android:paddingBottom="8dp" - android:text="@string/sentinel_crash_monitor" + android:text="@string/sentinel_crash_monitor_name" android:textAllCaps="true" android:textColor="@color/sentinel_primary" /> diff --git a/sentinel/src/main/res/values/strings.xml b/sentinel/src/main/res/values/strings.xml index 51a05cf2..b9582b6e 100644 --- a/sentinel/src/main/res/values/strings.xml +++ b/sentinel/src/main/res/values/strings.xml @@ -8,8 +8,8 @@ Permissions Settings App info - Bundle monitor - Crash monitor + Bundle monitor + Crash monitor Certificates Share Notify @@ -28,7 +28,7 @@ Bluetooth Distribution Design - Logger + Logger Triggers Share format diff --git a/tool-appgallery/build.gradle b/tool-appgallery/build.gradle index 8cd51724..c383bc65 100644 --- a/tool-appgallery/build.gradle +++ b/tool-appgallery/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-chucker/build.gradle b/tool-chucker/build.gradle index 0b5bfd54..caac7f73 100644 --- a/tool-chucker/build.gradle +++ b/tool-chucker/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-collar/build.gradle b/tool-collar/build.gradle index 293305a2..3636f774 100644 --- a/tool-collar/build.gradle +++ b/tool-collar/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-dbinspector/build.gradle b/tool-dbinspector/build.gradle index dd9e896f..16e62032 100644 --- a/tool-dbinspector/build.gradle +++ b/tool-dbinspector/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-googleplay/build.gradle b/tool-googleplay/build.gradle index fb8e62aa..13437422 100644 --- a/tool-googleplay/build.gradle +++ b/tool-googleplay/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-leakcanary/build.gradle b/tool-leakcanary/build.gradle index 0968afa8..2132bf3e 100644 --- a/tool-leakcanary/build.gradle +++ b/tool-leakcanary/build.gradle @@ -14,17 +14,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-thimble/build.gradle b/tool-thimble/build.gradle index 9bb2211f..b12c3460 100644 --- a/tool-thimble/build.gradle +++ b/tool-thimble/build.gradle @@ -15,17 +15,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } diff --git a/tool-timber/build.gradle b/tool-timber/build.gradle index 67a33d0f..9137864b 100644 --- a/tool-timber/build.gradle +++ b/tool-timber/build.gradle @@ -15,17 +15,13 @@ android { defaultConfig { minSdkVersion buildConfig.minSdk targetSdkVersion buildConfig.targetSdk - versionCode releaseConfig.versionCode - versionName releaseConfig.version } buildTypes { debug { - debuggable true minifyEnabled false } release { - debuggable false minifyEnabled true proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.txt" } @@ -67,7 +63,6 @@ dokkaJavadoc { } dependencies { - coreLibraryDesugaring libs.desugar implementation libs.kotlin.core implementation libs.coroutines api libs.library diff --git a/tool-timber/src/main/AndroidManifest.xml b/tool-timber/src/main/AndroidManifest.xml index 13652de9..211bcf90 100644 --- a/tool-timber/src/main/AndroidManifest.xml +++ b/tool-timber/src/main/AndroidManifest.xml @@ -6,7 +6,7 @@ + app:title="@string/sentinel_logger_name" /> Sentinel Search - Logger + Logger Logs %1$s: %2$s \ No newline at end of file