From 28b11abcadd3e5f11578a8c757e68578768cc92b Mon Sep 17 00:00:00 2001 From: Greg Schueler Date: Thu, 13 Aug 2020 16:19:51 -0700 Subject: [PATCH] Add axion release gradle plugin to set version --- RELEASING.md | 21 +++++++++++++++++++++ build.gradle | 12 ++++++++++-- 2 files changed, 31 insertions(+), 2 deletions(-) create mode 100644 RELEASING.md diff --git a/RELEASING.md b/RELEASING.md new file mode 100644 index 0000000..6928016 --- /dev/null +++ b/RELEASING.md @@ -0,0 +1,21 @@ +# Release + +Uses [axion release](https://axion-release-plugin.readthedocs.io/en/latest/) plugin. + + ./gradlew release + +If you need to release with a SNAPSHOT dependency: + + ./gradlew release -Prelease.disableChecks + +Otherwise, axion-release will fail the prerelease check. Only do this for testing. + +## Next minor version + + ./gradlew markNextVersion -Prelease.incrementer=incrementMinor + +Updates minor version without releasing, e.g. 0.1.x-SNAPSHOT becomes 0.2.0-SNAPSHOT + +## Force version + + ./gradlew release -Prelease.forceVersion=3.0.0 diff --git a/build.gradle b/build.gradle index 30f6671..d796406 100644 --- a/build.gradle +++ b/build.gradle @@ -13,8 +13,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - -version '1.0.2' +plugins{ + id 'pl.allegro.tech.build.axion-release' version '1.9.3' +} ext.rundeckPluginVersion = '1.2' @@ -34,6 +35,13 @@ repositories { mavenLocal() } +scmVersion { + tag { + prefix = 'v' + versionSeparator = '' + } +} +version scmVersion.version configurations { pluginLibs