Interplane page as plain text, for reading tools and agents. English is the reference text: translate it with your own tool. Text in backticks and in ``` blocks (commands, fingerprints, file names) and link targets in <...> are exact: copy them, never translate them. Page: /drakestapleton/git/blob/master/t/t4029-diff-trailing-space.sh # git [Ported from github.com/git/git] Sync with Git 2.56.1 Brought by drakestapleton Sign in to star 0 stars 0 watching About Files History Releases Proposed changes Issues For developers branch `master` Branches Tags History `git / t / t4029-diff-trailing-space.sh` 44 lines ยท 967 bytes Raw Blame History 1 #!/bin/sh 2 # 3 # Copyright (c) Jim Meyering 4 # 5 test_description='diff honors config option, diff.suppressBlankEmpty' 6 7 . ./test-lib.sh 8 9 cat <<\EOF >expected || 10 diff --git a/f b/f 11 index `5f6a263`..`8cb8bae` 100644 12 --- a/f 13 +++ b/f 14 @@ -1,2 +1,2 @@ 15 16 -x 17 +y 18 EOF 19 exit 1 20 21 test_expect_success "$test_description" ' 22 printf "\nx\n" > f && 23 before=$(git hash-object f) && 24 before=$(git rev-parse --short $before) && 25 git add f && 26 git commit -q -m. f && 27 printf "\ny\n" > f && 28 after=$(git hash-object f) && 29 after=$(git rev-parse --short $after) && 30 sed -e "s/^index .*/index $before..$after 100644/" expected >exp && 31 git config --bool diff.suppressBlankEmpty true && 32 git diff f > actual && 33 test_cmp exp actual && 34 sed "s/^\$/ /" exp >exp.munged && 35 mv exp.munged exp && 36 git config --bool diff.suppressBlankEmpty false && 37 git diff f > actual && 38 test_cmp exp actual && 39 git config --bool --unset diff.suppressBlankEmpty && 40 git diff f > actual && 41 test_cmp exp actual 42 ' 43 44 test_done