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/t6413-merge-crlf.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 / t6413-merge-crlf.sh` 47 lines ยท 978 bytes Raw Blame History 1 #!/bin/sh 2 3 test_description='merge conflict in crlf repo 4 5 b---M 6 / / 7 initial---a 8 9 ' 10 11 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main 12 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME 13 14 . ./test-lib.sh 15 16 test_expect_success setup ' 17 git config core.autocrlf true && 18 echo foo | append_cr >file && 19 git add file && 20 git commit -m "Initial" && 21 git tag initial && 22 git branch side && 23 echo line from a | append_cr >file && 24 git commit -m "add line from a" file && 25 git tag a && 26 git checkout side && 27 echo line from b | append_cr >file && 28 git commit -m "add line from b" file && 29 git tag b && 30 git checkout main 31 ' 32 33 test_expect_success 'Check "ours" is CRLF' ' 34 git reset --hard initial && 35 git merge side -s ours && 36 remove_cr file.temp && 37 test_cmp file file.temp 38 ' 39 40 test_expect_success 'Check that conflict file is CRLF' ' 41 git reset --hard a && 42 test_must_fail git merge side && 43 remove_cr file.temp && 44 test_cmp file file.temp 45 ' 46 47 test_done