(CommandList children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:test_description spids:[13]) op: Equal rhs: {(SQ <'git-am mbox with dos line ending.\n'> <'\n'>)} spids: [13] ) ] spids: [13] ) (C {(.)} {(./test-lib.sh)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(file1)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 38 stdin_parts: [('line 1\n')] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(file1a)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 51 stdin_parts: [('line 1\n') ('line 4\n')] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(file2)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 64 stdin_parts: [('line 1\n') ('line 2\n')] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(file3)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 78 stdin_parts: [('line 1\n') ('line 2\n') ('line 3\n')] ) ] ) (C {(test_expect_success)} {(SQ <'setup repository with dos files'>)} { (SQ <'\n'> <'\tappend_cr <file1 >file &&\n'> <'\tgit add file &&\n'> <'\tgit commit -m Initial &&\n'> <'\tgit tag initial &&\n'> <'\tappend_cr <file2 >file &&\n'> <'\tgit commit -a -m Second &&\n'> <'\tappend_cr <file3 >file &&\n'> <'\tgit commit -a -m Third\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with dos files without --keep-cr'>)} { (SQ <'\n'> <'\tgit checkout -b dosfiles initial &&\n'> <'\tgit format-patch -k initial..master &&\n'> <'\ttest_must_fail git am -k -3 000*.patch &&\n'> <'\tgit am --abort &&\n'> <'\trm -rf .git/rebase-apply 000*.patch\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with dos files with --keep-cr'>)} { (SQ <'\n'> <'\tgit checkout -b dosfiles-keep-cr initial &&\n'> <'\tgit format-patch -k --stdout initial..master | git am --keep-cr -k -3 &&\n'> <'\tgit diff --exit-code master\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with dos files config am.keepcr'>)} { (SQ <'\n'> <'\tgit config am.keepcr 1 &&\n'> <'\tgit checkout -b dosfiles-conf-keepcr initial &&\n'> <'\tgit format-patch -k --stdout initial..master | git am -k -3 &&\n'> <'\tgit diff --exit-code master\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with dos files config am.keepcr overridden by --no-keep-cr'>)} { (SQ <'\n'> <'\tgit config am.keepcr 1 &&\n'> <'\tgit checkout -b dosfiles-conf-keepcr-override initial &&\n'> <'\tgit format-patch -k initial..master &&\n'> <'\ttest_must_fail git am -k -3 --no-keep-cr 000*.patch &&\n'> <'\tgit am --abort &&\n'> <'\trm -rf .git/rebase-apply 000*.patch\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with dos files with --keep-cr continue'>)} { (SQ <'\n'> <'\tgit checkout -b dosfiles-keep-cr-continue initial &&\n'> <'\tgit format-patch -k initial..master &&\n'> <'\tappend_cr <file1a >file &&\n'> <'\tgit commit -m "different patch" file &&\n'> <'\ttest_must_fail git am --keep-cr -k -3 000*.patch &&\n'> <'\tappend_cr <file2 >file &&\n'> <'\tgit add file &&\n'> <'\tgit am -3 --resolved &&\n'> <'\tgit diff --exit-code master\n'> ) } ) (C {(test_expect_success)} {(SQ <'am with unix files config am.keepcr overridden by --no-keep-cr'>)} { (SQ <'\n'> <'\tgit config am.keepcr 1 &&\n'> <'\tgit checkout -b unixfiles-conf-keepcr-override initial &&\n'> <'\tcp -f file1 file &&\n'> <'\tgit commit -m "line ending to unix" file &&\n'> <'\tgit format-patch -k initial..master &&\n'> <'\tgit am -k -3 --no-keep-cr 000*.patch &&\n'> <'\tgit diff --exit-code -w master\n'> ) } ) (C {(test_done)}) ] )