From 1c0c933d8252d59db145d02a7827631f564d341b Mon Sep 17 00:00:00 2001 From: pgodithi Date: Tue, 12 Jul 2022 18:40:29 -0400 Subject: [PATCH 1/4] Version increment automation: task rename updateVersion Signed-off-by: pgodithi --- build.gradle | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/build.gradle b/build.gradle index 37e32e84..1bac53c9 100644 --- a/build.gradle +++ b/build.gradle @@ -190,3 +190,22 @@ run { } apply from: 'build-tools/pkgbuild.gradle' + +// updateVersion: Task to auto increment to the next development iteration +task updateVersion { + onlyIf { System.getProperty('newVersion') } + doLast { + ext.newVersion = System.getProperty('newVersion') + println "Setting version to ${newVersion}." + // String tokenization to support -SNAPSHOT + ant.replaceregexp(match: opensearch_version.tokenize('-')[0], replace: newVersion.tokenize('-')[0], flags:'g', byline:true) { + fileset(dir: projectDir) { + // Include the required files that needs to be updated with new Version + include(name: ".github/workflows/build.yml") + include(name: ".github/workflows/multi-node-test-workflow.yml") + + } + } + ant.replaceregexp(file:'build.gradle', match: '"opensearch.version", "\\d.*"', replace: '"opensearch.version", "' + newVersion.tokenize('-')[0] + '-SNAPSHOT"', flags:'g', byline:true) + } +} \ No newline at end of file From 9141b1c1f223d67709ef92531ed4d9deb16000a1 Mon Sep 17 00:00:00 2001 From: prudhvigodithi Date: Wed, 27 Jul 2022 10:01:29 -0400 Subject: [PATCH 2/4] Staging version increment Signed-off-by: prudhvigodithi --- build.gradle | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 1bac53c9..c51e32a5 100644 --- a/build.gradle +++ b/build.gradle @@ -208,4 +208,22 @@ task updateVersion { } ant.replaceregexp(file:'build.gradle', match: '"opensearch.version", "\\d.*"', replace: '"opensearch.version", "' + newVersion.tokenize('-')[0] + '-SNAPSHOT"', flags:'g', byline:true) } -} \ No newline at end of file +} + +// updateVersion: Task to auto increment to the next development iteration +task updateVersion { + onlyIf { System.getProperty('newVersion') } + doLast { + ext.newVersion = System.getProperty('newVersion') + println "Setting version to ${newVersion}." + // String tokenization to support -SNAPSHOT + ant.replaceregexp(match: opensearch_version.tokenize('-')[0], replace: newVersion.tokenize('-')[0], flags:'g', byline:true) { + fileset(dir: projectDir) { + // Include the required files that needs to be updated with new Version + include(name: ".github/workflows/build.yml") + include(name: ".github/workflows/multi-node-test-workflow.yml") + } + } + ant.replaceregexp(file:'build.gradle', match: '"opensearch.version", "\\d.*"', replace: '"opensearch.version", "' + newVersion.tokenize('-')[0] + '-SNAPSHOT"', flags:'g', byline:true) + } +} From c6fd70859b20919839df935eec0d66bf66dc17ad Mon Sep 17 00:00:00 2001 From: prudhvigodithi Date: Wed, 27 Jul 2022 10:03:32 -0400 Subject: [PATCH 3/4] Staging version increment Signed-off-by: prudhvigodithi --- build.gradle | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/build.gradle b/build.gradle index c51e32a5..c036d7f3 100644 --- a/build.gradle +++ b/build.gradle @@ -210,20 +210,3 @@ task updateVersion { } } -// updateVersion: Task to auto increment to the next development iteration -task updateVersion { - onlyIf { System.getProperty('newVersion') } - doLast { - ext.newVersion = System.getProperty('newVersion') - println "Setting version to ${newVersion}." - // String tokenization to support -SNAPSHOT - ant.replaceregexp(match: opensearch_version.tokenize('-')[0], replace: newVersion.tokenize('-')[0], flags:'g', byline:true) { - fileset(dir: projectDir) { - // Include the required files that needs to be updated with new Version - include(name: ".github/workflows/build.yml") - include(name: ".github/workflows/multi-node-test-workflow.yml") - } - } - ant.replaceregexp(file:'build.gradle', match: '"opensearch.version", "\\d.*"', replace: '"opensearch.version", "' + newVersion.tokenize('-')[0] + '-SNAPSHOT"', flags:'g', byline:true) - } -} From 0264ac997576e9e884afdd59a0f0812b7f259a06 Mon Sep 17 00:00:00 2001 From: prudhvigodithi Date: Tue, 9 Aug 2022 08:25:40 -0400 Subject: [PATCH 4/4] Updated junit Signed-off-by: prudhvigodithi --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index c036d7f3..151a36f6 100644 --- a/build.gradle +++ b/build.gradle @@ -81,7 +81,7 @@ allprojects { } dependencies { - testCompile ('junit:junit:4.12') { + testCompile ('junit:junit:4.13.2') { exclude group: 'org.hamcrest' } testCompile "org.opensearch.plugin:reindex-client:${opensearch_version}"