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

Re: [RFC/PATCH] notes: rework subcommands and parse options

From
Tim Henigan <tim.henigan@gmail.com>
Date
Feb 25, 2010, 18:26 UTC
Message-ID
<32c343771002251026n6d55ea7csbdb4c8899bb5fded@mail.gmail.com>
In-Reply-To
<1267086261-7675-1-git-send-email-bebarino@gmail.com>
On Thu, Feb 25, 2010 at 3:24 AM, Stephen Boyd <bebarino@gmail.com> wrote:
>
> +       else {
> +               result = error("Unknown subcommand: %s", argv[0]);
> +       }

In the case where an unknown subcommand was given, shouldn't the usage instructions be printed? i.e. add the following after the error()?

    usage_with_options(git_notes_usage, options);
-Tim
Previous: Stephen BoydNext: Johan Herland
Message 2 of 4 in “notes: rework subcommands and parse options”
  1. notes: rework subcommands and parse optionsStephen Boyd, Feb 25, 2010
  2. Tim HeniganFeb 25, 2010
  3. Johan HerlandFeb 26, 2010
  4. notes: rework subcommands and parse optionsStephen Boyd, Feb 27, 2010

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.