@matheusbsbs / matheus-bagliano / commits / 6586b1f346
Fork 0

check-ref-format: update usage string

'git check-ref-format' has learned --branch and --print options since the usage string was last updated. Signed-off-by: Jonathan Nieder <jrnieder@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Jonathan Nieder committed Nov 9, 2009 at 09:04 UTC 6586b1f3465a93e908664ea24fa2f5ff47a587e3
1 file changed +5 -1
builtin-check-ref-format.c
+5 -1
@@ -7,6 +7,10 @@
7 #include "builtin.h"
8 #include "strbuf.h"
9
10 +static const char builtin_check_ref_format_usage[] =
11 +"git check-ref-format [--print] <refname>\n"
12 +" or: git check-ref-format --branch <branchname-shorthand>";
13 +
14 int cmd_check_ref_format(int argc, const char **argv, const char *prefix)
15 {
16 if (argc == 3 && !strcmp(argv[1], "--branch")) {
@@ -18,6 +22,6 @@ int cmd_check_ref_format(int argc, const char **argv, const char *prefix)
22 exit(0);
23 }
24 if (argc != 2)
21 - usage("git check-ref-format refname");
25 + usage(builtin_check_ref_format_usage);
26 return !!check_ref_format(argv[1]);
27 }