]> git.ipfire.org Git - thirdparty/git.git/commit - t/t0040-parse-options.sh
parse-options: PARSE_OPT_KEEP_UNKNOWN only applies to --options
authorSZEDER Gábor <szeder.dev@gmail.com>
Fri, 19 Aug 2022 16:03:57 +0000 (18:03 +0200)
committerJunio C Hamano <gitster@pobox.com>
Fri, 19 Aug 2022 18:13:14 +0000 (11:13 -0700)
commit99d86d60e59e11cbc46766346e3e379164a6e4df
tree01d48b5ff8a6815654379ac8f3ddf939e6b8b9f9
parent80882bc5e7143a0c3823b5a398fd76c9138437ef
parse-options: PARSE_OPT_KEEP_UNKNOWN only applies to --options

The description of 'PARSE_OPT_KEEP_UNKNOWN' starts with "Keep unknown
arguments instead of erroring out".  This is a bit misleading, as this
flag only applies to unknown --options, while non-option arguments are
kept even without this flag.

Update the description to clarify this, and rename the flag to
PARSE_OPTIONS_KEEP_UNKNOWN_OPT to make this obvious just by looking at
the flag name.

Signed-off-by: SZEDER Gábor <szeder.dev@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
17 files changed:
Documentation/technical/api-parse-options.txt
builtin/archive.c
builtin/bisect--helper.c
builtin/difftool.c
builtin/env--helper.c
builtin/fast-export.c
builtin/log.c
builtin/reflog.c
builtin/revert.c
builtin/sparse-checkout.c
builtin/stash.c
diff.c
parse-options.c
parse-options.h
t/helper/test-parse-options.c
t/helper/test-serve-v2.c
t/t0040-parse-options.sh