diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2018-02-09 12:01:42 +0100 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-02-09 19:24:50 +0100 |
commit | 1224781d6080b8b69a81526ee23b22a1587920ea (patch) | |
tree | 8b31c3cc26307351710d01d6b797d77101bb97b8 /builtin/add.c | |
parent | parse-options: add OPT_xxx_F() variants (diff) | |
download | git-1224781d6080b8b69a81526ee23b22a1587920ea.tar.xz git-1224781d6080b8b69a81526ee23b22a1587920ea.zip |
parse-options: let OPT__FORCE take optional flags argument
--force option is most likely hidden from command line completion for
safety reasons. This is done by adding an extra flag
PARSE_OPT_NOCOMPLETE. Update OPT__FORCE() to accept additional
flags. Actual flag change comes later depending on individual
commands.
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/add.c')
-rw-r--r-- | builtin/add.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/add.c b/builtin/add.c index bf01d89e28..ac7c1c3277 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -294,7 +294,7 @@ static struct option builtin_add_options[] = { OPT_BOOL('i', "interactive", &add_interactive, N_("interactive picking")), OPT_BOOL('p', "patch", &patch_interactive, N_("select hunks interactively")), OPT_BOOL('e', "edit", &edit_interactive, N_("edit current diff and apply")), - OPT__FORCE(&ignored_too, N_("allow adding otherwise ignored files")), + OPT__FORCE(&ignored_too, N_("allow adding otherwise ignored files"), 0), OPT_BOOL('u', "update", &take_worktree_changes, N_("update tracked files")), OPT_BOOL(0, "renormalize", &add_renormalize, N_("renormalize EOL of tracked files (implies -u)")), OPT_BOOL('N', "intent-to-add", &intent_to_add, N_("record only the fact that the path will be added later")), |