android-samples/WearOS/Wearable/build.gradle.kts
dkhawk e4285607ae chore: update dependencies
Updates the following dependencies:

* compileSdk to 35
* androidx.core:core-ktx to 1.15.0
* org.jetbrains.kotlin:kotlin-stdlib-jdk7 to 2.0.21
* id("com.android.application") to 8.8.0
* id("org.jetbrains.kotlin.android") to 2.1.0
* Gradle to 8.11.1
* Also renames the savedState variable to savedInstanceState in AmbientActivity.kt and MainActivity.kt to match the base class.
2025-01-14 09:49:02 -07:00

78 lines
2.3 KiB
Plaintext

/*
* Copyright 2024 Google LLC
*
* 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("com.google.android.libraries.mapsplatform.secrets-gradle-plugin")
kotlin("android") // The Kotlin plugin is applied differently in Kotlin DSL
}
android {
compileSdk = 35
defaultConfig {
applicationId = "com.example.wearos"
minSdk = 23
targetSdk = 31
versionCode = 1
versionName = "1.0"
}
buildTypes {
getByName("release") {
isMinifyEnabled = false
proguardFiles(getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro")
}
}
namespace = "com.example.wearosmap"
kotlinOptions {
jvmTarget = "21"
}
kotlin {
jvmToolchain(21)
}
}
// [START maps_wear_os_dependencies]
dependencies {
// [START_EXCLUDE]
implementation("androidx.core:core-ktx:1.15.0")
implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk7:2.0.21")
// [END_EXCLUDE]
compileOnly("com.google.android.wearable:wearable:2.9.0")
implementation("com.google.android.support:wearable:2.9.0")
implementation("com.google.android.gms:play-services-maps:19.0.0")
// This dependency is necessary for ambient mode
implementation("androidx.wear:wear:1.3.0")
}
// [END maps_wear_os_dependencies]
secrets {
// To add your Maps API key to this project:
// 1. If the secrets.properties file does not exist, create it in the same folder as the local.properties file.
// 2. Add this line, where YOUR_API_KEY is your API key:
// MAPS_API_KEY=YOUR_API_KEY
propertiesFileName = "secrets.properties"
// A properties file containing default secret values. This file can be
// checked in version control.
defaultPropertiesFileName = "local.defaults.properties"
}