summaryrefslogtreecommitdiff
path: root/builtin/commit.c
diff options
context:
space:
mode:
authorDenton Liu <liu.denton@gmail.com>2019-04-17 10:23:26 (GMT)
committerJunio C Hamano <gitster@pobox.com>2019-04-18 04:49:28 (GMT)
commitca04dc96d13cbe5aead17a936e3b8695b20abb55 (patch)
tree9de34ca9a25415d0ee4c073fae938144f93bcf0e /builtin/commit.c
parentf29cd8620d85543dbef572f522c71991b3736387 (diff)
downloadgit-ca04dc96d13cbe5aead17a936e3b8695b20abb55.zip
git-ca04dc96d13cbe5aead17a936e3b8695b20abb55.tar.gz
git-ca04dc96d13cbe5aead17a936e3b8695b20abb55.tar.bz2
parse-options.h: extract common --cleanup option
The --cleanup option is commonly used. Extract it so that its definition is not repeated. Helped-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Denton Liu <liu.denton@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
-rw-r--r--builtin/commit.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index 0df15e4..8277da8 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -1473,7 +1473,7 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
OPT_BOOL('s', "signoff", &signoff, N_("add Signed-off-by:")),
OPT_FILENAME('t', "template", &template_file, N_("use specified template file")),
OPT_BOOL('e', "edit", &edit_flag, N_("force edit of commit")),
- OPT_STRING(0, "cleanup", &cleanup_arg, N_("default"), N_("how to strip spaces and #comments from message")),
+ OPT_CLEANUP(&cleanup_arg),
OPT_BOOL(0, "status", &include_status, N_("include status in commit message template")),
{ OPTION_STRING, 'S', "gpg-sign", &sign_commit, N_("key-id"),
N_("GPG sign commit"), PARSE_OPT_OPTARG, NULL, (intptr_t) "" },