diff --git a/Jenkinsfile b/Jenkinsfile index a3f975d..473a5f1 100644 --- a/Jenkinsfile +++ b/Jenkinsfile @@ -5,7 +5,7 @@ pipeline { steps { sh './gradlew :1.10.2:setupCiWorkspace' sh './gradlew :1.10.2:clean' - sh './gradlew :1.10.2:build' + sh './gradlew :1.10.2:build -Pbuild_number=${BUILD_NUMBER}' archive '1.10.2/build/libs/*jar' } } @@ -13,7 +13,7 @@ pipeline { steps { sh './gradlew :1.11.2:setupCiWorkspace' sh './gradlew :1.11.2:clean' - sh './gradlew :1.11.2:build' + sh './gradlew :1.11.2:build -Pbuild_number=${BUILD_NUMBER}' archive '1.11.2/build/libs/*jar' } } @@ -21,7 +21,7 @@ pipeline { steps { sh './gradlew :1.12.2:setupCiWorkspace' sh './gradlew :1.12.2:clean' - sh './gradlew :1.12.2:build' + sh './gradlew :1.12.2:build -Pbuild_number=${BUILD_NUMBER}' archive '1.12.2/build/libs/*jar' } } diff --git a/build.gradle b/build.gradle index 9212dad..ccec186 100644 --- a/build.gradle +++ b/build.gradle @@ -8,6 +8,12 @@ subprojects { apply plugin: "kotlin" apply plugin: "idea" + if (project.hasProperty('build_number')) { + mod_version += "-build-$build_number" + } else if(!project.hasProperty('release')) { + mod_version += "-dev" + } + idea { module { excludeDirs += [file("run")]