pipeline { agent { label 'agent1' } stages { stage('Hello') { steps { // Uruchomienie testów jednostkowych script { echo 'hello world ' } } } } post { success { // Archiwizacja artefaktów po udanym budowaniu archiveArtifacts artifacts: 'target/*.jar', allowEmptyArchive: true } failure { // Powiadomienie o nieudanym budowaniu echo 'Build failed!' } } }