Thread (1 message) 1 message, 1 author, 2016-10-06

Re: Format for %d includes unwanted preceding space

From: Junio C Hamano <hidden>
Date: 2016-10-06 18:49:59

"Ravi (Tom) Hale" [off-list ref] writes:
The log --format="%d" includes preceding space:

$ git log -n1 --format="XX%dXX" HEAD
XX (HEAD -> master)XX

I know of no other %<token> that is output in this way.
That is primarily because %d predates %[-+ ]<placeholder> mechanism,
I think.  It is too late to redefine what "%d" means and force all
users to update their script to use "% d" instead, unfortunately.

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help