Make usage strings dash-less
When you misuse a git command, you are shown the usage string. But this is currently shown in the dashed form. So if you just copy what you see, it will not work, when the dashed form is no longer supported. This patch makes git commands show the dash-less version. For shell scripts that do not specify OPTIONS_SPEC, git-sh-setup.sh generates a dash-less usage string now. Signed-off-by: Stephan Beyer <s-beyer@gmx.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
d492b31caf
commit
1b1dd23f2d
@ -13,9 +13,9 @@
|
||||
*/
|
||||
|
||||
static const char reflog_expire_usage[] =
|
||||
"git-reflog (show|expire) [--verbose] [--dry-run] [--stale-fix] [--expire=<time>] [--expire-unreachable=<time>] [--all] <refs>...";
|
||||
"git reflog (show|expire) [--verbose] [--dry-run] [--stale-fix] [--expire=<time>] [--expire-unreachable=<time>] [--all] <refs>...";
|
||||
static const char reflog_delete_usage[] =
|
||||
"git-reflog delete [--verbose] [--dry-run] [--rewrite] [--updateref] <refs>...";
|
||||
"git reflog delete [--verbose] [--dry-run] [--rewrite] [--updateref] <refs>...";
|
||||
|
||||
static unsigned long default_reflog_expire;
|
||||
static unsigned long default_reflog_expire_unreachable;
|
||||
@ -630,7 +630,7 @@ static int cmd_reflog_delete(int argc, const char **argv, const char *prefix)
|
||||
*/
|
||||
|
||||
static const char reflog_usage[] =
|
||||
"git-reflog (expire | ...)";
|
||||
"git reflog (expire | ...)";
|
||||
|
||||
int cmd_reflog(int argc, const char **argv, const char *prefix)
|
||||
{
|
||||
|
Reference in New Issue
Block a user