@@ -12,23 +12,25 @@ test_tick
12
12
# String "added" in German
13
13
# (translated with Google Translate),
14
14
# encoded in UTF-8, used as a commit log message below.
15
- added=$( printf ' added (hinzugef\303\274gt) foo' | iconv -t utf-8 )
16
- added_iso88591=$( printf ' added (hinzugef\303\274gt) foo ' | iconv -f utf-8 -t iso8859-1)
15
+ added=$( printf " added (hinzugef\303\274gt) foo" )
16
+ added_iso88591=$( echo " $ added" | iconv -f utf-8 -t iso8859-1)
17
17
# same but "changed"
18
- changed=$( printf " changed (ge\303\244ndert) foo" | iconv -t utf-8 )
19
- changed_iso88591=$( printf ' changed (ge\303\244ndert) foo ' | iconv -f utf-8 -t iso8859-1)
18
+ changed=$( printf " changed (ge\303\244ndert) foo" )
19
+ changed_iso88591=$( echo " $ changed" | iconv -f utf-8 -t iso8859-1)
20
20
21
21
test_expect_success ' setup' '
22
22
: >foo &&
23
23
git add foo &&
24
24
git config i18n.commitEncoding iso8859-1 &&
25
- git commit -m "$added_iso88591" &&
25
+ echo "$added_iso88591" > commit-msg &&
26
+ git commit -F commit-msg &&
26
27
head1=$(git rev-parse --verify HEAD) &&
27
28
head1_short=$(git rev-parse --verify --short $head1) &&
28
29
tree1=$(git rev-parse --verify HEAD:) &&
29
30
tree1_short=$(git rev-parse --verify --short $tree1) &&
30
31
echo "$changed" > foo &&
31
- git commit -a -m "$changed_iso88591" &&
32
+ echo "$changed_iso88591" > commit-msg &&
33
+ git commit -a -F commit-msg &&
32
34
head2=$(git rev-parse --verify HEAD) &&
33
35
head2_short=$(git rev-parse --verify --short $head2) &&
34
36
tree2=$(git rev-parse --verify HEAD:) &&
@@ -206,12 +208,12 @@ test_expect_success '%C(auto) respects --color=auto (stdout not tty)' '
206
208
)
207
209
'
208
210
209
- printf ' Test printing of complex bodies
211
+ printf " Test printing of complex bodies
210
212
211
213
This commit message is much longer than the others,
212
214
and it will be encoded in iso8859-1. We should therefore
213
- include an iso8859 character: \xc2\xa1bueno !
214
- ' | iconv -f utf-8 -t iso8859-1 > commit-msg
215
+ include an iso8859 character: \302\241bueno !
216
+ " | iconv -f utf-8 -t iso8859-1 > commit-msg
215
217
216
218
test_expect_success ' setup complex body' '
217
219
git config i18n.commitencoding iso8859-1 &&
0 commit comments