replace: allow long option names
It is now standard practice in Git to have both short and long option names. So let's give a long option name to the git replace options too. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Christian Couder committed
Sep 6, 2013 at 07:10 UTC
ed0ff80984d37f9f40b1bf209bc86ea2fa8f3783
2 files changed
+6
-3
Documentation/git-replace.txt
+3
@@ -54,13 +54,16 @@ achieve the same effect as the `--no-replace-objects` option.
54
OPTIONS
55
-------
56
-f::
57
+--force::
58
If an existing replace ref for the same object exists, it will
59
be overwritten (instead of failing).
60
61
-d::
62
+--delete::
63
Delete existing replace refs for the given objects.
64
65
-l <pattern>::
66
+--list <pattern>::
67
List replace refs for objects that match the given pattern (or
68
all if no pattern is given).
69
Typing "git replace" without arguments, also lists all replace
builtin/replace.c
+3
-3
@@ -128,9 +128,9 @@ int cmd_replace(int argc, const char **argv, const char *prefix)
128
{
129
int list = 0, delete = 0, force = 0;
130
struct option options[] = {
131
- OPT_BOOLEAN('l', NULL, &list, N_("list replace refs")),
132
- OPT_BOOLEAN('d', NULL, &delete, N_("delete replace refs")),
133
- OPT_BOOLEAN('f', NULL, &force, N_("replace the ref if it exists")),
131
+ OPT_BOOLEAN('l', "list", &list, N_("list replace refs")),
132
+ OPT_BOOLEAN('d', "delete", &delete, N_("delete replace refs")),
133
+ OPT_BOOLEAN('f', "force", &force, N_("replace the ref if it exists")),
134
OPT_END()
135
};
136