On Wed, Sep 8, 2021 at 11:24 AM Ævar Arnfjörð Bjarmason <avarab@xxxxxxxxx> wrote: > Instead of having two lines that call list_config_help(for_human) > let's setup the pager and print the trailer conditionally. This makes > it clearer at a glance how the two differ in behavior. > > Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@xxxxxxxxx> > --- > @@ -574,13 +574,12 @@ int cmd_help(int argc, const char **argv, const char *prefix) > - if (!for_human) { > - list_config_help(for_human); > - return 0; > - } > - setup_pager(); > + if (for_human) > + setup_pager(); > list_config_help(for_human); > - printf("\n%s\n", _("'git help config' for more information")); > + if (for_human) > + printf("\n%s\n", _("'git help config' for more information")); > + For what it's worth, I find the original logic easier to reason about since it gets the "simple" case out of the way early, thus I don't have to keep as much (or any) state in mind as I'm reading the rest of the code. However, it's highly subjective, of course; just one person's opinion.