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

Re: [PATCH] Show branch information in short output of git status

From
Michael J Gruber <git@drmicha.warpmail.net>
Date
May 25, 2010, 14:03 UTC
Message-ID
<4BFBD8A3.8040203@drmicha.warpmail.net>
In-Reply-To
<284d7af64fec2dc0cabdb5cf29ab3fd34fad79f0.1274794889.git.git@drmicha.warpmail.net>
Show 10 quoted lines
> From: Daniel Knittl-Frank <knittl89+git@googlemail.com>
> 
> This patch adds a first line in the output of `git status -s` when given
> the option `-b` or `--branch`, showing which branch the user is
> currently on, and in case of tracking branches the number of commits on
> each branch.
> 
> Signed-off-by: Daniel Knittl-Frank <knittl89+git@googlemail.com>
> ---
> Sent by the not-so-atomatic mob-robot...
...with the not so automagic spell-checker...
Show 7 quoted lines
> I noticed some white space issue but assume Junio fixes that automatically
> when applying.
> 
>  builtin/commit.c |    8 ++++-
>  wt-status.c      |   68 ++++++++++++++++++++++++++++++++++++++++++++++++++++-
>  wt-status.h      |    6 +++-
>  3 files changed, 76 insertions(+), 6 deletions(-)

I tried it and I like it! [Ordinary status could use the same colors for tracking info, they're helpful.]

I also like the fact that --porcelain -b does what it should (unchanged by the patch).

I'm wondering what "git status -b" should do. Currently, "-b" is ignored silently. One may argue it's okay since ordinary status shows tracking info anyways.

Michael
Previous: Michael J GruberNext: Michael J Gruber
Message 2 of 3 in “Show branch information in short output of git status”
  1. Show branch information in short output of git statusMichael J Gruber, May 25, 2010
  2. Michael J GruberMay 25, 2010
  3. Documentation+t5708: document and test status -s -bMichael J Gruber, May 25, 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.