Skip to content

Commit 0a09b49

Browse files
authored
Arm backend: Make pre-push non-interactive on one argument (#11280)
Calling pre-push as a git hook actually supplies it with 2 arguments, remote-name and remote-url. So the logic of automatically going non-interactive when there are any arguments is flawed. This commit makes sure pre-push only goes non-interactive when there is only one argument. Signed-off-by: [email protected]
1 parent ef7a6ea commit 0a09b49

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

backends/arm/scripts/pre-push

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
# This source code is licensed under the BSD-style license found in the
55
# LICENSE file in the root directory of this source tree.
66

7-
# Calling this script with any argument is equal to launching it in
7+
# Calling this script with one argument is equal to launching it in
88
# non-interactive mode. "$#" gives the number of positional arguments.
9-
[ "$#" -eq 0 ] && is_script_interactive=1 || is_script_interactive=0
9+
[ "$#" -eq 1 ] && is_script_interactive=1 || is_script_interactive=0
1010

1111
if [ $is_script_interactive -eq 1 ]; then
1212
RESET='\e[0m'

0 commit comments

Comments
 (0)