doc: improve usage string in MyFirstContribution
We implement a command called git-psuh which accept arguments, so let's show that it accepts arguments in the doc and the usage string. While at it, we need to prepare "a NULL-terminated array of usage strings", not just "a NULL-terminated usage string". Helped-by: Emily Shaffer <emilyshaffer@google.com> Helped-by: Eric Sunshine <sunshine@sunshineco.com> Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Christian Couder committed
Jun 22, 2019 at 08:10 UTC
b37e0ec32b580d126ce9e5e706fd32b2edd8a9e9
1 file changed
+7
-5
Documentation/MyFirstContribution.txt
+7
-5
@@ -428,7 +428,7 @@ git-psuh - Delight users' typo with a shy horse
428
SYNOPSIS
429
--------
430
[verse]
431
-'git-psuh'
431
+'git-psuh [<arg>...]'
432
433
DESCRIPTION
434
-----------
@@ -491,14 +491,16 @@ Take a look at `Documentation/technical/api-parse-options.txt`. This is a handy
491
tool for pulling out options you need to be able to handle, and it takes a
492
usage string.
493
494
-In order to use it, we'll need to prepare a NULL-terminated usage string and a
495
-`builtin_psuh_options` array. Add a line to `#include "parse-options.h"`.
494
+In order to use it, we'll need to prepare a NULL-terminated array of usage
495
+strings and a `builtin_psuh_options` array.
496
497
-At global scope, add your usage:
497
+Add a line to `#include "parse-options.h"`.
498
+
499
+At global scope, add your array of usage strings:
500
501
----
502
static const char * const psuh_usage[] = {
501
- N_("git psuh"),
503
+ N_("git psuh [<arg>...]"),
504
NULL,
505
};
506
----