From 5638c03e76c69072d9cd88897b26f4e96eff96bf Mon Sep 17 00:00:00 2001 From: Marcel Peterkau Date: Mon, 2 Jun 2025 20:29:13 +0200 Subject: [PATCH] added Stage to build Littlefs --- Jenkinsfile | 34 ++++++++++++++++++++++------------ 1 file changed, 22 insertions(+), 12 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 342da61..0f02ba3 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -52,26 +52,36 @@ wifi_ap_password = DummyAP } } + stage('📁 Build Filesystem (LittleFS)') { + steps { + dir('Software') { + sh """ + ${env.VENV_PATH}/bin/platformio run -t buildfs -e ${params.BUILD_ENV} + """ + } + } + } + stage('📦 Find & Archive Firmware') { steps { dir('Software') { - script { - echo "🔍 Suche nach Firmware (.fw.bin) und Filesystem (.fs.gz) Artefakten..." + script { + echo "🔍 Suche nach Firmware (.fw.bin) und Filesystem (.fs.gz) Artefakten..." - def firmwareFiles = findFiles(glob: '.pio/build/**/*.fw.bin') - def fsFiles = findFiles(glob: '.pio/build/**/*.fs.gz') + def firmwareFiles = findFiles(glob: '.pio/build/**/*.fw.bin') + def fsFiles = findFiles(glob: '.pio/build/**/*.fs.gz') - if (firmwareFiles.length == 0 && fsFiles.length == 0) { - echo "⚠️ Keine passenden Artefakte (.fw.bin / .fs.gz) gefunden – nichts zu archivieren." - } else { - firmwareFiles.each { echo "📦 Firmware: ${it.path}" } - fsFiles.each { echo "📦 Filesystem: ${it.path}" } + if (firmwareFiles.length == 0 && fsFiles.length == 0) { + echo "⚠️ Keine passenden Artefakte (.fw.bin / .fs.gz) gefunden – nichts zu archivieren." + } else { + firmwareFiles.each { echo "📦 Firmware: ${it.path}" } + fsFiles.each { echo "📦 Filesystem: ${it.path}" } - def allArtifacts = (firmwareFiles + fsFiles).collect { it.path } - archiveArtifacts artifacts: allArtifacts.join(', ') + def allArtifacts = (firmwareFiles + fsFiles).collect { it.path } + archiveArtifacts artifacts: allArtifacts.join(', ') + } } } - } } }