properties([ buildDiscarder( logRotator( artifactDaysToKeepStr: '', artifactNumToKeepStr: '', daysToKeepStr: '', numToKeepStr: '3' ) ) ]) pipeline { options { timestamps () } agent { label 'vs2022 && windows' } stages { stage('Clean') { steps { dir ('build/vs2022/Release') { deleteDir() } dir ('dist') { deleteDir() } } } stage('Prepare') { steps { dir('third-party/sqlite3/') { sh 'sh -ex fetch_sqlite3.sh' } } } stage('Build') { steps { bat ''' cmake --preset vs -DCMAKE_BUILD_TYPE=Release cmake --build --preset vs-release --config Release copy /y README.MD .\\build\\vs2022\\Release\\ copy /y LICENSE .\\build\\vs2022\\Release\\ ''' } } stage('Archive') { steps { bat ''' 7za a -tzip -mtm- dist/kgg-dec.zip .\\build\\vs2022\\Release\\* ''' } post { success { archiveArtifacts 'dist/*.zip' } } } } }