mirror of
https://github.com/spring-projects/spring-petclinic.git
synced 2026-01-23 11:51:11 +00:00
30 lines
512 B
Groovy
30 lines
512 B
Groovy
pipeline {
|
|
agent any
|
|
|
|
environment {
|
|
GIT_COMMIT_SHORT = sh(script: "git rev-parse --short HEAD", returnStdout: true).trim()
|
|
DOCKER_HUB_USER = "m1kkY8"
|
|
}
|
|
|
|
stages {
|
|
stage('checkStyle') {
|
|
when { not {branch 'main' }}
|
|
steps {
|
|
sh './gradlew checkstyleMain'
|
|
}
|
|
}
|
|
|
|
stage('Test') {
|
|
when { not {branch 'main' }}
|
|
steps {
|
|
sh './gradlew test'
|
|
}
|
|
}
|
|
|
|
stage('Build') {
|
|
steps {
|
|
sh './gradlew build -x test'
|
|
}
|
|
}
|
|
}
|
|
}
|