prune: allow --dry-run for -n and --verbose for -v
For consistency with other git commands, let git prune accept the long options --dry-run and --verbose for the respective short ones -n and -v. Signed-off-by: Rene Scharfe <rene.scharfe@lsrfire.ath.cx> Signed-off-by: Junio C Hamano <gitster@pobox.com>
René Scharfe committed
Aug 6, 2010 at 22:28 UTC
24aea033138561e5501ee5dfb3459f3ae4940625
2 files changed
+4
-3
Documentation/git-prune.txt
+2
@@ -31,10 +31,12 @@ OPTIONS
31
-------
32
33
-n::
34
+--dry-run::
35
Do not remove anything; just report what it would
36
remove.
37
38
-v::
39
+--verbose::
40
Report all removed objects.
41
42
\--::
builtin/prune.c
+2
-3
@@ -125,10 +125,9 @@ int cmd_prune(int argc, const char **argv, const char *prefix)
125
{
126
struct rev_info revs;
127
const struct option options[] = {
128
- OPT_BOOLEAN('n', NULL, &show_only,
128
+ OPT_BOOLEAN('n', "dry-run", &show_only,
129
"do not remove, show only"),
130
- OPT_BOOLEAN('v', NULL, &verbose,
131
- "report pruned objects"),
130
+ OPT_BOOLEAN('v', "verbose", &verbose, "report pruned objects"),
131
OPT_DATE(0, "expire", &expire,
132
"expire objects older than <time>"),
133
OPT_END()