You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@helix.apache.org by jx...@apache.org on 2022/12/15 05:33:32 UTC
[helix] branch master updated: Revert "Revert "Remove revision variable in pom.xml and update bump-up.sh (#2308)""
This is an automated email from the ASF dual-hosted git repository.
jxue pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/helix.git
The following commit(s) were added to refs/heads/master by this push:
new f20128cc5 Revert "Revert "Remove revision variable in pom.xml and update bump-up.sh (#2308)""
f20128cc5 is described below
commit f20128cc585788611d1fec81ddfe5183b3a55e7a
Author: Junkai Xue <jx...@apache.org>
AuthorDate: Wed Dec 14 21:17:40 2022 -0800
Revert "Revert "Remove revision variable in pom.xml and update bump-up.sh (#2308)""
This reverts commit 69dc7d32c264efcf09b830646b86bae6e35591ab.
---
bump-snapshot.sh | 4 ++--
bump-up.sh | 21 +++++++++++++--------
helix-admin-webapp/pom.xml | 1 -
helix-agent/pom.xml | 1 -
helix-common/pom.xml | 1 -
helix-core/pom.xml | 1 -
helix-front/pom.xml | 4 ----
helix-lock/pom.xml | 1 -
helix-view-aggregator/pom.xml | 1 -
metadata-store-directory-common/pom.xml | 1 -
metrics-common/pom.xml | 1 -
pom.xml | 2 +-
recipes/distributed-lock-manager/pom.xml | 1 -
recipes/pom.xml | 3 ---
recipes/rabbitmq-consumer-group/pom.xml | 1 -
recipes/rsync-replicated-file-system/pom.xml | 1 -
recipes/service-discovery/pom.xml | 1 -
recipes/task-execution/pom.xml | 3 ---
website/0.9.9/pom.xml | 6 +-----
website/1.0.2/pom.xml | 6 +-----
website/1.0.4/pom.xml | 6 +-----
website/pom.xml | 4 ++--
zookeeper-api/pom.xml | 1 -
23 files changed, 21 insertions(+), 51 deletions(-)
diff --git a/bump-snapshot.sh b/bump-snapshot.sh
index a9869f2e3..d18e84e3e 100755
--- a/bump-snapshot.sh
+++ b/bump-snapshot.sh
@@ -21,7 +21,7 @@
echo There are $# arguments to $0: $*
-version=`grep "<revision>" pom.xml | awk 'BEGIN {FS="[<,>]"};{print $3}'`
+version=`grep -A 1 "<artifactId>helix</artifactId>" pom.xml |tail -1 | awk 'BEGIN {FS="[<,>]"};{print $3}'`
if [ "$#" -eq 1 ]; then
new_version=$1
elif [ "$#" -eq 2 ]; then
@@ -47,7 +47,7 @@ mv helix-view-aggregator/helix-view-aggregator-$version-SNAPSHOT.ivy helix-view-
find . -type f -name '*.ivy' -exec sed -i "s/$version/$new_version/g" {} \;
-find . -type f -name 'pom.xml' -exec sed -i "s/<revision>$version/<revision>$new_version/g" pom.xml;
+find . -type f -name 'pom.xml' -exec sed -i "s/$version/$new_version/g" {} \;
diff --git a/bump-up.sh b/bump-up.sh
index 76f8635d7..9b23aec11 100755
--- a/bump-up.sh
+++ b/bump-up.sh
@@ -21,9 +21,9 @@
update_pom_version() {
pom=$1
+ version=$2
echo "bump up $pom"
- version=`get_version_from_pom $pom`
- sed -i'' -e "s/<revision>$version/<revision>$new_version/g" $pom
+ sed -i'' -e "s/${version}/${new_version}/g" "$pom"
if ! grep -C 1 "$new_version" $pom; then
echo "Failed to update new version $new_version in $pom"
exit 1
@@ -37,7 +37,8 @@ update_ivy() {
if [ -f $ivy_file ]; then
echo "bump up $ivy_file"
git mv "$ivy_file" "$new_ivy_file"
- sed -i'' -e "s/${current_version}/${new_version}/g" "$new_ivy_file"
+ current_ivy_version=`get_version_from_ivy $new_ivy_file`
+ sed -i'' -e "s/${current_ivy_version}/${new_version}/g" "$new_ivy_file"
if ! grep -C 1 "$new_version" "$new_ivy_file"; then
echo "Failed to update new version $new_version in $new_ivy_file"
exit 1
@@ -48,7 +49,11 @@ update_ivy() {
}
get_version_from_pom() {
- grep "<revision>" $1 | awk 'BEGIN {FS="[<,>]"};{print $3}'
+ grep -A 1 "<artifactId>helix</artifactId>" $1 |tail -1 | awk 'BEGIN {FS="[<,>]"};{print $3}'
+}
+
+get_version_from_ivy() {
+ grep revision "$1" | awk 'BEGIN {FS="[=,\"]"};{print $3}'
}
current_version=`get_version_from_pom pom.xml`
@@ -66,18 +71,18 @@ else
new_version="$major_version.$submajor_version.$new_minor_version"
fi
echo "bump up: $current_version -> $new_version"
-update_pom_version "pom.xml"
+update_pom_version "pom.xml" $current_version
for module in "metrics-common" "metadata-store-directory-common" "zookeeper-api" "helix-common" "helix-core" \
"helix-admin-webapp" "helix-rest" "helix-lock" "helix-view-aggregator" "helix-agent"; do
update_ivy $module
- update_pom_version $module/pom.xml
+ update_pom_version $module/pom.xml $current_version
done
-for module in recipes/task-execution recipes \
+for module in recipes/task-execution recipes helix-front \
recipes/distributed-lock-manager recipes/rsync-replicated-file-system \
recipes/rabbitmq-consumer-group recipes/service-discovery; do
- update_pom_version $module/pom.xml
+ update_pom_version $module/pom.xml $current_version
done
#END
diff --git a/helix-admin-webapp/pom.xml b/helix-admin-webapp/pom.xml
index ce542291b..f46e9c868 100644
--- a/helix-admin-webapp/pom.xml
+++ b/helix-admin-webapp/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
com.fasterxml.jackson*,
diff --git a/helix-agent/pom.xml b/helix-agent/pom.xml
index ab7189ec5..98779f175 100644
--- a/helix-agent/pom.xml
+++ b/helix-agent/pom.xml
@@ -42,7 +42,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.apache.commons.cli;version="[1.2,2)",
diff --git a/helix-common/pom.xml b/helix-common/pom.xml
index 9d7995b07..9d2598bc4 100644
--- a/helix-common/pom.xml
+++ b/helix-common/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.slf4j*;version="[1.7,2)",
org.apache.logging.log4j*;version="[2.17,3)",
diff --git a/helix-core/pom.xml b/helix-core/pom.xml
index 4248332f0..0c2f72e08 100755
--- a/helix-core/pom.xml
+++ b/helix-core/pom.xml
@@ -44,7 +44,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
javax.management*,
javax.xml.bind*,
diff --git a/helix-front/pom.xml b/helix-front/pom.xml
index 2cbdc9f7b..6ab7a47ba 100644
--- a/helix-front/pom.xml
+++ b/helix-front/pom.xml
@@ -42,10 +42,6 @@
<url>http://www.apache.org</url>
</organization>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
-
<dependencies>
</dependencies>
diff --git a/helix-lock/pom.xml b/helix-lock/pom.xml
index 63b398e3a..2e3ad1e63 100644
--- a/helix-lock/pom.xml
+++ b/helix-lock/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.slf4j*;version="[1.7,2)",
diff --git a/helix-view-aggregator/pom.xml b/helix-view-aggregator/pom.xml
index c86f46764..43cf4c4fb 100644
--- a/helix-view-aggregator/pom.xml
+++ b/helix-view-aggregator/pom.xml
@@ -43,7 +43,6 @@ under the License.
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.apache.commons.cli*,
diff --git a/metadata-store-directory-common/pom.xml b/metadata-store-directory-common/pom.xml
index 456613277..046573e22 100644
--- a/metadata-store-directory-common/pom.xml
+++ b/metadata-store-directory-common/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.slf4j*;version="[1.7,2)",
org.apache.logging.log4j*;version="[2.17,3)",
diff --git a/metrics-common/pom.xml b/metrics-common/pom.xml
index 1e8bf54dc..59d6546a2 100644
--- a/metrics-common/pom.xml
+++ b/metrics-common/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.slf4j*;version="[1.7,2)",
org.apache.logging.log4j*;version="[2.17,3)",
diff --git a/pom.xml b/pom.xml
index b2fe9c3f7..abffa1d73 100644
--- a/pom.xml
+++ b/pom.xml
@@ -401,7 +401,7 @@
</ciManagement>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
+ <revision>1.1.1-SNAPSHOT</revision>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<project.build.outputTimestamp>1671078135</project.build.outputTimestamp>
diff --git a/recipes/distributed-lock-manager/pom.xml b/recipes/distributed-lock-manager/pom.xml
index 1082cde24..5e2331c49 100644
--- a/recipes/distributed-lock-manager/pom.xml
+++ b/recipes/distributed-lock-manager/pom.xml
@@ -44,7 +44,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.slf4j*;version="[1.7,2)",
diff --git a/recipes/pom.xml b/recipes/pom.xml
index de3a396b8..ab08dff45 100644
--- a/recipes/pom.xml
+++ b/recipes/pom.xml
@@ -42,9 +42,6 @@
<url>http://www.apache.org</url>
</organization>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
<modules>
<module>rabbitmq-consumer-group</module>
<module>rsync-replicated-file-system</module>
diff --git a/recipes/rabbitmq-consumer-group/pom.xml b/recipes/rabbitmq-consumer-group/pom.xml
index bf4234d15..a9b1a942b 100644
--- a/recipes/rabbitmq-consumer-group/pom.xml
+++ b/recipes/rabbitmq-consumer-group/pom.xml
@@ -45,7 +45,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.slf4j*;version="[1.7,2)",
diff --git a/recipes/rsync-replicated-file-system/pom.xml b/recipes/rsync-replicated-file-system/pom.xml
index 9cdb8d0ce..d43b45307 100644
--- a/recipes/rsync-replicated-file-system/pom.xml
+++ b/recipes/rsync-replicated-file-system/pom.xml
@@ -44,7 +44,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.slf4j*;version="[1.7,2)",
diff --git a/recipes/service-discovery/pom.xml b/recipes/service-discovery/pom.xml
index 57bfdfc6e..fdf79bd5a 100644
--- a/recipes/service-discovery/pom.xml
+++ b/recipes/service-discovery/pom.xml
@@ -44,7 +44,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.apache.helix*,
org.slf4j*;version="[1.7,2)",
diff --git a/recipes/task-execution/pom.xml b/recipes/task-execution/pom.xml
index 556fc9a24..bf2dc2749 100644
--- a/recipes/task-execution/pom.xml
+++ b/recipes/task-execution/pom.xml
@@ -43,9 +43,6 @@
<url>http://www.apache.org</url>
</organization>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
<dependencies>
<dependency>
<groupId>org.slf4j</groupId>
diff --git a/website/0.9.9/pom.xml b/website/0.9.9/pom.xml
index e179c5fdd..70cfdc127 100644
--- a/website/0.9.9/pom.xml
+++ b/website/0.9.9/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.apache.helix</groupId>
<artifactId>website</artifactId>
- <version>${revision}</version>
+ <version>1.1.1-SNAPSHOT</version>
</parent>
<artifactId>0.9.9-docs</artifactId>
@@ -43,10 +43,6 @@
<url>http://www.apache.org</url>
</organization>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
-
<dependencies>
<dependency>
<groupId>org.testng</groupId>
diff --git a/website/1.0.2/pom.xml b/website/1.0.2/pom.xml
index 7cb9078a9..27b601e4a 100644
--- a/website/1.0.2/pom.xml
+++ b/website/1.0.2/pom.xml
@@ -23,17 +23,13 @@
<parent>
<groupId>org.apache.helix</groupId>
<artifactId>website</artifactId>
- <version>${revision}</version>
+ <version>1.1.1-SNAPSHOT</version>
</parent>
<artifactId>1.0.2-docs</artifactId>
<packaging>bundle</packaging>
<name>Apache Helix :: Website :: 1.0.2</name>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
-
<licenses>
<license>
<name>Apache License, Version 2.0</name>
diff --git a/website/1.0.4/pom.xml b/website/1.0.4/pom.xml
index 73ba93e39..d9b77b5ce 100644
--- a/website/1.0.4/pom.xml
+++ b/website/1.0.4/pom.xml
@@ -23,7 +23,7 @@
<parent>
<groupId>org.apache.helix</groupId>
<artifactId>website</artifactId>
- <version>${revision}</version>
+ <version>1.1.1-SNAPSHOT</version>
</parent>
<artifactId>1.0.4-docs</artifactId>
@@ -43,10 +43,6 @@
<url>http://www.apache.org</url>
</organization>
- <properties>
- <revision>1.0.5-SNAPSHOT</revision>
- </properties>
-
<dependencies>
<dependency>
<groupId>org.testng</groupId>
diff --git a/website/pom.xml b/website/pom.xml
index a518a80f6..4474b5d02 100644
--- a/website/pom.xml
+++ b/website/pom.xml
@@ -21,7 +21,7 @@
<parent>
<groupId>org.apache.helix</groupId>
<artifactId>helix</artifactId>
- <version>${revision}</version>
+ <version>1.1.1-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<packaging>pom</packaging>
@@ -51,7 +51,7 @@
</modules>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
+ <revision>1.1.1-SNAPSHOT</revision>
<!-- for svnpubsub site deployment -->
<!-- you can use javasvn too -->
<svnImpl>svn</svnImpl>
diff --git a/zookeeper-api/pom.xml b/zookeeper-api/pom.xml
index 9e2070770..a393a9aac 100644
--- a/zookeeper-api/pom.xml
+++ b/zookeeper-api/pom.xml
@@ -43,7 +43,6 @@
</organization>
<properties>
- <revision>1.0.5-SNAPSHOT</revision>
<osgi.import>
org.slf4j*;version="[1.7,2)",
org.apache.zookeeper*;version="[3.6,3.7)",