diff --git a/CHANGELOG b/CHANGELOG index 0f7e0ad..b5e231b 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,6 +1,11 @@ CHANGELOG ========= +0.5.1 +----- + +* Fix accidental merge with SNAPSHOT version in to master + 0.5.0 ----- @@ -9,7 +14,6 @@ CHANGELOG * Add `BeanBuilder` experiment * Upgrade `lombok` to 1.16.20 * Upgrade assertj to 3.9.1 -* jenkins: test on both java 8 and 9 0.4.0 ----- diff --git a/Jenkinsfile.groovy b/Jenkinsfile.groovy index 7bb06b5..0ef8595 100644 --- a/Jenkinsfile.groovy +++ b/Jenkinsfile.groovy @@ -9,12 +9,24 @@ pipeline { git url: gitRepoUrl, branch: '**', credentialsId: 'github-kemitix' } } + stage('no SNAPSHOT in master') { + // checks that the pom version is not a snapshot when the current branch is master + // TODO: also check for SNAPSHOT when is a pull request with master as the target branch + when { + expression { + (env.GIT_BRANCH == 'master') && + (readMavenPom(file: 'pom.xml').version).contains("SNAPSHOT") } + } + steps { + error("Build failed because SNAPSHOT version") + } + } stage('Build') { parallel { stage('Java 8') { steps { withMaven(maven: 'maven 3.5.2', jdk: 'JDK 1.8') { - sh 'mvn clean install' + sh "${mvn} clean install" } } } diff --git a/pom.xml b/pom.xml index e1b3a89..2c2e95f 100644 --- a/pom.xml +++ b/pom.xml @@ -12,7 +12,7 @@ net.kemitix mon - 0.5.0-SNAPSHOT + 0.6.0-SNAPSHOT 1.8