feat(android): configurar soporte de firma de release, plantilla key.properties y resguardo en gitignore
This commit is contained in:
+2
-1
@@ -31,12 +31,13 @@
|
||||
- [x] **Creación del archivo `agents.md`:** Establecida la guía del agente en la raíz del proyecto según el estándar de Telcotronics.
|
||||
- [x] **Registro en el MCP de Infraestructura:** Servicio registrado exitosamente con ID 24 (`como-gasto`) en el MCP en vivo (`http://192.168.10.160:3006/sse`).
|
||||
- [x] **Registro y Autorización en Hub sigma-robot:** Agente autorizado con ID 74, token Bearer configurado en `.env` (0600) y presentación formal enviada al canal `#general` del ecosistema.
|
||||
- [x] **Configuración de Firma y Plantilla de Keystore (Android):** Soporte condicional para `android/key.properties` en `build.gradle`, plantilla `android/key.properties.example` y protección de `*.jks`/`*.keystore` en `.gitignore`.
|
||||
- [x] **Revisión de Commits y Sincronización:** Confirmado y publicado en `origin/master` con árbol de trabajo 100% limpio.
|
||||
|
||||
---
|
||||
|
||||
## 2. Siguientes Pasos Operacionales 🚀
|
||||
|
||||
- [ ] **Firma y Empaque de Producción:** Configurar `key.properties` para generar el Android App Bundle (`.aab`) y build de iOS (`.ipa`).
|
||||
- [ ] **Empaque de Producción:** Completar `key.properties` con la clave real y generar el Android App Bundle (`.aab`) o build de iOS (`.ipa`).
|
||||
- [ ] **Carga en Consola de Google Play:** Subir ficha técnica, capturas 2:1, ícono 512×512, gráfico 1024×500 y credenciales demo (`demo@comogasto.com` / `123456`).
|
||||
- [ ] **Carga en App Store Connect:** Subir metadatos y notas de revisión de la app.
|
||||
|
||||
@@ -80,4 +80,6 @@ ios/Flutter/flutter_export_environment.sh
|
||||
.env.*
|
||||
servers.conf
|
||||
/android/key.properties
|
||||
*.jks
|
||||
*.keystore
|
||||
|
||||
|
||||
@@ -9,3 +9,5 @@ GeneratedPluginRegistrant.java
|
||||
# Remember to never publicly share your keystore.
|
||||
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
|
||||
key.properties
|
||||
*.jks
|
||||
*.keystore
|
||||
|
||||
@@ -6,6 +6,13 @@ if (localPropertiesFile.exists()) {
|
||||
}
|
||||
}
|
||||
|
||||
// Carga de credenciales de firma de producción desde android/key.properties (ignorado por Git)
|
||||
def keystoreProperties = new Properties()
|
||||
def keystorePropertiesFile = rootProject.file('key.properties')
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(new FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
def flutterRoot = localProperties.getProperty('flutter.sdk')
|
||||
if (flutterRoot == null) {
|
||||
throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
|
||||
@@ -47,11 +54,23 @@ android {
|
||||
multiDexEnabled true
|
||||
}
|
||||
|
||||
// Configuración de firmas: se usa la clave de producción si key.properties existe;
|
||||
// de lo contrario, se mantiene la firma debug para no romper entornos locales de desarrollo.
|
||||
signingConfigs {
|
||||
release {
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keyAlias keystoreProperties['keyAlias']
|
||||
keyPassword keystoreProperties['keyPassword']
|
||||
storeFile keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
|
||||
storePassword keystoreProperties['storePassword']
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
// TODO: Add your own signing config for the release build.
|
||||
// Signing with the debug keys for now, so `flutter run --release` works.
|
||||
signingConfig signingConfigs.debug
|
||||
// Asigna automáticamente signingConfigs.release si el archivo key.properties está presente
|
||||
signingConfig (keystorePropertiesFile.exists() ? signingConfigs.release : signingConfigs.debug)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,7 @@
|
||||
# Plantilla de configuración de firma para Android Release (Google Play)
|
||||
# Copiar este archivo como 'android/key.properties' y completar con los valores reales.
|
||||
# El archivo 'key.properties' está ignorado en .gitignore para resguardar las claves.
|
||||
storeFile=upload-keystore.jks
|
||||
storePassword=REPLACE_LOCALLY
|
||||
keyAlias=como-gasto-upload
|
||||
keyPassword=REPLACE_LOCALLY
|
||||
Reference in New Issue
Block a user