Merge branch 'sb/bisect-run-empty'
authorJunio C Hamano <gitster@pobox.com>
Wed, 15 Nov 2017 03:14:36 +0000 (12:14 +0900)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 Nov 2017 03:14:36 +0000 (12:14 +0900)
"git bisect run" that did not specify any command to run used to go
ahead and treated all commits to be tested as 'good'. This has
been corrected by making the command error out.

* sb/bisect-run-empty:
bisect run: die if no command is given

1  2 
git-bisect.sh
diff --combined git-bisect.sh
index a82256e345dcdfdade6f6196531d2c745cb52a29,a69e436563ae3be2bf0c5285148e36cb8f89e368..54cbfecc5ab0531513ff9e069be55d74339ad427
@@@ -1,6 -1,6 +1,6 @@@
  #!/bin/sh
  
 -USAGE='[help|start|bad|good|new|old|terms|skip|next|reset|visualize|replay|log|run]'
 +USAGE='[help|start|bad|good|new|old|terms|skip|next|reset|visualize|view|replay|log|run]'
  LONG_USAGE='git bisect help
        print this long help message.
  git bisect start [--term-{old,good}=<term> --term-{new,bad}=<term>]
@@@ -20,7 -20,7 +20,7 @@@ git bisect nex
        find next bisection to test and check it out.
  git bisect reset [<commit>]
        finish bisection search and go back to commit.
 -git bisect visualize
 +git bisect (visualize|view)
        show bisect status in gitk.
  git bisect replay <logfile>
        replay bisection log.
@@@ -450,6 -450,8 +450,8 @@@ bisect_replay () 
  bisect_run () {
        bisect_next_check fail
  
+       test -n "$*" || die "$(gettext "bisect run failed: no command provided.")"
        while true
        do
                command="$@"