diff --git a/JetLagged/buildscripts/init.gradle.kts b/JetLagged/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/JetLagged/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/JetLagged/gradle/libs.versions.toml b/JetLagged/gradle/libs.versions.toml index 1cd5b96b62..2c0b490a3b 100644 --- a/JetLagged/gradle/libs.versions.toml +++ b/JetLagged/gradle/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } diff --git a/JetNews/buildscripts/init.gradle.kts b/JetNews/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/JetNews/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/JetNews/gradle/libs.versions.toml b/JetNews/gradle/libs.versions.toml index 1cd5b96b62..2c0b490a3b 100644 --- a/JetNews/gradle/libs.versions.toml +++ b/JetNews/gradle/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } diff --git a/Jetcaster/buildscripts/init.gradle.kts b/Jetcaster/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/Jetcaster/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/Jetcaster/gradle/libs.versions.toml b/Jetcaster/gradle/libs.versions.toml index 3cffd54753..2c0b490a3b 100644 --- a/Jetcaster/gradle/libs.versions.toml +++ b/Jetcaster/gradle/libs.versions.toml @@ -3,20 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -android-material3 = "1.13.0-alpha11" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -31,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } @@ -149,7 +150,6 @@ kotlinx-collections-immutable = { module = "org.jetbrains.kotlinx:kotlinx-collec kotlinx-coroutines-android = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-android", version.ref = "coroutines" } kotlinx-coroutines-test = { module = "org.jetbrains.kotlinx:kotlinx-coroutines-test", version.ref = "coroutines" } kotlinx-serialization-json = { module = "org.jetbrains.kotlinx:kotlinx-serialization-json", version.ref = "kotlinx-serialization-json" } -android-material3 = { group = "com.google.android.material", name = "material", version.ref = "android-material3" } okhttp-logging = { module = "com.squareup.okhttp3:logging-interceptor", version.ref = "okhttp" } okhttp3 = { module = "com.squareup.okhttp3:okhttp", version.ref = "okhttp" } play-services-wearable = { module = "com.google.android.gms:play-services-wearable", version.ref = "play-services-wearable" } diff --git a/Jetchat/buildscripts/init.gradle.kts b/Jetchat/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/Jetchat/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/Jetchat/gradle/libs.versions.toml b/Jetchat/gradle/libs.versions.toml index 1cd5b96b62..2c0b490a3b 100644 --- a/Jetchat/gradle/libs.versions.toml +++ b/Jetchat/gradle/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } diff --git a/Jetsnack/buildscripts/init.gradle.kts b/Jetsnack/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/Jetsnack/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/Jetsnack/gradle/libs.versions.toml b/Jetsnack/gradle/libs.versions.toml index 1cd5b96b62..2c0b490a3b 100644 --- a/Jetsnack/gradle/libs.versions.toml +++ b/Jetsnack/gradle/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } diff --git a/Reply/buildscripts/init.gradle.kts b/Reply/buildscripts/init.gradle.kts new file mode 100644 index 0000000000..1b7a54264c --- /dev/null +++ b/Reply/buildscripts/init.gradle.kts @@ -0,0 +1,72 @@ +/* + * Copyright 2022 The Android Open Source Project + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * https://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +val ktlintVersion = "0.46.1" + +initscript { + val spotlessVersion = "6.10.0" + + repositories { + mavenCentral() + } + + dependencies { + classpath("com.diffplug.spotless:spotless-plugin-gradle:$spotlessVersion") + } +} + +allprojects { + if (this == rootProject) { + return@allprojects + } + apply() + extensions.configure { + kotlin { + target("**/*.kt") + targetExclude("**/build/**/*.kt") + ktlint(ktlintVersion).editorConfigOverride( + mapOf( + "ktlint_code_style" to "android", + "ij_kotlin_allow_trailing_comma" to true, + // These rules were introduced in ktlint 0.46.0 and should not be + // enabled without further discussion. They are disabled for now. + // See: https://github.com/pinterest/ktlint/releases/tag/0.46.0 + "disabled_rules" to + "filename," + + "annotation,annotation-spacing," + + "argument-list-wrapping," + + "double-colon-spacing," + + "enum-entry-name-case," + + "multiline-if-else," + + "no-empty-first-line-in-method-block," + + "package-name," + + "trailing-comma," + + "spacing-around-angle-brackets," + + "spacing-between-declarations-with-annotations," + + "spacing-between-declarations-with-comments," + + "unary-op-spacing" + ) + ) + licenseHeaderFile(rootProject.file("spotless/copyright.kt")) + } + format("kts") { + target("**/*.kts") + targetExclude("**/build/**/*.kts") + // Look for the first line that doesn't have a block comment (assumed to be the license) + licenseHeaderFile(rootProject.file("spotless/copyright.kt"), "(^(?![\\/ ]\\*).*$)") + } + } +} \ No newline at end of file diff --git a/Reply/gradle/libs.versions.toml b/Reply/gradle/libs.versions.toml index 1cd5b96b62..2c0b490a3b 100644 --- a/Reply/gradle/libs.versions.toml +++ b/Reply/gradle/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,37 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } diff --git a/scripts/libs.versions.toml b/scripts/libs.versions.toml index 29300201d3..2c0b490a3b 100644 --- a/scripts/libs.versions.toml +++ b/scripts/libs.versions.toml @@ -3,19 +3,20 @@ # Do not add a dependency to an individual sample, edit the global version instead. ##### [versions] -accompanist = "0.37.0" -androidGradlePlugin = "8.8.1" -androidx-activity-compose = "1.10.0" +accompanist = "0.37.2" +android-material3 = "1.13.0-alpha13" +androidGradlePlugin = "8.9.2" +androidx-activity-compose = "1.10.1" androidx-appcompat = "1.7.0" -androidx-compose-bom = "2025.02.00" +androidx-compose-bom = "2025.04.01" androidx-constraintlayout = "1.1.0" androidx-core-splashscreen = "1.0.1" -androidx-corektx = "1.15.0" +androidx-corektx = "1.16.0" androidx-glance = "1.1.1" androidx-lifecycle = "2.8.2" androidx-lifecycle-compose = "2.8.7" androidx-lifecycle-runtime-compose = "2.8.7" -androidx-navigation = "2.8.7" +androidx-navigation = "2.8.9" androidx-palette = "1.0.0" androidx-test = "1.6.1" androidx-test-espresso = "3.6.1" @@ -30,36 +31,38 @@ androix-test-uiautomator = "2.3.0" coil = "2.7.0" # @keep compileSdk = "35" -coroutines = "1.10.1" +coroutines = "1.10.2" google-maps = "18.2.0" gradle-versions = "0.52.0" -hilt = "2.55" +hilt = "2.56.2" hiltExt = "1.2.0" -horologist = "0.6.22" +horologist = "0.6.23" # @pin When updating to AGP 7.4.0-alpha10 and up we can update this https://developer.android.com/studio/write/java8-support#library-desugaring-versions jdkDesugar = "1.2.2" junit = "4.13.2" -kotlin = "2.1.10" +kotlin = "2.1.20" kotlinx-serialization-json = "1.7.3" kotlinx_immutable = "0.3.8" -ksp = "2.1.10-1.0.30" +ksp = "2.1.20-2.0.0" maps-compose = "3.1.1" # @keep minSdk = "21" okhttp = "4.12.0" play-services-wearable = "18.1.0" robolectric = "4.14.1" -roborazzi = "1.42.0" +roborazzi = "1.43.1" rome = "2.1.0" -room = "2.6.1" +room = "2.7.1" secrets = "2.0.1" +spotless = "7.0.3" # @keep targetSdk = "33" -version-catalog-update = "0.8.5" +version-catalog-update = "1.0.0" [libraries] accompanist-adaptive = { module = "com.google.accompanist:accompanist-adaptive", version.ref = "accompanist" } accompanist-permissions = { module = "com.google.accompanist:accompanist-permissions", version.ref = "accompanist" } +android-material3 = { module = "com.google.android.material:material", version.ref = "android-material3" } androidx-activity-compose = { module = "androidx.activity:activity-compose", version.ref = "androidx-activity-compose" } androidx-activity-ktx = { module = "androidx.activity:activity-ktx", version.ref = "androidx-activity-compose" } androidx-appcompat = { module = "androidx.appcompat:appcompat", version.ref = "androidx-appcompat" } @@ -171,4 +174,5 @@ kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization", versi ksp = { id = "com.google.devtools.ksp", version.ref = "ksp" } roborazzi = { id = "io.github.takahirom.roborazzi", version.ref = "roborazzi" } secrets = { id = "com.google.android.libraries.mapsplatform.secrets-gradle-plugin", version.ref = "secrets" } +spotless = { id = "com.diffplug.spotless", version.ref = "spotless" } version-catalog-update = { id = "nl.littlerobots.version-catalog-update", version.ref = "version-catalog-update" }