Skip to content

Commit cfa1a79

Browse files
committed
User may want to skip tidy check sometimes
1 parent 97279e9 commit cfa1a79

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/etc/pre-push.sh

+5-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
# and remove it from .git/hooks to deactivate.
66
#
77

8-
set -Eeuo pipefail
8+
set -Euo pipefail
99

1010
# https://github.com/rust-lang/rust/issues/77620#issuecomment-705144570
1111
unset GIT_DIR
@@ -15,3 +15,7 @@ echo "Running pre-push script $ROOT_DIR/x test tidy"
1515

1616
cd "$ROOT_DIR"
1717
./x test tidy --set build.locked-deps=true
18+
if [ $? -ne 0 ]; then
19+
echo "You may use \`git push --no-verify\` to skip this check."
20+
exit 1
21+
fi

0 commit comments

Comments
 (0)