Skip to content

Commit b5cd634

Browse files
PhilipOakleygitster
authored andcommitted
doc: pretty-formats describe use of ellipsis in truncation
Commit a7f01c6 (pretty: support truncating in %>, %< and %><, 2013-04-19) added the use of ellipsis when truncating placeholder values. Show our 'two dot' ellipsis, and examples for the left, middle and right truncation to avoid any confusion as to which end of the string is adjusted. (cf justification and sub-string). Signed-off-by: Philip Oakley <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 63792c5 commit b5cd634

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

Documentation/pretty-formats.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -149,9 +149,9 @@ The placeholders are:
149149
'%<( <N> [,trunc|ltrunc|mtrunc])':: make the next placeholder take at
150150
least N column widths, padding spaces on
151151
the right if necessary. Optionally
152-
truncate at the beginning (ltrunc),
153-
the middle (mtrunc) or the end
154-
(trunc) if the output is longer than
152+
truncate (with ellipsis '..') at the left (ltrunc) `..ft`,
153+
the middle (mtrunc) `mi..le`, or the end
154+
(trunc) `rig..`, if the output is longer than
155155
N columns.
156156
Note 1: that truncating
157157
only works correctly with N >= 2.

0 commit comments

Comments
 (0)