From bc85bcf6015312b83a0272ab9e215c1cf1baf540 Mon Sep 17 00:00:00 2001 From: Siwat Sirichai Date: Thu, 7 Dec 2023 16:02:28 +0700 Subject: [PATCH] Update Jenkinsfile --- Jenkinsfile | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/Jenkinsfile b/Jenkinsfile index 9ef0dd4..dcf9353 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -2,22 +2,18 @@ pipeline { agent any stages { - stage('Clone') { - steps { - git branch: 'main', url: 'https://git.siwatsystem.com/ise-senior-iot/iot-firmware.git' - } - } stage('Build') { steps { + git branch: 'main', url: 'https://git.siwatsystem.com/ise-senior-iot/iot-firmware.git' sh 'export PLATFORMIO_PATH=/root/.platformio/penv/bin/platformio' sh '/usr/bin/python3 gen_release.py' + stash includes: 'release/**/*', name: 'release_binaries' } } stage('Publish') { steps { - sh 'mkdir -p artifacts' - sh 'cp -r release/ artifacts/' - archiveArtifacts artifacts: 'artifacts/**/*', fingerprint: true + unstash 'release_binaries' + archiveArtifacts artifacts: 'release/**/*', fingerprint: true } } }