git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] cat-file: add missing [=<format>] to usage/synopsis

From
Jeff King <peff@peff.net>
Date
Jul 1, 2020, 15:03 UTC
Message-ID
<20200701150313.GA6726@coredump.intra.peff.net>
In-Reply-To
<20200701101618.28761-1-chriscool@tuxfamily.org>
On Wed, Jul 01, 2020 at 12:16:18PM +0200, Christian Couder wrote:
Show 15 quoted lines
> When displaying cat-file usage, the fact that a <format> can
> be specified is only visible when lookling at the --batch and
> --batch-check options which are shown like this:
> 
>     --batch[=<format>]    show info and content of objects fed from the standard input
>     --batch-check[=<format>]
>                           show info about objects fed from the standard input
> 
> It seems more coherent and improves discovery to also show it
> on the usage line.
> 
> In the documentation the DESCRIPTION tells us that "The output
> format can be overridden using the optional <format> argument",
> but we can't see the <format> argument in the SYNOPSIS above
> the description which is confusing.

Thanks, this makes sense and the patch looks good to me (it does make the line very long, but the one above is much longer anyway).

-Peff
Previous: Christian Couder
Message 2 of 2 in “cat-file: add missing [=<format>] to usage/synopsis”
  1. cat-file: add missing [=<format>] to usage/synopsisChristian Couder, Jul 1, 2020
  2. Jeff KingJul 1, 2020

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.