about summary refs log tree commit diff
diff options
context:
space:
mode:
authorMatthias Krüger <matthias.krueger@famsik.de>2023-07-01 00:35:08 +0200
committerGitHub <noreply@github.com>2023-07-01 00:35:08 +0200
commit58a61eea89de061ed707b449fbcfc8b4150bac7e (patch)
tree5b2e39cc6f1ff0d92181ab269909536a0f091c9a
parent626e1ea63c31d50e4177ca87d4e30bff0109c190 (diff)
parentcfa1a79009503d7ba12f39522c4d622e4ea239c8 (diff)
downloadrust-58a61eea89de061ed707b449fbcfc8b4150bac7e.tar.gz
rust-58a61eea89de061ed707b449fbcfc8b4150bac7e.zip
Rollup merge of #113206 - chenyukang:yukang-trivial-fix-113135, r=Kobzol
User may want to skip tidy check sometimes

Fixes #113135
-rwxr-xr-xsrc/etc/pre-push.sh6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/etc/pre-push.sh b/src/etc/pre-push.sh
index 0807e0492c1..c9e1a2733fd 100755
--- a/src/etc/pre-push.sh
+++ b/src/etc/pre-push.sh
@@ -5,7 +5,7 @@
 # and remove it from .git/hooks to deactivate.
 #
 
-set -Eeuo pipefail
+set -Euo pipefail
 
 # https://github.com/rust-lang/rust/issues/77620#issuecomment-705144570
 unset GIT_DIR
@@ -15,3 +15,7 @@ echo "Running pre-push script $ROOT_DIR/x test tidy"
 
 cd "$ROOT_DIR"
 ./x test tidy --set build.locked-deps=true
+if [ $? -ne 0 ]; then
+    echo "You may use \`git push --no-verify\` to skip this check."
+    exit 1
+fi