@matheusbsbs / matheus-bagliano / commits / 0371a764d2
Fork 0

help: drop usage of 'common' and 'useful' for guides

Since 1b81d8cb19 (help: use command-list.txt for the source of guides, 2018-05-20), all man5/man7 guides listed in command-list.txt appear in the output of 'git help -g'. However, 'git help -g' still prefixes this list with "The common Git guides are:", which makes one wonder if there are others! In the same spirit, the man page for 'git help' describes the '--guides' option as listing 'useful' guides, which is not false per se but can also be taken to mean that there are other guides that exist but are not useful. Instead of 'common' and 'useful', use 'Git concept guides' in both places. To keep the code in line with this change, rename help.c::list_common_guides_help to list_guides_help. Signed-off-by: Philippe Blain <levraiphilippeblain@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Philippe Blain committed Aug 5, 2020 at 01:19 UTC 0371a764d2db05e13a87bc1fc16600a1a576e9fe
4 files changed +7 -7
Documentation/git-help.txt
+3 -3
@@ -21,8 +21,8 @@ on the standard output.
21 If the option `--all` or `-a` is given, all available commands are
22 printed on the standard output.
23
24 -If the option `--guides` or `-g` is given, a list of the useful
25 -Git guides is also printed on the standard output.
24 +If the option `--guides` or `-g` is given, a list of the
25 +Git concept guides is also printed on the standard output.
26
27 If a command, or a guide, is given, a manual page for that command or
28 guide is brought up. The 'man' program is used by default for this
@@ -58,7 +58,7 @@ OPTIONS
58
59 -g::
60 --guides::
61 - Prints a list of useful guides on the standard output. This
61 + Prints a list of the Git concept guides on the standard output. This
62 option overrides any given command or guide name.
63
64 -i::
builtin/help.c
+1 -1
@@ -579,7 +579,7 @@ int cmd_help(int argc, const char **argv, const char *prefix)
579 }
580
581 if (show_guides)
582 - list_common_guides_help();
582 + list_guides_help();
583
584 if (show_all || show_guides) {
585 printf("%s\n", _(git_more_info_string));
help.c
+2 -2
@@ -397,10 +397,10 @@ void list_cmds_by_config(struct string_list *list)
397 }
398 }
399
400 -void list_common_guides_help(void)
400 +void list_guides_help(void)
401 {
402 struct category_description catdesc[] = {
403 - { CAT_guide, N_("The common Git guides are:") },
403 + { CAT_guide, N_("The Git concept guides are:") },
404 { 0, NULL }
405 };
406 print_cmd_by_category(catdesc, NULL);
help.h
+1 -1
@@ -21,7 +21,7 @@ static inline void mput_char(char c, unsigned int num)
21
22 void list_common_cmds_help(void);
23 void list_all_cmds_help(void);
24 -void list_common_guides_help(void);
24 +void list_guides_help(void);
25
26 void list_all_main_cmds(struct string_list *list);
27 void list_all_other_cmds(struct string_list *list);