| git init file-creation && |
| git commit --allow-empty -m init && |
| echo postimage >"$postimage" && |
| git add -N "$postimage" && |
| git diff HEAD >"../git-$desc.diff" |
| rm -fr trad-modification && |
| mkdir trad-modification && |
| echo preimage >"$postimage.orig" && |
| echo postimage >"$postimage" && |
| ! diff -u "$postimage.orig" "$postimage" >"../diff-$desc.diff" |
| echo postimage >"b/$postimage" && |
| ! diff -pruN a b >"../add-$desc.diff" |
| do_filename plain postimage.txt && |
| do_filename 'with spaces' 'post image.txt' && |
| do_filename 'with tab' 'post image.txt' && |
| do_filename 'with backslash' 'post\image.txt' && |
| do_filename 'with quote' '"postimage".txt' && |
| expand add-plain.diff >damaged.diff || |