Angela Yu f777167272
chore: set up new snippets modules for region tags (#1368)
* chore: move MapsCompose.kt to snippets/app-compose app

* chore: create app-places-ktx snippets module with places-ktx install snippet

* chore: create app-maps-rx snippets module

* chore: create app-ktx snippets module

* chore: add app-utils-ktx snippets module

* chore: rename app-maps-rx to app-rx

* chore: add app-utils snippets module

* chore: move region tag from tutorials to snippets for play services sdk dependency

* chore: move kotlin utils to app-utils-ktx module

* chore: move utils and utils-ktx snippets into corresponding modules

* chore: finalize maps sdk snippets

* chore: upgrade AGP and add namespaces

* chore: fix build issues

* chore: udpate build workflow to Java 17

* chore: fix build errors

* chore: remove v3 files

* Revert "chore: remove v3 files"

This reverts commit f70c47bd0cbd5ed73dfd43199371dcfc6afd6350.

* chore: add default PLACES_API_KEY to Current Place tutorial

* chore: fix tutorial builds
2023-10-31 09:33:26 -07:00

89 lines
2.9 KiB
Groovy

// [START maps_android_secrets_gradle_plugin]
plugins {
// [START_EXCLUDE]
id 'com.android.application'
id 'kotlin-android'
// [END_EXCLUDE]
id 'com.google.android.libraries.mapsplatform.secrets-gradle-plugin'
}
// [END maps_android_secrets_gradle_plugin]
android {
compileSdk 33
defaultConfig {
applicationId "com.google.maps.example"
minSdk 24
targetSdk 33
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildFeatures {
buildConfig = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
flavorDimensions "version"
productFlavors {
gms {
dimension "version"
applicationIdSuffix ".gms"
versionNameSuffix "-gms"
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}
namespace 'com.google.maps.example'
}
// [START maps_android_play_services_maps_dependency]
dependencies {
// [START_EXCLUDE silent]
implementation fileTree(dir: "libs", include: ["*.jar"])
implementation 'org.jetbrains.kotlin:kotlin-stdlib:1.9.0'
implementation 'androidx.core:core-ktx:1.9.0'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation "androidx.compose.foundation:foundation:1.4.0-beta01"
implementation "androidx.compose.material:material:1.4.0-beta01"
implementation 'com.google.android.material:material:1.8.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'androidx.navigation:navigation-fragment-ktx:2.5.3'
implementation 'androidx.navigation:navigation-ui-ktx:2.5.3'
implementation 'com.android.volley:volley:1.2.1'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.5.1'
implementation 'com.google.android.libraries.places:places:3.0.0'
// [END_EXCLUDE]
// Maps SDK for Android
implementation 'com.google.android.gms:play-services-maps:18.2.0'
}
// [END maps_android_play_services_maps_dependency]
// [START maps_android_secrets_gradle_plugin_config]
secrets {
// Optionally specify a different file name containing your secrets.
// The plugin defaults to "local.properties"
propertiesFileName = "secrets.properties"
// A properties file containing default secret values. This file can be
// checked in version control.
defaultPropertiesFileName = 'local.defaults.properties'
// Configure which keys should be ignored by the plugin by providing regular expressions.
// "sdk.dir" is ignored by default.
ignoreList.add("keyToIgnore") // Ignore the key "keyToIgnore"
ignoreList.add("sdk.*") // Ignore all keys matching the regexp "sdk.*"
}
// [END maps_android_secrets_gradle_plugin_config]