Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Merge branch 'main' into iangclifton/jetsurvey-m3
This updates Jetsurvey to use the version catalog. The only meaningful
differences from main are to use material3 and accompanist
systemuicontroller in build.gradle.kts.
  • Loading branch information
IanGClifton committed Aug 23, 2022
commit 9ee2e370970d7101fa5f264c0de4a89478703260
156 changes: 0 additions & 156 deletions Crane/app/build.gradle

This file was deleted.

149 changes: 149 additions & 0 deletions Crane/app/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,149 @@
@file:Suppress("UnstableApiUsage")

/*
* Copyright 2019 Google, Inc.
*
* 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
*
* http://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.
*/

plugins {
id("com.android.application")
id("kotlin-android")
id("kotlin-kapt")
id("dagger.hilt.android.plugin")
id("com.google.android.libraries.mapsplatform.secrets-gradle-plugin")
}

android {
compileSdk = libs.versions.compileSdk.get().toInt()

defaultConfig {
applicationId = "androidx.compose.samples.crane"
minSdk = libs.versions.minSdk.get().toInt()
targetSdk = libs.versions.targetSdk.get().toInt()
versionCode = 1
versionName = "1.0"
testInstrumentationRunner = "androidx.compose.samples.crane.CustomTestRunner"
javaCompileOptions {
annotationProcessorOptions {
arguments["dagger.hilt.disableModulesHaveInstallInCheck"] = "true"
}
}
}

signingConfigs {
// We use a bundled debug keystore, to allow debug builds from CI to be upgradable
named("debug") {
storeFile = rootProject.file("debug.keystore")
storePassword = "android"
keyAlias = "androiddebugkey"
keyPassword = "android"
}
}

buildTypes {
getByName("debug") {
signingConfig = signingConfigs.getByName("debug")
}

getByName("release") {
isMinifyEnabled = true
signingConfig = signingConfigs.getByName("debug")
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-rules.pro")
}

create("benchmark") {
initWith(getByName("release"))
signingConfig = signingConfigs.getByName("debug")
matchingFallbacks.add("release")
proguardFiles(getDefaultProguardFile("proguard-android-optimize.txt"),
"proguard-benchmark-rules.pro")
isDebuggable = false
}
}

compileOptions {
isCoreLibraryDesugaringEnabled = true

sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}

buildFeatures {
compose = true

}

composeOptions {
kotlinCompilerExtensionVersion = libs.versions.compose.compiler.get()
}

packagingOptions {
// Multiple dependency bring these files in. Exclude them to enable
// our test APK to build (has no effect on our AARs)
excludes += "/META-INF/AL2.0"
excludes += "/META-INF/LGPL2.1"
}
}

dependencies {
implementation(libs.kotlin.stdlib)
implementation(libs.kotlinx.coroutines.android)

implementation(libs.googlemaps.maps)
implementation(libs.googlemaps.compose)

implementation(libs.androidx.appcompat)
implementation(libs.androidx.activity.compose)
implementation(libs.androidx.compose.runtime)
implementation(libs.androidx.compose.foundation)
implementation(libs.androidx.compose.foundation.layout)
implementation(libs.androidx.compose.ui.util)
implementation(libs.androidx.compose.material)
implementation(libs.androidx.compose.materialWindow)
implementation(libs.androidx.compose.animation)
implementation(libs.androidx.compose.material.iconsExtended)
implementation(libs.androidx.compose.ui.tooling.preview)
implementation(libs.androidx.compose.runtime.livedata)
debugImplementation(libs.androidx.compose.ui.tooling)
implementation(libs.androidx.navigation.compose)

implementation(libs.androidx.lifecycle.viewModelCompose)

implementation(libs.androidx.hilt.navigation.compose)
implementation(libs.hilt.android)
kapt(libs.hilt.compiler)
kapt(libs.hilt.ext.compiler)

implementation(libs.coil.kt.compose)

debugImplementation(libs.androidx.compose.ui.test.manifest)

androidTestImplementation(libs.junit)
androidTestImplementation(libs.androidx.test.core)
androidTestImplementation(libs.androidx.test.runner)
androidTestImplementation(libs.androidx.test.espresso.core)
androidTestImplementation(libs.androidx.test.rules)
androidTestImplementation(libs.androidx.test.ext.junit)
androidTestImplementation(libs.kotlinx.coroutines.test)
androidTestImplementation(libs.androidx.compose.ui.test)
androidTestImplementation(libs.androidx.compose.ui.test.junit4)
androidTestImplementation(libs.hilt.android.testing)
coreLibraryDesugaring(libs.core.jdk.desugaring)
kaptAndroidTest(libs.hilt.compiler)
}

secrets {
defaultPropertiesFileName = "local.defaults.properties"
}
38 changes: 38 additions & 0 deletions Crane/app/src/androidTest/AndroidManifest.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright 2020 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
~
~ http://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.
-->
<!-- Added as workaround for https://github.com/android/android-test/issues/1412 -->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
package="androidx.compose.samples.crane">

<application>

<activity
android:name="androidx.test.core.app.InstrumentationActivityInvoker$BootstrapActivity"
android:exported="true"
tools:node="merge">
<intent-filter tools:node="removeAll" />
</activity>
<activity
android:name="androidx.test.core.app.InstrumentationActivityInvoker$EmptyActivity"
android:exported="true"
tools:node="merge">
<intent-filter tools:node="removeAll" />
</activity>

</application>
</manifest>
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,7 @@ fun CraneTabs(
) {
Text(
modifier = textModifier,
text = title.uppercase(
ConfigurationCompat.getLocales(LocalConfiguration.current)[0]
)
text = title.uppercase()
)
}
}
Expand Down
Loading
You are viewing a condensed version of this merge commit. You can view the full changes here.