todos-contra-el-fuego-mobile/android/app/build.gradle
vjrj 4461481668
Some checks failed
ci / analyze (push) Failing after 2m3s
ci / test (push) Failing after 1m26s
release / android (push) Failing after 5m51s
Republish setup: fastlane + Forgejo CI, signing/version fixes, Play-policy link
- support_page: repoint comunes.org link to project page (Play re-approval)
- build.gradle: conditional release signing (debug fallback), versionCode/Name
  from pubspec, drop duplicate google-services plugin
- pubspec: version 1.10.0+10 (versionCode must exceed last uploaded)
- track AndroidManifest.xml (no secrets in it)
- fastlane: Appfile/Fastfile (deploy_play/deploy_metadata/promote_production) +
  Gemfile + es/en/gl store metadata
- .forgejo: ci.yml (analyze+test) + release.yml (tag v* -> signed AAB -> Play internal)
- README + RELEASE.md
2026-07-16 20:49:28 +02:00

95 lines
2.9 KiB
Groovy

plugins {
id 'com.android.application'
id 'kotlin-android'
id 'dev.flutter.flutter-gradle-plugin'
}
def localProperties = new Properties()
def localPropertiesFile = rootProject.file('local.properties')
if (localPropertiesFile.exists()) {
localPropertiesFile.withReader('UTF-8') { reader ->
localProperties.load(reader)
}
}
// Release signing is opt-in: only load key.properties if it exists. Without it
// (CI analyze/test jobs, contributors) builds fall back to debug signing.
def keystorePropertiesFile = rootProject.file("key.properties")
def keystoreProperties = new Properties()
def hasReleaseKeystore = keystorePropertiesFile.exists()
if (hasReleaseKeystore) {
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
}
android {
compileSdkVersion 36
namespace "org.comunes.fires"
lintOptions {
disable 'InvalidPackage'
}
defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId "org.comunes.fires"
minSdkVersion flutter.minSdkVersion
targetSdkVersion 36
// versionCode/versionName come from pubspec.yaml (version: X.Y.Z+CODE)
// so a `v*` git tag maps the release version, matching the tane flow.
versionCode flutter.versionCode
versionName flutter.versionName
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
signingConfigs {
if (hasReleaseKeystore) {
release {
keyAlias keystoreProperties['keyAlias']
keyPassword keystoreProperties['keyPassword']
storeFile file(keystoreProperties['storeFile'])
storePassword keystoreProperties['storePassword']
}
}
}
buildTypes {
release {
// Sign with the release key when available, else debug (contributors/CI).
signingConfig hasReleaseKeystore ? signingConfigs.release : signingConfigs.debug
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
flavorDimensions "flavor-type"
productFlavors {
development {
dimension "flavor-type"
applicationIdSuffix ".dev"
versionNameSuffix "-dev"
}
production {
dimension "flavor-type"
}
}
}
flutter {
source '../..'
}
dependencies {
testImplementation 'junit:junit:4.13.2'
// androidx test dependencies replace old android.support.test
androidTestImplementation 'androidx.test:runner:1.5.2'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
// implementation 'com.google.firebase:firebase-core:15.0.2'
// google recommends 16 but fails because location flutter package deps in 15
}
apply plugin: 'com.google.gms.google-services'