Skip to content
This repository has been archived by the owner on Jan 12, 2023. It is now read-only.

Commit

Permalink
For #8035 - Refactor Versions to FocusVersions
Browse files Browse the repository at this point in the history
  • Loading branch information
gabrielluong authored and mergify[bot] committed Nov 16, 2022
1 parent 162e002 commit 14305bd
Show file tree
Hide file tree
Showing 4 changed files with 65 additions and 65 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ android {
}

composeOptions {
kotlinCompilerExtensionVersion = Versions.google_compose_compiler
kotlinCompilerExtensionVersion = FocusVersions.google_compose_compiler
}

flavorDimensions "product"
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ configurations {
}

dependencies {
ktlint("com.pinterest:ktlint:${Versions.ktlint_version}") {
ktlint("com.pinterest:ktlint:${FocusVersions.ktlint_version}") {
attributes {
attribute(Bundling.BUNDLING_ATTRIBUTE, getObjects().named(Bundling, Bundling.EXTERNAL))
}
Expand Down
124 changes: 62 additions & 62 deletions buildSrc/src/main/java/FocusDependencies.kt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */

object Versions {
object FocusVersions {
object Adjust {
const val adjust = "4.33.0"
const val install_referrer = "2.2"
Expand Down Expand Up @@ -70,75 +70,75 @@ object Versions {
// Workaround for a Gradle parsing bug that prevents using nested objects directly in Gradle files.
// These might be removable if we switch to kts files instead.
// https://github.com/gradle/gradle/issues/9251
const val google_compose_compiler = Versions.Google.compose_compiler
const val ktlint_version = Versions.Testing.ktlint
const val google_compose_compiler = FocusVersions.Google.compose_compiler
const val ktlint_version = FocusVersions.Testing.ktlint
}

object FocusDependencies {
const val androidx_annotation = "androidx.annotation:annotation:${Versions.AndroidX.annotation}"
const val androidx_arch_core_testing = "androidx.arch.core:core-testing:${Versions.AndroidX.arch}"
const val androidx_appcompat = "androidx.appcompat:appcompat:${Versions.AndroidX.appcompat}"
const val androidx_browser = "androidx.browser:browser:${Versions.AndroidX.browser}"
const val androidx_cardview = "androidx.cardview:cardview:${Versions.AndroidX.cardview}"
const val androidx_compose_ui = "androidx.compose.ui:ui:${Versions.AndroidX.compose}"
const val androidx_compose_ui_test = "androidx.compose.ui:ui-test-junit4:${Versions.AndroidX.compose}"
const val androidx_compose_ui_test_manifest = "androidx.compose.ui:ui-test-manifest:${Versions.AndroidX.compose}"
const val androidx_compose_ui_tooling = "androidx.compose.ui:ui-tooling:${Versions.AndroidX.compose}"
const val androidx_compose_foundation = "androidx.compose.foundation:foundation:${Versions.AndroidX.compose}"
const val androidx_compose_material = "androidx.compose.material:material:${Versions.AndroidX.compose}"
const val androidx_compose_runtime_livedata = "androidx.compose.runtime:runtime-livedata:${Versions.AndroidX.compose}"
const val androidx_annotation = "androidx.annotation:annotation:${FocusVersions.AndroidX.annotation}"
const val androidx_arch_core_testing = "androidx.arch.core:core-testing:${FocusVersions.AndroidX.arch}"
const val androidx_appcompat = "androidx.appcompat:appcompat:${FocusVersions.AndroidX.appcompat}"
const val androidx_browser = "androidx.browser:browser:${FocusVersions.AndroidX.browser}"
const val androidx_cardview = "androidx.cardview:cardview:${FocusVersions.AndroidX.cardview}"
const val androidx_compose_ui = "androidx.compose.ui:ui:${FocusVersions.AndroidX.compose}"
const val androidx_compose_ui_test = "androidx.compose.ui:ui-test-junit4:${FocusVersions.AndroidX.compose}"
const val androidx_compose_ui_test_manifest = "androidx.compose.ui:ui-test-manifest:${FocusVersions.AndroidX.compose}"
const val androidx_compose_ui_tooling = "androidx.compose.ui:ui-tooling:${FocusVersions.AndroidX.compose}"
const val androidx_compose_foundation = "androidx.compose.foundation:foundation:${FocusVersions.AndroidX.compose}"
const val androidx_compose_material = "androidx.compose.material:material:${FocusVersions.AndroidX.compose}"
const val androidx_compose_runtime_livedata = "androidx.compose.runtime:runtime-livedata:${FocusVersions.AndroidX.compose}"
const val androidx_constraint_layout_compose =
"androidx.constraintlayout:constraintlayout-compose:${Versions.AndroidX.constraint_layout_compose}"
const val androidx_constraint_layout = "androidx.constraintlayout:constraintlayout:${Versions.AndroidX.constraint_layout}"
const val androidx_core_ktx = "androidx.core:core-ktx:${Versions.AndroidX.core}"
const val androidx_fragment = "androidx.fragment:fragment:${Versions.AndroidX.fragment}"
"androidx.constraintlayout:constraintlayout-compose:${FocusVersions.AndroidX.constraint_layout_compose}"
const val androidx_constraint_layout = "androidx.constraintlayout:constraintlayout:${FocusVersions.AndroidX.constraint_layout}"
const val androidx_core_ktx = "androidx.core:core-ktx:${FocusVersions.AndroidX.core}"
const val androidx_fragment = "androidx.fragment:fragment:${FocusVersions.AndroidX.fragment}"

const val androidx_palette = "androidx.palette:palette-ktx:${Versions.AndroidX.palette}"
const val androidx_preference = "androidx.preference:preference-ktx:${Versions.AndroidX.preference}"
const val androidx_recyclerview = "androidx.recyclerview:recyclerview:${Versions.AndroidX.recyclerview}"
const val androidx_lifecycle_process = "androidx.lifecycle:lifecycle-process:${Versions.AndroidX.lifecycle}"
const val androidx_lifecycle_viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:${Versions.AndroidX.lifecycle}"
const val androidx_splashscreen = "androidx.core:core-splashscreen:${Versions.AndroidX.splashscreen}"
const val androidx_savedstate = "androidx.savedstate:savedstate-ktx:${Versions.AndroidX.savedstate}"
const val androidx_transition = "androidx.transition:transition:${Versions.AndroidX.transition}"
const val androidx_work_ktx = "androidx.work:work-runtime-ktx:${Versions.AndroidX.work}"
const val androidx_work_testing = "androidx.work:work-testing:${Versions.AndroidX.work}"
const val androidx_palette = "androidx.palette:palette-ktx:${FocusVersions.AndroidX.palette}"
const val androidx_preference = "androidx.preference:preference-ktx:${FocusVersions.AndroidX.preference}"
const val androidx_recyclerview = "androidx.recyclerview:recyclerview:${FocusVersions.AndroidX.recyclerview}"
const val androidx_lifecycle_process = "androidx.lifecycle:lifecycle-process:${FocusVersions.AndroidX.lifecycle}"
const val androidx_lifecycle_viewmodel = "androidx.lifecycle:lifecycle-viewmodel-ktx:${FocusVersions.AndroidX.lifecycle}"
const val androidx_splashscreen = "androidx.core:core-splashscreen:${FocusVersions.AndroidX.splashscreen}"
const val androidx_savedstate = "androidx.savedstate:savedstate-ktx:${FocusVersions.AndroidX.savedstate}"
const val androidx_transition = "androidx.transition:transition:${FocusVersions.AndroidX.transition}"
const val androidx_work_ktx = "androidx.work:work-runtime-ktx:${FocusVersions.AndroidX.work}"
const val androidx_work_testing = "androidx.work:work-testing:${FocusVersions.AndroidX.work}"

const val google_material = "com.google.android.material:material:${Versions.Google.material}"
const val google_accompanist_insets_ui = "com.google.accompanist:accompanist-insets-ui:${Versions.Google.accompanist}"
const val google_play = "com.google.android.play:core:${Versions.Google.play}"
const val kotlin_gradle_plugin = "org.jetbrains.kotlin:kotlin-gradle-plugin:${Versions.Gradle.kotlin_plugin}"
const val android_gradle_plugin = "com.android.tools.build:gradle:${Versions.Gradle.android_plugin}"
const val jna = "net.java.dev.jna:jna:${Versions.ThirdParty.jna}@jar"
const val leakcanary = "com.squareup.leakcanary:leakcanary-android-core:${Versions.ThirdParty.leakcanary}"
const val sentry = "io.sentry:sentry-android:${Versions.ThirdParty.sentry}"
const val google_material = "com.google.android.material:material:${FocusVersions.Google.material}"
const val google_accompanist_insets_ui = "com.google.accompanist:accompanist-insets-ui:${FocusVersions.Google.accompanist}"
const val google_play = "com.google.android.play:core:${FocusVersions.Google.play}"
const val kotlin_gradle_plugin = "org.jetbrains.kotlin:kotlin-gradle-plugin:${FocusVersions.Gradle.kotlin_plugin}"
const val android_gradle_plugin = "com.android.tools.build:gradle:${FocusVersions.Gradle.android_plugin}"
const val jna = "net.java.dev.jna:jna:${FocusVersions.ThirdParty.jna}@jar"
const val leakcanary = "com.squareup.leakcanary:leakcanary-android-core:${FocusVersions.ThirdParty.leakcanary}"
const val sentry = "io.sentry:sentry-android:${FocusVersions.ThirdParty.sentry}"

const val kotlin_coroutines = "org.jetbrains.kotlinx:kotlinx-coroutines-core:${Versions.Kotlin.coroutines}"
const val kotlin_coroutines_android = "org.jetbrains.kotlinx:kotlinx-coroutines-android:${Versions.Kotlin.coroutines}"
const val kotlin_coroutines = "org.jetbrains.kotlinx:kotlinx-coroutines-core:${FocusVersions.Kotlin.coroutines}"
const val kotlin_coroutines_android = "org.jetbrains.kotlinx:kotlinx-coroutines-android:${FocusVersions.Kotlin.coroutines}"

const val adjust = "com.adjust.sdk:adjust-android:${Versions.Adjust.adjust}"
const val install_referrer = "com.android.installreferrer:installreferrer:${Versions.Adjust.install_referrer}"
const val adjust = "com.adjust.sdk:adjust-android:${FocusVersions.Adjust.adjust}"
const val install_referrer = "com.android.installreferrer:installreferrer:${FocusVersions.Adjust.install_referrer}"

const val androidx_junit_ktx = "androidx.test.ext:junit-ktx:${Versions.Testing.androidx_ext_junit}"
const val androidx_orchestrator = "androidx.test:orchestrator:${Versions.Testing.androidx_orchestrator}"
const val androidx_test_core = "androidx.test:core:${Versions.Testing.androidx_core}"
const val androidx_test_core_ktx = "androidx.test:core-ktx:${Versions.Testing.androidx_core}"
const val androidx_test_rules = "androidx.test:rules:${Versions.Testing.androidx_core}"
const val androidx_test_runner = "androidx.test:runner:${Versions.Testing.androidx_core}"
const val androidx_uiautomator = "androidx.test.uiautomator:uiautomator:${Versions.Testing.androidx_uiautomator}"
const val espresso_contrib = "androidx.test.espresso:espresso-contrib:${Versions.Testing.androidx_espresso}"
const val espresso_core = "androidx.test.espresso:espresso-core:${Versions.Testing.androidx_espresso}"
const val espresso_idling_resource = "androidx.test.espresso:espresso-idling-resource:${Versions.Testing.androidx_espresso}"
const val espresso_intents = "androidx.test.espresso:espresso-intents:${Versions.Testing.androidx_espresso}"
const val espresso_web = "androidx.test.espresso:espresso-web:${Versions.Testing.androidx_espresso}"
const val falcon = "com.jraska:falcon:${Versions.Testing.falcon}"
const val fastlane = "tools.fastlane:screengrab:${Versions.Testing.fastlane}"
const val testing_robolectric = "org.robolectric:robolectric:${Versions.Testing.robolectric}"
const val testing_mockito = "org.mockito:mockito-core:${Versions.Testing.mockito}"
const val testing_mockwebserver = "com.squareup.okhttp3:mockwebserver:${Versions.Testing.mockwebserver}"
const val testing_coroutines = "org.jetbrains.kotlinx:kotlinx-coroutines-test:${Versions.Kotlin.coroutines}"
const val androidx_junit_ktx = "androidx.test.ext:junit-ktx:${FocusVersions.Testing.androidx_ext_junit}"
const val androidx_orchestrator = "androidx.test:orchestrator:${FocusVersions.Testing.androidx_orchestrator}"
const val androidx_test_core = "androidx.test:core:${FocusVersions.Testing.androidx_core}"
const val androidx_test_core_ktx = "androidx.test:core-ktx:${FocusVersions.Testing.androidx_core}"
const val androidx_test_rules = "androidx.test:rules:${FocusVersions.Testing.androidx_core}"
const val androidx_test_runner = "androidx.test:runner:${FocusVersions.Testing.androidx_core}"
const val androidx_uiautomator = "androidx.test.uiautomator:uiautomator:${FocusVersions.Testing.androidx_uiautomator}"
const val espresso_contrib = "androidx.test.espresso:espresso-contrib:${FocusVersions.Testing.androidx_espresso}"
const val espresso_core = "androidx.test.espresso:espresso-core:${FocusVersions.Testing.androidx_espresso}"
const val espresso_idling_resource = "androidx.test.espresso:espresso-idling-resource:${FocusVersions.Testing.androidx_espresso}"
const val espresso_intents = "androidx.test.espresso:espresso-intents:${FocusVersions.Testing.androidx_espresso}"
const val espresso_web = "androidx.test.espresso:espresso-web:${FocusVersions.Testing.androidx_espresso}"
const val falcon = "com.jraska:falcon:${FocusVersions.Testing.falcon}"
const val fastlane = "tools.fastlane:screengrab:${FocusVersions.Testing.fastlane}"
const val testing_robolectric = "org.robolectric:robolectric:${FocusVersions.Testing.robolectric}"
const val testing_mockito = "org.mockito:mockito-core:${FocusVersions.Testing.mockito}"
const val testing_mockwebserver = "com.squareup.okhttp3:mockwebserver:${FocusVersions.Testing.mockwebserver}"
const val testing_coroutines = "org.jetbrains.kotlinx:kotlinx-coroutines-test:${FocusVersions.Kotlin.coroutines}"

const val testing_junit_api = "org.junit.jupiter:junit-jupiter-api:${Versions.Testing.junit}"
const val testing_junit_engine = "org.junit.jupiter:junit-jupiter-engine:${Versions.Testing.junit}"
const val testing_junit_params = "org.junit.jupiter:junit-jupiter-params:${Versions.Testing.junit}"
const val testing_junit_api = "org.junit.jupiter:junit-jupiter-api:${FocusVersions.Testing.junit}"
const val testing_junit_engine = "org.junit.jupiter:junit-jupiter-engine:${FocusVersions.Testing.junit}"
const val testing_junit_params = "org.junit.jupiter:junit-jupiter-params:${FocusVersions.Testing.junit}"
}
2 changes: 1 addition & 1 deletion taskcluster/ci/toolchain/android.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ linux64-android-gradle-dependencies:
resources:
- taskcluster/scripts/toolchain/android-gradle-dependencies.sh
- taskcluster/scripts/toolchain/android-gradle-dependencies/**
- buildSrc/src/main/java/Dependencies.kt
- buildSrc/src/main/java/FocusDependencies.kt
- buildSrc/src/main/java/AndroidComponents.kt
toolchain-artifact: public/build/android-gradle-dependencies.tar.xz
toolchain-alias: android-gradle-dependencies
Expand Down

0 comments on commit 14305bd

Please sign in to comment.