From 7a26679de1637f37d8e1f7266219d3b66f4d959f Mon Sep 17 00:00:00 2001 From: Peter Nied Date: Fri, 23 Sep 2022 17:34:48 +0000 Subject: [PATCH] Manually incorperate changes from #1741 Incorperating changes from https://github.com/opensearch-project/security/pull/1741 Specifically build.gradle changes, see https://github.com/opensearch-project/security/commit/274408130b315de313ea04afae4ddff70ba34352#diff-49a96e7eea8a94af862798a45174e6ac43eb4f8b4bd40759b5da63ba31ec3ef7 Signed-off-by: Peter Nied --- build.gradle | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/build.gradle b/build.gradle index 2659e74be4..e2bce7dffa 100644 --- a/build.gradle +++ b/build.gradle @@ -56,7 +56,18 @@ repositories { } ext { + isSnapshot = "true" == System.getProperty("build.snapshot", "true") opensearch_version = System.getProperty("opensearch.version", "1.3.4-SNAPSHOT") + buildVersionQualifier = System.getProperty("build.version_qualifier", "") + version_tokens = opensearch_version.tokenize('-') + opensearch_build = version_tokens[0] + '.0' + if (buildVersionQualifier) { + opensearch_build += "-${buildVersionQualifier}" + opensearch_build_nosnapshot = opensearch_build + } + if (isSnapshot) { + opensearch_build += "-SNAPSHOT" + } } configurations.all { @@ -123,13 +134,8 @@ dependencies { compileOnly "org.opensearch:opensearch:${opensearch_version}" } -ext { - securityPluginVersion = '1.3.4.0' - isSnapshot = "true" == System.getProperty("build.snapshot", "true") -} - group = 'org.opensearch' -version = "${securityPluginVersion}" + (isSnapshot ? "-SNAPSHOT" : "") +version = opensearch_build description = 'OpenSearch Security'