diff options
author | Harry Jeffery <harry@exec64.co.uk> | 2014-09-18 22:53:53 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2014-09-19 00:15:21 +0200 |
commit | 9271095cc5571e306d709ebf8eb7f0a388254d9d (patch) | |
tree | 82f6c8af5766632711b0daa9012f4af903c1b3bb /t | |
parent | Merge git://github.com/git-l10n/git-po (diff) | |
download | git-9271095cc5571e306d709ebf8eb7f0a388254d9d.tar.xz git-9271095cc5571e306d709ebf8eb7f0a388254d9d.zip |
pretty: add %D format specifier
Add a new format specifier, '%D' that is identical in behaviour to '%d',
except that it does not include the ' (' prefix or ')' suffix provided
by '%d'.
Signed-off-by: Harry Jeffery <harry@exec64.co.uk>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't')
-rwxr-xr-x | t/t4205-log-pretty-formats.sh | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/t/t4205-log-pretty-formats.sh b/t/t4205-log-pretty-formats.sh index 349c531989..e6015e2684 100755 --- a/t/t4205-log-pretty-formats.sh +++ b/t/t4205-log-pretty-formats.sh @@ -450,4 +450,15 @@ EOF test_cmp expected actual1 ' +test_expect_success 'clean log decoration' ' + git log --no-walk --tags --pretty="%H %D" --decorate=full >actual && + cat >expected <<EOF && +$head1 tag: refs/tags/tag2 +$head2 tag: refs/tags/message-one +$old_head1 tag: refs/tags/message-two +EOF + sort actual >actual1 && + test_cmp expected actual1 +' + test_done |