Modificato Jenkinsfile
Some checks failed
WMS - Android (New)/pipeline/head There was a failure building this commit

This commit is contained in:
Giuseppe Scorrano 2025-05-28 10:46:25 +02:00
parent 9cc70f4ee6
commit 7a02e1d8ad
2 changed files with 7 additions and 5 deletions

View File

@ -10,22 +10,23 @@ pipeline {
environment {
// ANDROID_HOME = "/usr/local/android/sdk" // Cambia in base al tuo sistema
JAVA_HOME = tool 'JDK 17.0.6 x64' // Nome dello strumento configurato in Jenkins
GRADLE_HOME = tool 'Gradle 8.13' // Nome dello strumento configurato in Jenkins
PATH = "${env.GRADLE_HOME}/bin:${env.PATH}"
PATH = "${env.GRADLE_HOME}/bin:${env.JAVA_HOME}/bin:${env.PATH}"
}
stages {
stage('Preparing project') {
steps {
powershell "(gc gradle.properties) -replace 'org.gradle.caching=true', 'org.gradle.caching=false' | Out-File -encoding ASCII gradle.properties"
powershell "(gc gradle.properties) -replace 'org.gradle.unsafe.configuration-cache=ON', 'org.gradle.unsafe.configuration-cache=OFF' | Out-File -encoding ASCII gradle.properties"
// powershell "(gc gradle.properties) -replace 'org.gradle.caching=true', 'org.gradle.caching=false' | Out-File -encoding ASCII gradle.properties"
// powershell "(gc gradle.properties) -replace 'org.gradle.unsafe.configuration-cache=ON', 'org.gradle.unsafe.configuration-cache=OFF' | Out-File -encoding ASCII gradle.properties"
}
}
stage('Build') {
steps {
bat "gradle app:build --stacktrace"
bat "./gradlew assembleRelease"
}
}
}

View File

@ -53,7 +53,8 @@ android {
ext.enableCrashlytics = false
}
release {
minifyEnabled false
minifyEnabled true // Abilita la minimizzazione del codice
shrinkResources true // Rimuove risorse non utilizzate
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
}