This is an automated email from the ASF dual-hosted git repository.

philo pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-gluten.git


The following commit(s) were added to refs/heads/main by this push:
     new f70c74c6ae [VL] Fix script for packaging releases (#10853)
f70c74c6ae is described below

commit f70c74c6ae87e2bb7a26b0b9f4f408b8e75730c3
Author: PHILO-HE <[email protected]>
AuthorDate: Thu Oct 9 22:01:25 2025 +0800

    [VL] Fix script for packaging releases (#10853)
---
 dev/release/package-release.sh | 24 +++++++++++++-----------
 1 file changed, 13 insertions(+), 11 deletions(-)

diff --git a/dev/release/package-release.sh b/dev/release/package-release.sh
index bb0de30259..ec18101ae2 100755
--- a/dev/release/package-release.sh
+++ b/dev/release/package-release.sh
@@ -16,18 +16,20 @@
 # limitations under the License.
 
 # Note: Manually create $GLUTEN_HOME/release/ and place the release JARs 
inside.
-#       Also set TAG manually (e.g., v1.5.0).
+#       Provide the release tag (e.g., v1.5.0-rc0) as an argument to this 
script.
 
 set -eu
 
-TAG=""
-
-if [[ -z "$TAG" ]]; then
-  echo "TAG is not set. Please set TAG=vX.Y.Z before running."
+usage() {
+  echo "Usage: $0 <release_tag>  e.g., v1.5.0-rc0"
   exit 1
-fi
+}
+
+TAG="${1:-}"; [[ -n "$TAG" ]] || usage
+
+TAG_VERSION=${TAG#v}
 
-VERSION=${TAG#v}
+RELEASE_VERSION=${TAG_VERSION%-rc*}
 
 CURRENT_DIR=$(cd "$(dirname "$BASH_SOURCE")"; pwd)
 GLUTEN_HOME=${CURRENT_DIR}/../../
@@ -39,24 +41,24 @@ pushd $GLUTEN_HOME/release/
 SPARK_VERSIONS="3.2 3.3 3.4 3.5"
 
 for v in $SPARK_VERSIONS; do
-  JAR="gluten-velox-bundle-spark${v}_2.12-linux_amd64-${VERSION}.jar"
+  JAR="gluten-velox-bundle-spark${v}_2.12-linux_amd64-${RELEASE_VERSION}.jar"
   if [[ ! -f "$JAR" ]]; then
     echo "Missing Gluten release JAR under $GLUTEN_HOME/release/ for Spark $v: 
$JAR"
     exit 1
   fi
   echo "Packaging for Spark $v..."
-  tar -czf apache-gluten-$VERSION-incubating-bin-spark-${v}.tar.gz \
+  tar -czf apache-gluten-${RELEASE_VERSION}-incubating-bin-spark-${v}.tar.gz \
       ${GLUTEN_HOME}/DISCLAIMER \
       $JAR
 done
 
 SRC_ZIP="${TAG}.zip"
-SRC_DIR="incubator-gluten-${VERSION}"
+SRC_DIR="incubator-gluten-${TAG_VERSION}"
 
 echo "Packaging source code..."
 wget https://github.com/apache/incubator-gluten/archive/refs/tags/${SRC_ZIP}
 unzip -q ${SRC_ZIP}
-tar -czf apache-gluten-$VERSION-incubating-src.tar.gz ${SRC_DIR}
+tar -czf apache-gluten-${RELEASE_VERSION}-incubating-src.tar.gz ${SRC_DIR}
 rm -r ${SRC_ZIP} ${SRC_DIR}
 
 popd


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to