parse-options: add parse_opt_unknown_cb()
Add a new callback function, parse_opt_unknown_cb(), which returns -2 to indicate that the corresponding option is unknown. This can be used to add "-h" documentation for an option that will be handled externally to parse_options(). Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
committed by
Junio C Hamano
parent
433860f3d0
commit
ce564eb1bd
@ -228,6 +228,7 @@ extern int parse_opt_commits(const struct option *, const char *, int);
|
||||
extern int parse_opt_tertiary(const struct option *, const char *, int);
|
||||
extern int parse_opt_string_list(const struct option *, const char *, int);
|
||||
extern int parse_opt_noop_cb(const struct option *, const char *, int);
|
||||
extern int parse_opt_unknown_cb(const struct option *, const char *, int);
|
||||
extern int parse_opt_passthru(const struct option *, const char *, int);
|
||||
extern int parse_opt_passthru_argv(const struct option *, const char *, int);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user