From: Harry Jeffery <harry@exec64.co.uk>
To: Junio C Hamano <gitster@pobox.com>
Cc: git@vger.kernel.org
Subject: Re: [PATCH] pretty-format: add append line-feed format specifier
Date: Tue, 09 Sep 2014 20:30:20 +0100 [thread overview]
Message-ID: <540F554C.5010301@exec64.co.uk> (raw)
In-Reply-To: <xmqqmwa8k3lg.fsf@gitster.dls.corp.google.com>
On 09/09/14 20:15, Junio C Hamano wrote:
> Is this different from "%n%-d"?
>
Yes. "%n%-d" will place the newline before the expansion, not after.
log --decorate --pretty=format:"%n%-d%h\\ %t\\ [%cn]\\ %s"
---
(HEAD, upstream/master, master)85f0837 c29da1d [Junio C Hamano] Start
the post-2.1 cycle
f655651 4027a43 [Junio C Hamano] Merge branch 'rs/strbuf-getcwd'
51eeaea 1f4970c [Junio C Hamano] Merge branch 'ta/pretty-parse-config'
4740891 8961621 [Junio C Hamano] Merge branch 'bc/archive-pax-header-mode'
---
log --decorate --pretty=format:"%_d%%h\\ %t\\ [%cn]\\ %s"
---
(HEAD, upstream/master, master)
85f0837 c29da1d [Junio C Hamano] Start the post-2.1 cycle
f655651 4027a43 [Junio C Hamano] Merge branch 'rs/strbuf-getcwd'
51eeaea 1f4970c [Junio C Hamano] Merge branch 'ta/pretty-parse-config'
4740891 8961621 [Junio C Hamano] Merge branch 'bc/archive-pax-header-mode'
---
The latter is the output I've been trying to accomplish, and as far as I
can tell, this patch is the only way to achieve it.
Well, you can do "%d%n" but that will put a blank line before every
commit that doesn't have a ref.
next prev parent reply other threads:[~2014-09-09 19:30 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-09-09 18:09 [PATCH] pretty-format: add append line-feed format specifier Harry Jeffery
2014-09-09 19:15 ` Junio C Hamano
2014-09-09 19:30 ` Harry Jeffery [this message]
2014-09-09 19:37 ` Junio C Hamano
2014-09-09 21:45 ` Jeff King
2014-09-09 22:17 ` Harry Jeffery
2014-09-09 22:31 ` Jeff King
2014-09-10 17:19 ` Junio C Hamano
2014-09-12 4:49 ` Jeff King
2014-09-12 16:36 ` Junio C Hamano
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=540F554C.5010301@exec64.co.uk \
--to=harry@exec64.co.uk \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).