Ziel fürs Erste: TestFlight + Play-Internal-Testing (kein öffentlicher Store-Eintrag). Code-seitig vorbereitet, alle Konsolen-Schritte für Chris in firebase-einrichtung.md (Schritt 9-11) dokumentiert: - App Check Client-Integration (Debug-Provider), Functions erzwingen es noch nicht (zweistufiger Rollout, siehe Doku) - iOS: ITSAppUsesNonExemptEncryption gesetzt - Android: Release-Signing über key.properties vorbereitet (Upload-Key fehlt noch bewusst, Erzeugung ist Chris' Schritt) - flutter_launcher_icons vorbereitet für künftiges echtes App-Icon - Datenschutzerklärung entworfen (docs/legal/datenschutz.html) Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
75 lines
2.5 KiB
Text
75 lines
2.5 KiB
Text
import java.io.FileInputStream
|
|
import java.util.Properties
|
|
|
|
plugins {
|
|
id("com.android.application")
|
|
// START: FlutterFire Configuration
|
|
id("com.google.gms.google-services")
|
|
// END: FlutterFire Configuration
|
|
id("kotlin-android")
|
|
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
|
id("dev.flutter.flutter-gradle-plugin")
|
|
}
|
|
|
|
// Release-Signing: Werte kommen aus android/key.properties (nicht im Repo,
|
|
// siehe key.properties.example). Ohne die Datei wird weiterhin mit dem
|
|
// Debug-Key signiert, damit lokale Debug-Builds unverändert funktionieren.
|
|
val keystorePropertiesFile = rootProject.file("key.properties")
|
|
val keystoreProperties = Properties()
|
|
val hasReleaseSigning = keystorePropertiesFile.exists()
|
|
if (hasReleaseSigning) {
|
|
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
|
|
}
|
|
|
|
android {
|
|
namespace = "dev.leafittome.app"
|
|
compileSdk = flutter.compileSdkVersion
|
|
ndkVersion = flutter.ndkVersion
|
|
|
|
compileOptions {
|
|
sourceCompatibility = JavaVersion.VERSION_17
|
|
targetCompatibility = JavaVersion.VERSION_17
|
|
}
|
|
|
|
kotlinOptions {
|
|
jvmTarget = JavaVersion.VERSION_17.toString()
|
|
}
|
|
|
|
defaultConfig {
|
|
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
|
|
applicationId = "dev.leafittome.app"
|
|
// You can update the following values to match your application needs.
|
|
// For more information, see: https://flutter.dev/to/review-gradle-config.
|
|
minSdk = flutter.minSdkVersion
|
|
targetSdk = flutter.targetSdkVersion
|
|
versionCode = flutter.versionCode
|
|
versionName = flutter.versionName
|
|
}
|
|
|
|
signingConfigs {
|
|
if (hasReleaseSigning) {
|
|
create("release") {
|
|
keyAlias = keystoreProperties["keyAlias"] as String
|
|
keyPassword = keystoreProperties["keyPassword"] as String
|
|
storeFile = file(keystoreProperties["storeFile"] as String)
|
|
storePassword = keystoreProperties["storePassword"] as String
|
|
}
|
|
}
|
|
}
|
|
|
|
buildTypes {
|
|
release {
|
|
// Nutzt den echten Upload-Key, sobald key.properties existiert;
|
|
// bis dahin Fallback auf den Debug-Key (siehe oben).
|
|
signingConfig = if (hasReleaseSigning) {
|
|
signingConfigs.getByName("release")
|
|
} else {
|
|
signingConfigs.getByName("debug")
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
flutter {
|
|
source = "../.."
|
|
}
|