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

Re: [PATCH v3 2/5] pretty: make %H/%h/etc respect --abbrev[-commit]

From
Will Palmer <wmpalmer@gmail.com>
Date
May 2, 2010, 07:52 UTC
Message-ID
<1272786771.4194.13.camel@walleee>
In-Reply-To
<7v39yazx4i.fsf@alter.siamese.dyndns.org>
On Sat, 2010-05-01 at 22:33 -0700, Junio C Hamano wrote:
> Jeff King <peff@peff.net> writes:
> 
> > On Sat, May 01, 2010 at 08:13:00PM -0700, Junio C Hamano wrote:
> >

Sounds like this one remains controversial. I'll pull the format changes out of the next pretty-alias series, and submit them as separate patches later on. I still think the documentation implies that %H should be abbreviated when --abbrev-commit is passed, but for now I'm going to focus on cleaning up the pretty.alias code. The eventual solution, I suspect, will involve a more-generic syntax as was brought up in the previous discussion. Something like %(abbrev-commit?%H), which would also be able to play with something like [but, for obvious reasons, not exactly] %(is-merge?Merge: %p %p)

The %?C syntax seems to be generating less comment this time, and is the one that I would find the most important to extending the usefulness of format-aliases (ie: so that I can view a custom log with color in a terminal, then output it to a text file and have it "do the right thing"). Still, it would be lonely without %H/%h, so I'll stick it in its own patch as well (once I fix it up a bit more, as mentioned in the other thread).

-- 
-- Will
Previous: Jeff KingNext: Will Palmer
Message 10 of 21 in “pretty: format aliases”
  1. 0/5 pretty: format aliasesWill Palmer, Apr 30, 2010
  2. 1/5 pretty: add conditional %C?colorname placeholdersWill Palmer, Apr 30, 2010
  3. Junio C HamanoMay 2, 2010
  4. Will PalmerMay 2, 2010
  5. 2/5 pretty: make %H/%h/etc respect --abbrev[-commit]Will Palmer, Apr 30, 2010
  6. Junio C HamanoMay 2, 2010
  7. Jeff KingMay 2, 2010
  8. Junio C HamanoMay 2, 2010
  9. Jeff KingMay 2, 2010
  10. Will PalmerMay 2, 2010
  11. Will PalmerMay 2, 2010
  12. Junio C HamanoMay 2, 2010
  13. Jonathan NiederMay 2, 2010
  14. 3/5 pretty: make it easier to add new formatsWill Palmer, Apr 30, 2010
  15. 4/5 pretty: add infrastructure to allow format aliasesWill Palmer, Apr 30, 2010
  16. Junio C HamanoMay 2, 2010
  17. Will PalmerMay 2, 2010
  18. 5/5 pretty: add aliases for pretty formatsWill Palmer, Apr 30, 2010
  19. Junio C HamanoMay 2, 2010
  20. Jeff KingMay 2, 2010
  21. Junio C HamanoMay 2, 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.