doc/git-bisect: clarify `git bisect run` syntax
The description of the `git bisect run` command syntax at the beginning of the manpage is `git bisect run <cmd>...`, which isn't quite clear about what `<cmd>` is or what the `...` mean; one could think that it is the whole (quoted) command line with all arguments in a single string, or that it supports multiple commands, or that it doesn't accept commands with arguments at all. Change to `git bisect run <cmd> [<arg>...]` to clarify the syntax, in both the manpage and the `git bisect -h` command output. Additionally, change `--term-{new,bad}` et al to `--term-(new|bad)` for consistency with the synopsis syntax conventions. Signed-off-by: Javier Mora <cousteaulecommandant@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Javier Mora committed
Oct 23, 2023 at 19:23 UTC
3f02785de9f6db28fec17e7100f70665e725b7c5
2 files changed
+4
-4
Documentation/git-bisect.txt
+2
-2
@@ -16,7 +16,7 @@ DESCRIPTION
16
The command takes various subcommands, and different options depending
17
on the subcommand:
18
19
- git bisect start [--term-{new,bad}=<term> --term-{old,good}=<term>]
19
+ git bisect start [--term-(new|bad)=<term-new> --term-(old|good)=<term-old>]
20
[--no-checkout] [--first-parent] [<bad> [<good>...]] [--] [<paths>...]
21
git bisect (bad|new|<term-new>) [<rev>]
22
git bisect (good|old|<term-old>) [<rev>...]
@@ -26,7 +26,7 @@ on the subcommand:
26
git bisect (visualize|view)
27
git bisect replay <logfile>
28
git bisect log
29
- git bisect run <cmd>...
29
+ git bisect run <cmd> [<arg>...]
30
git bisect help
31
32
This command uses a binary search algorithm to find which commit in
builtin/bisect.c
+2
-2
@@ -26,7 +26,7 @@ static GIT_PATH_FUNC(git_path_bisect_first_parent, "BISECT_FIRST_PARENT")
26
static GIT_PATH_FUNC(git_path_bisect_run, "BISECT_RUN")
27
28
#define BUILTIN_GIT_BISECT_START_USAGE \
29
- N_("git bisect start [--term-{new,bad}=<term> --term-{old,good}=<term>]" \
29
+ N_("git bisect start [--term-(new|bad)=<term> --term-(old|good)=<term>]" \
30
" [--no-checkout] [--first-parent] [<bad> [<good>...]] [--]" \
31
" [<pathspec>...]")
32
#define BUILTIN_GIT_BISECT_STATE_USAGE \
@@ -46,7 +46,7 @@ static GIT_PATH_FUNC(git_path_bisect_run, "BISECT_RUN")
46
#define BUILTIN_GIT_BISECT_LOG_USAGE \
47
"git bisect log"
48
#define BUILTIN_GIT_BISECT_RUN_USAGE \
49
- N_("git bisect run <cmd>...")
49
+ N_("git bisect run <cmd> [<arg>...]")
50
51
static const char * const git_bisect_usage[] = {
52
BUILTIN_GIT_BISECT_START_USAGE,