From b581e4596998a9fafdb8010d3ce24f3078657b34 Mon Sep 17 00:00:00 2001 From: Guillaume Chatelet Date: Tue, 6 May 2025 09:42:28 +0000 Subject: [PATCH] Fix scripts/make_release.sh - Make sure to commit `MODULE.bazel` - Fail before tagging if the repo has unstaged or uncommited changes. --- scripts/make_release.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/scripts/make_release.sh b/scripts/make_release.sh index 0eadc9a..2e11a44 100755 --- a/scripts/make_release.sh +++ b/scripts/make_release.sh @@ -66,9 +66,12 @@ echo -e "${ACTION}Modifying MODULE.bazel${NOCOLOR}" sed -i "s/CPU_FEATURES_VERSION = \"${LATEST_VERSION}\"/CPU_FEATURES_VERSION = \"${VERSION}\"/g" MODULE.bazel echo -e "${ACTION}Commit new revision${NOCOLOR}" -git add CMakeLists.txt +git add CMakeLists.txt MODULE.bazel git commit -m"Release ${GIT_TAG}" +echo -e "${ACTION}Check for unstaged or uncommited changes${NOCOLOR}" +git diff --quiet && git diff --quiet --cached + echo -e "${ACTION}Create new tag${NOCOLOR}" git tag ${GIT_TAG}