You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by xi...@apache.org on 2023/03/10 03:04:57 UTC
[spark] branch master updated: [SPARK-42739][BUILD] Ensure release tag to be pushed to release branch
This is an automated email from the ASF dual-hosted git repository.
xinrong pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/spark.git
The following commit(s) were added to refs/heads/master by this push:
new 785188dd8b5 [SPARK-42739][BUILD] Ensure release tag to be pushed to release branch
785188dd8b5 is described below
commit 785188dd8b5e74510c29edbff5b9991d88855e43
Author: Xinrong Meng <xi...@apache.org>
AuthorDate: Fri Mar 10 11:04:34 2023 +0800
[SPARK-42739][BUILD] Ensure release tag to be pushed to release branch
### What changes were proposed in this pull request?
In the release script, add a check to ensure release tag to be pushed to release branch.
### Why are the changes needed?
To ensure the success of a RC cut. Otherwise, release conductors have to manually check that.
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
Manual test.
```
~/spark [_d_branch] $ git commit -am '_d_commmit'
...
~/spark [_d_branch] $ git tag '_d_tag'
~/spark [_d_branch] $ git push origin _d_tag
~/spark [_d_branch] $ git branch -r --contains tags/_d_tag | grep origin
~/spark [_d_branch] $ echo $?
1
~/spark [_d_branch] $ git push origin HEAD:_d_branch
...
~/spark [_d_branch] $ git branch -r --contains tags/_d_tag | grep origin
origin/_d_branch
~/spark [_d_branch] $ echo $?
0
```
Closes #40357 from xinrong-meng/chk_release.
Authored-by: Xinrong Meng <xi...@apache.org>
Signed-off-by: Xinrong Meng <xi...@apache.org>
---
dev/create-release/release-tag.sh | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/dev/create-release/release-tag.sh b/dev/create-release/release-tag.sh
index 255bda37ad8..fa701dd74b2 100755
--- a/dev/create-release/release-tag.sh
+++ b/dev/create-release/release-tag.sh
@@ -122,6 +122,12 @@ if ! is_dry_run; then
git push origin $RELEASE_TAG
if [[ $RELEASE_VERSION != *"preview"* ]]; then
git push origin HEAD:$GIT_BRANCH
+ if git branch -r --contains tags/$RELEASE_TAG | grep origin; then
+ echo "Pushed $RELEASE_TAG to $GIT_BRANCH."
+ else
+ echo "Failed to push $RELEASE_TAG to $GIT_BRANCH. Please start over."
+ exit 1
+ fi
else
echo "It's preview release. We only push $RELEASE_TAG to remote."
fi
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org