From a0be6ad81f47903583c1e8decb11b07403398762 Mon Sep 17 00:00:00 2001 From: Ben Hale Date: Wed, 9 May 2018 12:19:35 -0700 Subject: [PATCH] Extract Project Version Previously the project version in the build was explicitly specified within the build script itself. This way of specifying the project version makes the value non-overrideable from the command line. This change moves that value to the gradle.properties file where it becomes a "normal" property, overridable using the standard -P syntax. --- build.gradle | 4 ---- gradle.properties | 14 ++++++++++++++ 2 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 gradle.properties diff --git a/build.gradle b/build.gradle index b090b6a3d..f4d107593 100644 --- a/build.gradle +++ b/build.gradle @@ -26,10 +26,6 @@ plugins { id 'io.morethan.jmhreport' version '0.7.0' apply false } -allprojects { - version = hasProperty('version') ? property('version') : '0.11.0.BUILD-SNAPSHOT' -} - subprojects { apply plugin: 'io.spring.dependency-management' diff --git a/gradle.properties b/gradle.properties new file mode 100644 index 000000000..34dbb3a6c --- /dev/null +++ b/gradle.properties @@ -0,0 +1,14 @@ +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +version=0.11.0.BUILD-SNAPSHOT