]>
Commit | Line | Data |
---|---|---|
3714e7c8 JS |
1 | #!/bin/sh |
2 | # | |
3 | # Copyright (c) 2006 Johannes E. Schindelin | |
4 | # | |
5 | ||
5be60078 | 6 | test_description='git shortlog |
3714e7c8 JS |
7 | ' |
8 | ||
9 | . ./test-lib.sh | |
10 | ||
11 | echo 1 > a1 | |
12 | git add a1 | |
13 | tree=$(git write-tree) | |
238128d8 | 14 | commit=$( (echo "Test"; echo) | git commit-tree $tree ) |
3714e7c8 JS |
15 | git update-ref HEAD $commit |
16 | ||
17 | echo 2 > a1 | |
557b1e0d | 18 | git commit --quiet -m "This is a very, very long first line for the commit message to see if it is wrapped correctly" a1 |
3714e7c8 JS |
19 | |
20 | # test if the wrapping is still valid when replacing all i's by treble clefs. | |
21 | echo 3 > a1 | |
557b1e0d | 22 | git commit --quiet -m "$(echo "This is a very, very long first line for the commit message to see if it is wrapped correctly" | sed "s/i/1234/g" | tr 1234 '\360\235\204\236')" a1 |
3714e7c8 JS |
23 | |
24 | # now fsck up the utf8 | |
5c66d0d4 | 25 | git config i18n.commitencoding non-utf-8 |
3714e7c8 | 26 | echo 4 > a1 |
557b1e0d | 27 | git commit --quiet -m "$(echo "This is a very, very long first line for the commit message to see if it is wrapped correctly" | sed "s/i/1234/g" | tr 1234 '\370\235\204\236')" a1 |
3714e7c8 JS |
28 | |
29 | echo 5 > a1 | |
557b1e0d | 30 | git commit --quiet -m "a 12 34 56 78" a1 |
3714e7c8 | 31 | |
3d711d97 | 32 | git shortlog -w HEAD > out |
3714e7c8 JS |
33 | |
34 | cat > expect << EOF | |
35 | A U Thor (5): | |
36 | Test | |
37 | This is a very, very long first line for the commit message to see if | |
38 | it is wrapped correctly | |
39 | Th๐s ๐s a very, very long f๐rst l๐ne for the comm๐t message to see ๐f | |
40 | ๐t ๐s wrapped correctly | |
41 |