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

Re: How to trim the fat on my log graphs

From
RDRobert Dailey <rcdailey.lists@gmail.com>
Date
Apr 23, 2014, 19:59 UTC
Message-ID
<CAHd499Cw8=FMctRA49MUi+vP2gvMyXH9WgcfCKK_MrKDEOfvjw@mail.gmail.com>
In-Reply-To
<xmqqha5k0x8c.fsf@gitster.dls.corp.google.com>
On Wed, Apr 23, 2014 at 12:30 PM, Junio C Hamano <gitster@pobox.com> wrote:
Show 32 quoted lines
> Robert Dailey <rcdailey.lists@gmail.com> writes:
>
> [Administrivia: because people read from top to bottom / why is it
> bad to top-post? / please do not top-post.]
>
>> On Tue, Apr 22, 2014 at 4:37 PM, Junio C Hamano <gitster@pobox.com> wrote:
>>> Robert Dailey <rcdailey.lists@gmail.com> writes:
>>>
>>>> git log log --graph --abbrev-commit --decorate --date=relative
>>>> --format=format:'%C(bold blue)%h%C(reset)%x09%C(bold
>>>> green)(%ar)%C(reset)%C(bold yellow)%d%C(reset) %C(dim
>>>> white)%an%C(reset) - %C(white)%s%C(reset)' --branches --remotes
>>>> ...
>>>> The goal is to weed out the really distant and irrelevant commits. I
>>>> really just want to see the commits that are closely related to my
>>>> current branch. Thanks in advance.
>>>
>>> For a starter, how about dropping "--branches --remotes" from that
>>> command line?  A merge from elsewhere will show as "Merge branch foo"
>>> which should be sufficient without the decoration.
>>
>> Thanks, removing those two options did help quite a bit already.
>> However, the history can still get pretty crazy. Is there a way to
>> hide all tags from the log graph? Really I just want the LABELS to be
>> hidden.
>
> As you had --decorate and a lot of %C(cruft), I was assuming that
> you do want to see all the bells and whistles when I suggested to
> omit --branches and --remotes.
>
> If you do not want --decorate, I think you can omit that from the
> command line without changing what the output means.
I referred back to the documentation for --decorate:

--decorate[=short|full|no] Print out the ref names of any commits that are shown. If short is specified, the ref name prefixesrefs/heads/, refs/tags/ and refs/remotes/ will not be printed. If full is specified, the full ref name (including prefix) will be printed. The default option is short.

since default is short, and its documented to exclude tag names, I would expect them to not be there. I also tried removing it to test but i saw no difference; tag names are still visible.

Previous: Junio C HamanoNext: Junio C Hamano
Message 5 of 8 in “How to trim the fat on my log graphs”
  1. Robert DaileyApr 22, 2014
  2. Junio C HamanoApr 22, 2014
  3. Robert DaileyApr 23, 2014
  4. Junio C HamanoApr 23, 2014
  5. Robert DaileyApr 23, 2014
  6. Junio C HamanoApr 23, 2014
  7. Jeff KingApr 23, 2014
  8. Felipe ContrerasApr 23, 2014

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.