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

Re: [BUG?] git log does not decorate when custom format is used

From
Jeff King <peff@peff.net>
Date
Aug 20, 2008, 17:53 UTC
Message-ID
<20080820175325.GD27773@sigill.intra.peff.net>
In-Reply-To
<1KVmkk-2IOrGi0@fwd26.aul.t-online.de>
On Wed, Aug 20, 2008 at 02:25:30PM +0200, MichaelTiloDressel@t-online.de wrote:
> is it a bug?
Sort of. More like a missing feature.
Show 6 quoted lines
> When I use something like:
> git log --pretty=format:'%H %s' --decorate
> I do not get the decoration.
> While 
> git log --pretty=oneline --decorate
> does decorate.

The problem is where the decoration would go. I think it makes sense not to show the decoration automatically in that case, since its placement depends on the user formatting.

The right solution would be a '%d' placeholder to include the decoration. Patch series to follow:

  [1/2] decorate: allow const objects to be decorated
  [2/2] allow '%d' pretty format specifier to show decoration
-Peff
Previous: MichaelTiloDressel@t-online.deNext: Jeff King
Message 2 of 14 in “[BUG?] git log does not decorate when custom format is used”
  1. MichaelTiloDressel@t-online.deAug 20, 2008
  2. Jeff KingAug 20, 2008
  3. 1/2 decorate: allow const objects to be decoratedJeff King, Aug 20, 2008
  4. 2/2 allow '%d' pretty format specifier to show decorationJeff King, Aug 20, 2008
  5. Junio C HamanoAug 20, 2008
  6. Johannes SchindelinAug 20, 2008
  7. Junio C HamanoAug 20, 2008
  8. Johannes SchindelinAug 20, 2008
  9. Jeff KingSep 3, 2008
  10. Michael DresselAug 20, 2008
  11. Junio C HamanoAug 20, 2008
  12. Michael DresselAug 20, 2008
  13. "log --pretty=format:" languageTeemu Likonen, Aug 21, 2008
  14. Jakub NarebskiAug 24, 2008

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.