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

Re: jc/shortstatus

From
Junio C Hamano <gitster@pobox.com>
Date
Aug 15, 2009, 08:18 UTC
Message-ID
<7v8whltrqj.fsf@alter.siamese.dyndns.org>
In-Reply-To
<20090815070904.GA23389@coredump.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 7 quoted lines
> For the "git stat" portion still in pu, I have a few comments/questions:
>
>   1. Is "stat" a good name? I worry a little that it is _too_ similar to
>      "status", and that will cause confusion while they both exist. So
>      something like "git overview" would cause less confusion, and even
>      though it sucks to type, it will eventually replace "status" (and
>      in the meantime people can make aliases or whatever).

It is handy to have both available while asking others help debugging the version in 'pu', and that is the only reason for the separate command. It could have been named 'git frotz' for all I care ;-)

I do not intend to make it another "git merge-recur"; I would actually want to have it replace "status" before the series goes to 'next'.

I hopefully will have some time to start doing that over the weekend; the first step would be to rename the branch to jc/1.7.0-status and get rid of cmd_status() from builtin-commit.c.

A few points I haven't managed to think about, decide, nor test, are:
 - What should its exit code be?  Should it be consistent with the
   traditional "git status" at least when no paths are given, signallying
   failure when nothing is staged for committing, so that ancient out of
   tree scripts people may have written would not break too badly when we
   make the switch?
 - What should its default mode of output be?  Do people prefer "svn st"
   style short-format output, or should we stay verbose and explanatory?
 - Is it handling corner cases correctly?  e.g. Does it operate correctly
   when run from a subdirectory?  How should it handle submodules?  Before
   the initial commit?  Use of colors?
Show 6 quoted lines
>   2. Does it really belong in builtin-commit.c anymore? It seems like
>      historical accident that "status" is so closely tied to commit. The
>      whole point of the new command is to _not_ be tied; I think of the
>      new command more as an extension of 'diff'. Admittedly, users don't
>      care where the source is located, but it helps the developers
>      understand the relationships between code.

It would make sense to create a separate builtin-status.c. I haven't looked at the dependencies yet, but it shouldn't be too bad. We'll see.

>   3. Can you squash in the gitignore patch below? :)
Yes but hopefully it won't be necessary ;-)
Previous: Jeff KingNext: Jeff King
Message 5 of 7 in “What's cooking in git.git (Aug 2009, #02; Wed, 12)”
  1. Junio C HamanoAug 13, 2009
  2. Jakub NarebskiAug 14, 2009
  3. Junio C HamanoAug 15, 2009
  4. jc/shortstatus (was: What's cooking in git.git (Aug 2009, #02; Wed, 12))Jeff King, Aug 15, 2009
  5. Junio C HamanoAug 15, 2009
  6. Jeff KingAug 15, 2009
  7. Junio C HamanoAug 15, 2009

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.