Merge remote-tracking branch 'origin/main'
Build & Deploy Pluriwave / Análisis de código (push) Failing after 13m6s
Build & Deploy Pluriwave / Build APK + AAB release (push) Failing after 14m58s

# Conflicts:
#	android/app/src/main/kotlin/es/freetimelab/pluriwave/AlarmScheduler.kt
This commit is contained in:
Javier Bautista Fernández
2026-05-28 12:31:12 +02:00
4 changed files with 71 additions and 19 deletions
+33 -10
View File
@@ -7,17 +7,22 @@ on:
env: env:
PATH: /opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin PATH: /opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
ANDROID_HOME: /Users/freetlab/Library/Android/sdk ANDROID_HOME: /Users/freetlab/Library/Android/sdk
KEYSTORE_PATH: /Users/freetlab/.openclaw/workspace/.secure/pluriwave/pluriwave-upload.jks
KEYSTORE_ALIAS: pluriwave-upload
jobs: jobs:
analizar: analizar:
name: Análisis de código name: Análisis de código
runs-on: [self-hosted, macos, arm64, flutter] runs-on: [self-hosted, macos, arm64, flutter]
steps: steps:
- uses: actions/checkout@v4 - name: Clonar repo
run: |
git clone https://ShanaiaBot:${{ secrets.GITEA_TOKEN }}@git.freetimelab.es/FreeTLab/pluriwave.git .
git fetch origin main
- name: Obtener dependencias - name: Obtener dependencias
run: flutter pub get run: flutter pub get
#- name: Generar l10n
# run: flutter gen-l10n
- name: Analizar código - name: Analizar código
run: flutter analyze --no-fatal-infos --no-fatal-warnings run: flutter analyze --no-fatal-infos --no-fatal-warnings
@@ -27,7 +32,24 @@ jobs:
needs: analizar needs: analizar
if: ${{ gitea.ref == 'refs/heads/main' }} if: ${{ gitea.ref == 'refs/heads/main' }}
steps: steps:
- uses: actions/checkout@v4 - name: Clonar repo
run: |
git clone https://ShanaiaBot:${{ secrets.GITEA_TOKEN }}@git.freetimelab.es/FreeTLab/pluriwave.git .
git fetch origin main
- name: Configurar keystore de firma
env:
KEYSTORE_PASSWORD: ${{ secrets.PLURIWAVE_KEYSTORE_PASSWORD }}
run: |
if [ ! -f "$KEYSTORE_PATH" ]; then
echo "ERROR: Keystore no encontrado en $KEYSTORE_PATH"
exit 1
fi
echo "storeFile=$KEYSTORE_PATH" > android/key.properties
echo "storePassword=$KEYSTORE_PASSWORD" >> android/key.properties
echo "keyAlias=$KEYSTORE_ALIAS" >> android/key.properties
echo "keyPassword=$KEYSTORE_PASSWORD" >> android/key.properties
echo "✅ Keystore configurado"
- name: Bump versión patch + commit - name: Bump versión patch + commit
run: | run: |
@@ -46,7 +68,6 @@ jobs:
git add pubspec.yaml git add pubspec.yaml
git commit -m "chore: bump version to ${NEW_VERSION} [ci skip]" git commit -m "chore: bump version to ${NEW_VERSION} [ci skip]"
git push origin main git push origin main
echo "NEW_SEMVER=${MAJOR}.${MINOR}.${NEW_PATCH}" >> $GITHUB_ENV
- name: Extraer versión - name: Extraer versión
id: version id: version
@@ -59,15 +80,17 @@ jobs:
- name: Obtener dependencias - name: Obtener dependencias
run: flutter pub get run: flutter pub get
#- name: Generar l10n
# run: flutter gen-l10n
- name: Build APK release - name: Build APK release
run: flutter build apk --release run: flutter build apk --release
- name: Build AAB release - name: Build AAB release
run: flutter build appbundle --release run: flutter build appbundle --release
- name: Verificar firma
run: |
echo "=== Huellas del keystore ==="
keytool -list -v -keystore "$KEYSTORE_PATH" -alias $KEYSTORE_ALIAS -storepass "$KEYSTORE_PASSWORD" 2>/dev/null | grep "SHA1:\|SHA256:" || echo "OK"
- name: Publicar en ftl-builds (Zimaboard) - name: Publicar en ftl-builds (Zimaboard)
run: | run: |
VERSION="${{ steps.version.outputs.version }}" VERSION="${{ steps.version.outputs.version }}"
@@ -94,9 +117,9 @@ jobs:
BOT_TOKEN=$(plutil -extract 'EnvironmentVariables:TELEGRAM_BOT_TOKEN' raw /Users/freetlab/Library/LaunchAgents/ai.openclaw.gateway.plist 2>/dev/null || echo "") BOT_TOKEN=$(plutil -extract 'EnvironmentVariables:TELEGRAM_BOT_TOKEN' raw /Users/freetlab/Library/LaunchAgents/ai.openclaw.gateway.plist 2>/dev/null || echo "")
if [ -z "$BOT_TOKEN" ]; then exit 0; fi if [ -z "$BOT_TOKEN" ]; then exit 0; fi
if [ "${{ job.status }}" = "success" ]; then if [ "${{ job.status }}" = "success" ]; then
MSG="✅ *Pluriwave* v${VERSION} build OK · ${COMMIT}%0AAPK + AAB en builds.freetimelab.es" MSG="✅ *Pluriwave* v${VERSION} build OK (firma release) · ${COMMIT}%0AAPK + AAB en builds.freetimelab.es"
else else
MSG="❌ *Pluriwave* v${VERSION} build FAILED · ${COMMIT}" MSG="❌ *Pluriwave* v${VERSION} build FAILED · ${COMMIT}"
fi fi
curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \ curl -s -X POST "https://api.telegram.org/bot${BOT_TOKEN}/sendMessage" \
-d "chat_id=221721467" -d "parse_mode=Markdown" -d "text=${MSG}" || true -d "chat_id=221721467" -d "parse_mode=Markdown" -d "text=${MSG}" || true
+35 -7
View File
@@ -1,10 +1,21 @@
plugins { plugins {
id("com.android.application") id("com.android.application")
id("kotlin-android") id("kotlin-android")
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
id("dev.flutter.flutter-gradle-plugin") id("dev.flutter.flutter-gradle-plugin")
} }
import java.util.Properties
val keystoreProperties = Properties()
val keystorePropertiesFile = rootProject.file("key.properties")
if (keystorePropertiesFile.exists()) {
keystorePropertiesFile.inputStream().use { keystoreProperties.load(it) }
}
fun secret(name: String, propertyName: String): String? =
keystoreProperties.getProperty(propertyName)?.takeIf { it.isNotBlank() }
?: System.getenv(name)?.takeIf { it.isNotBlank() }
android { android {
namespace = "es.freetimelab.pluriwave" namespace = "es.freetimelab.pluriwave"
compileSdk = flutter.compileSdkVersion compileSdk = flutter.compileSdkVersion
@@ -20,21 +31,38 @@ android {
} }
defaultConfig { defaultConfig {
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
applicationId = "es.freetimelab.pluriwave" applicationId = "es.freetimelab.pluriwave"
// 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 minSdk = flutter.minSdkVersion
targetSdk = flutter.targetSdkVersion targetSdk = flutter.targetSdkVersion
versionCode = flutter.versionCode versionCode = flutter.versionCode
versionName = flutter.versionName versionName = flutter.versionName
} }
signingConfigs {
create("release") {
val storeFilePath = secret("KEYSTORE_PATH", "storeFile")
val storePasswordValue = secret("KEYSTORE_PASSWORD", "storePassword")
val keyAliasValue = secret("KEYSTORE_ALIAS", "keyAlias")
val keyPasswordValue = secret("KEY_PASSWORD", "keyPassword")
if (!storeFilePath.isNullOrBlank()) {
storeFile = file(storeFilePath)
}
if (!storePasswordValue.isNullOrBlank()) {
storePassword = storePasswordValue
}
if (!keyAliasValue.isNullOrBlank()) {
keyAlias = keyAliasValue
}
if (!keyPasswordValue.isNullOrBlank()) {
keyPassword = keyPasswordValue
}
}
}
buildTypes { buildTypes {
release { release {
// TODO: Add your own signing config for the release build. signingConfig = signingConfigs.getByName("release")
// Signing with the debug keys for now, so `flutter run --release` works.
signingConfig = signingConfigs.getByName("debug")
} }
} }
} }
@@ -508,7 +508,8 @@ class AlarmScheduler(private val context: Context) {
appContext, appContext,
requestCode(id, 2), requestCode(id, 2),
Intent(appContext, MainActivity::class.java).apply { Intent(appContext, MainActivity::class.java).apply {
this.flags = Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TOP this.flags =
Intent.FLAG_ACTIVITY_NEW_TASK or Intent.FLAG_ACTIVITY_CLEAR_TOP
putExtra(PluriWaveAlarmReceiver.EXTRA_ALARM_ACTION, PluriWaveAlarmReceiver.ACTION_FIRE) putExtra(PluriWaveAlarmReceiver.EXTRA_ALARM_ACTION, PluriWaveAlarmReceiver.ACTION_FIRE)
}, },
flags or PendingIntent.FLAG_IMMUTABLE flags or PendingIntent.FLAG_IMMUTABLE
+1 -1
View File
@@ -1,7 +1,7 @@
name: pluriwave name: pluriwave
description: "Radio mundial con ecualizador, reconocimiento de canciones y UI premium" description: "Radio mundial con ecualizador, reconocimiento de canciones y UI premium"
publish_to: 'none' publish_to: 'none'
version: 0.1.48+49 version: 0.1.53+54
environment: environment:
sdk: ^3.7.0 sdk: ^3.7.0