(CommandList children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:test_description spids:[13]) op: Equal rhs: {(SQ <'git svn property tests'>)} spids: [13] ) ] spids: [13] ) (C {(.)} {(./lib-git-svn.sh)}) (C {(mkdir)} {(import)}) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_crlf spids:[28]) op:Equal rhs:(EmptyWord) spids:[28])] spids: [28] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_lf spids:[30]) op:Equal rhs:(EmptyWord) spids:[30])] spids: [30] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_cr spids:[32]) op:Equal rhs:(EmptyWord) spids:[32])] spids: [32] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_ne_crlf spids:[34]) op: Equal rhs: (EmptyWord) spids: [34] ) ] spids: [34] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_ne_lf spids:[36]) op:Equal rhs:(EmptyWord) spids:[36])] spids: [36] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_ne_cr spids:[38]) op:Equal rhs:(EmptyWord) spids:[38])] spids: [38] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:a_empty spids:[40]) op:Equal rhs:(EmptyWord) spids:[40])] spids: [40] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_lf spids:[42]) op: Equal rhs: (EmptyWord) spids: [42] ) ] spids: [42] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_cr spids:[44]) op: Equal rhs: (EmptyWord) spids: [44] ) ] spids: [44] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_crlf spids:[46]) op: Equal rhs: (EmptyWord) spids: [46] ) ] spids: [46] ) (C {(cd)} {(import)}) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_DGreat '>>'> fd:16777215 arg_word:{(kw.c)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 66 stdin_parts: [('/* Somebody prematurely put a keyword into this file */\n') ('/* $Id$ */\n')] ) ] ) (SimpleCommand words: [ {(printf)} { (DQ (Hello) (Lit_Other '\\') (r) (Lit_Other '\\') (nWorld) (Lit_Other '\\') (r) (Lit_Other '\\') (n) ) } ] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(crlf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_crlf spids:[88]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(crlf)})]) left_token: <Left_CommandSub '$('> spids: [89 97] ) } spids: [88] ) ] spids: [88] ) (SimpleCommand words: [{(printf)} {(DQ (Hello) (Lit_Other '\\') (rWorld) (Lit_Other '\\') (r))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(cr)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_cr spids:[115]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(cr)})]) left_token: <Left_CommandSub '$('> spids: [116 124] ) } spids: [115] ) ] spids: [115] ) (SimpleCommand words: [{(printf)} {(DQ (Hello) (Lit_Other '\\') (nWorld) (Lit_Other '\\') (n))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(lf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_lf spids:[142]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(lf)})]) left_token: <Left_CommandSub '$('> spids: [143 151] ) } spids: [142] ) ] spids: [142] ) (SimpleCommand words: [{(printf)} {(DQ (Hello) (Lit_Other '\\') (r) (Lit_Other '\\') (nWorld))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(ne_crlf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_ne_crlf spids:[170]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(ne_crlf)})]) left_token: <Left_CommandSub '$('> spids: [171 179] ) } spids: [170] ) ] spids: [170] ) (SimpleCommand words: [{(printf)} {(DQ (Hello) (Lit_Other '\\') (nWorld))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(ne_lf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_ne_lf spids:[195]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(ne_lf)})]) left_token: <Left_CommandSub '$('> spids: [196 204] ) } spids: [195] ) ] spids: [195] ) (SimpleCommand words: [{(printf)} {(DQ (Hello) (Lit_Other '\\') (rWorld))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(ne_cr)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_ne_cr spids:[220]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(ne_cr)})]) left_token: <Left_CommandSub '$('> spids: [221 229] ) } spids: [220] ) ] spids: [220] ) (C {(touch)} {(empty)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty spids:[238]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(-w)} {(empty)})]) left_token: <Left_CommandSub '$('> spids: [239 247] ) } spids: [238] ) ] spids: [238] ) (SimpleCommand words: [{(printf)} {(DQ (Lit_Other '\\') (n))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(empty_lf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_lf spids:[262]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(git)} {(hash-object)} {(-w)} {(empty_lf)})] ) left_token: <Left_CommandSub '$('> spids: [263 271] ) } spids: [262] ) ] spids: [262] ) (SimpleCommand words: [{(printf)} {(DQ (Lit_Other '\\') (r))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(empty_cr)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_cr spids:[286]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(git)} {(hash-object)} {(-w)} {(empty_cr)})] ) left_token: <Left_CommandSub '$('> spids: [287 295] ) } spids: [286] ) ] spids: [286] ) (SimpleCommand words: [{(printf)} {(DQ (Lit_Other '\\') (r) (Lit_Other '\\') (n))}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(empty_crlf)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_empty_crlf spids:[312]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [(C {(git)} {(hash-object)} {(-w)} {(empty_crlf)})] ) left_token: <Left_CommandSub '$('> spids: [313 321] ) } spids: [312] ) ] spids: [312] ) (SimpleCommand words: [ {(svn_cmd)} {(import)} {(--no-auto-props)} {(-m)} {(SQ <'import for git svn'>)} {(.)} {(DQ ($ VSub_Name '$svnrepo'))} ] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(/dev/null)})] ) (C {(cd)} {(..)}) (C {(rm)} {(-rf)} {(import)}) (C {(test_expect_success)} {(SQ <'checkout working copy from svn'>)} {(SQ <'svn co "$svnrepo" test_wc'>)} ) (C {(test_expect_success)} {(SQ <'setup some commits to svn'>)} { (SQ <'\n'> <'\t(\n'> <'\t\tcd test_wc &&\n'> <'\t\techo Greetings >> kw.c &&\n'> <'\t\tpoke kw.c &&\n'> <'\t\tsvn_cmd commit -m "Not yet an Id" &&\n'> <'\t\techo Hello world >> kw.c &&\n'> <'\t\tpoke kw.c &&\n'> <'\t\tsvn_cmd commit -m "Modified file, but still not yet an Id" &&\n'> <'\t\tsvn_cmd propset svn:keywords Id kw.c &&\n'> <'\t\tpoke kw.c &&\n'> <'\t\tsvn_cmd commit -m "Propset Id"\n'> <'\t)\n'> ) } ) (C {(test_expect_success)} {(SQ <'initialize git svn'>)} {(SQ <'git svn init "$svnrepo"'>)}) (C {(test_expect_success)} {(SQ <'fetch revisions from svn'>)} {(SQ <'git svn fetch'>)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:name spids:[411]) op: Equal rhs: {(SQ <'test svn:keywords ignoring'>)} spids: [411] ) ] spids: [411] ) (C {(test_expect_success)} {(DQ ($ VSub_Name '$name'))} { (SQ <'git checkout -b mybranch remotes/git-svn &&\n'> <'\techo Hi again >> kw.c &&\n'> <'\tgit commit -a -m "test keywords ignoring" &&\n'> <'\tgit svn set-tree remotes/git-svn..mybranch &&\n'> <'\tgit pull . remotes/git-svn'> ) } ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:expect spids:[433]) op: Equal rhs: {(SQ <'/* $Id$ */'>)} spids: [433] ) ] spids: [433] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:got spids:[438]) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(sed)} {(-ne)} {(2p)} {(kw.c)})]) left_token: <Left_CommandSub '$('> spids: [440 448] ) ) } spids: [438] ) ] spids: [438] ) (C {(test_expect_success)} {(SQ <'raw $Id$ found in kw.c'>)} {(DQ ("test '") ($ VSub_Name '$expect') ("' = '") ($ VSub_Name '$got') ("'"))} ) (C {(test_expect_success)} {(DQ ('propset CR on crlf files'))} { (SQ <'\n'> <'\t(\n'> <'\t\tcd test_wc &&\n'> <'\t\tsvn_cmd propset svn:eol-style CR empty &&\n'> <'\t\tsvn_cmd propset svn:eol-style CR crlf &&\n'> <'\t\tsvn_cmd propset svn:eol-style CR ne_crlf &&\n'> <'\t\tsvn_cmd commit -m "propset CR on crlf files"\n'> <'\t )\n'> ) } ) (C {(test_expect_success)} {(SQ <'fetch and pull latest from svn and checkout a new wc'>)} { (SQ <'git svn fetch &&\n'> <'\t git pull . remotes/git-svn &&\n'> <'\t svn_cmd co "$svnrepo" new_wc'> ) } ) (ForEach iter_name: i iter_words: [ {(crlf)} {(ne_crlf)} {(lf)} {(ne_lf)} {(cr)} {(ne_cr)} {(empty_cr)} {(empty_lf)} {(empty)} {(empty_crlf)} ] do_arg_iter: F body: (DoGroup children: [ (C {(test_expect_success)} {(DQ ('Comparing ') ($ VSub_Name '$i'))} {(DQ ('cmp ') ($ VSub_Name '$i') (' new_wc/') ($ VSub_Name '$i'))} ) ] spids: [525 542] ) spids: [504 16777215] ) (C {(cd)} {(test_wc)}) (SimpleCommand words: [{(printf)} {(SQ <'$Id$\\rHello\\rWorld\\r'>)}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(cr)})] ) (SimpleCommand words: [{(printf)} {(SQ <'$Id$\\rHello\\rWorld'>)}] redirects: [(Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(ne_cr)})] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_cr spids:[573]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(printf)} {(SQ <'$Id$\\r\\nHello\\r\\nWorld\\r\\n'>)}) (C {(git)} {(hash-object)} {(--stdin)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [574 588] ) } spids: [573] ) ] spids: [573] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:a_ne_cr spids:[591]) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(printf)} {(SQ <'$Id$\\r\\nHello\\r\\nWorld'>)}) (C {(git)} {(hash-object)} {(--stdin)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [592 606] ) } spids: [591] ) ] spids: [591] ) (C {(test_expect_success)} {(SQ <'Set CRLF on cr files'>)} { (SQ <'svn_cmd propset svn:eol-style CRLF cr &&\n'> <'\t svn_cmd propset svn:eol-style CRLF ne_cr &&\n'> <'\t svn_cmd propset svn:keywords Id cr &&\n'> <'\t svn_cmd propset svn:keywords Id ne_cr &&\n'> <'\t svn_cmd commit -m "propset CRLF on cr files"'> ) } ) (C {(cd)} {(..)}) (C {(test_expect_success)} {(SQ <'fetch and pull latest from svn'>)} {(SQ <'git svn fetch && git pull . remotes/git-svn'>)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:b_cr spids:[642]) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(cr)})]) left_token: <Left_CommandSub '$('> spids: [644 650] ) ) } spids: [642] ) ] spids: [642] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:b_ne_cr spids:[653]) op: Equal rhs: { (DQ (CommandSubPart command_list: (CommandList children:[(C {(git)} {(hash-object)} {(ne_cr)})]) left_token: <Left_CommandSub '$('> spids: [655 661] ) ) } spids: [653] ) ] spids: [653] ) (C {(test_expect_success)} {(SQ <'CRLF + $Id$'>)} {(DQ ("test '") ($ VSub_Name '$a_cr') ("' = '") ($ VSub_Name '$b_cr') ("'"))} ) (C {(test_expect_success)} {(SQ <'CRLF + $Id$ (no newline)'>)} {(DQ ("test '") ($ VSub_Name '$a_ne_cr') ("' = '") ($ VSub_Name '$b_ne_cr') ("'"))} ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(show-ignore.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 716 stdin_parts: [ ('\n') ('# /\n') ('/no-such-file*\n') ('\n') ('# /deeply/\n') ('/deeply/no-such-file*\n') ('\n') ('# /deeply/nested/\n') ('/deeply/nested/no-such-file*\n') ('\n') ('# /deeply/nested/directory/\n') ('/deeply/nested/directory/no-such-file*\n') ] ) ] ) (C {(test_expect_success)} {(SQ <'test show-ignore'>)} { (DQ ('\n') ('\t(\n') ('\t\tcd test_wc &&\n') ('\t\tmkdir -p deeply/nested/directory &&\n') ('\t\ttouch deeply/nested/directory/.keep &&\n') ('\t\tsvn_cmd add deeply &&\n') ('\t\tsvn_cmd up &&\n') ("\t\tsvn_cmd propset -R svn:ignore '\n") ('no-such-file*\n') ("' .\n") ("\t\tsvn_cmd commit -m 'propset svn:ignore'\n") ('\t) &&\n') ('\tgit svn show-ignore > show-ignore.got &&\n') ('\tcmp show-ignore.expect show-ignore.got\n') ) } ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(create-ignore.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 752 stdin_parts: [('/no-such-file*\n')] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(create-ignore-index.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 767 stdin_parts: [ ('100644 8c52e5dfcd0a8b6b6bcfe6b41b89bcbf493718a5 0\t.gitignore\n') ('100644 8c52e5dfcd0a8b6b6bcfe6b41b89bcbf493718a5 0\tdeeply/.gitignore\n') ('100644 8c52e5dfcd0a8b6b6bcfe6b41b89bcbf493718a5 0\tdeeply/nested/.gitignore\n') ( '100644 8c52e5dfcd0a8b6b6bcfe6b41b89bcbf493718a5 0\tdeeply/nested/directory/.gitignore\n' ) ] ) ] ) (C {(test_expect_success)} {(SQ <'test create-ignore'>)} { (DQ ('\n') ('\tgit svn fetch && git pull . remotes/git-svn &&\n') ('\tgit svn create-ignore &&\n') ('\tcmp ./.gitignore create-ignore.expect &&\n') ('\tcmp ./deeply/.gitignore create-ignore.expect &&\n') ('\tcmp ./deeply/nested/.gitignore create-ignore.expect &&\n') ('\tcmp ./deeply/nested/directory/.gitignore create-ignore.expect &&\n') ('\tgit ls-files -s | grep gitignore | cmp - create-ignore-index.expect\n') ('\t') ) } ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(prop.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 800 stdin_parts: [('\n') ('no-such-file*\n') ('\n')] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(prop2.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 811 stdin_parts: [('8\n')] ) ] ) (C {(test_expect_success)} {(SQ <'test propget'>)} { (DQ ('\n') ('\tgit svn propget svn:ignore . | cmp - prop.expect &&\n') ('\tcd deeply &&\n') ('\tgit svn propget svn:ignore . | cmp - ../prop.expect &&\n') ('\tgit svn propget svn:entry:committed-rev nested/directory/.keep ') ('\t | cmp - ../prop2.expect &&\n') ('\tgit svn propget svn:ignore .. | cmp - ../prop.expect &&\n') ('\tgit svn propget svn:ignore nested/ | cmp - ../prop.expect &&\n') ('\tgit svn propget svn:ignore ./nested | cmp - ../prop.expect &&\n') ('\tgit svn propget svn:ignore .././deeply/nested | cmp - ../prop.expect\n') ('\t') ) } ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(prop.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 859 stdin_parts: [ ("Properties on '.':\n") (' svn:entry:committed-date\n') (' svn:entry:committed-rev\n') (' svn:entry:last-author\n') (' svn:entry:uuid\n') (' svn:ignore\n') ] ) ] ) (SimpleCommand words: [{(cat)}] redirects: [ (Redir op:<Redir_Great '>'> fd:16777215 arg_word:{(prop2.expect)}) (HereDoc op: <Redir_DLess '<<'> fd: 16777215 here_begin: {(EscapedLiteralPart token:<Lit_EscapedChar '\\E'>) (OF)} here_end_span_id: 874 stdin_parts: [ ("Properties on 'nested/directory/.keep':\n") (' svn:entry:committed-date\n') (' svn:entry:committed-rev\n') (' svn:entry:last-author\n') (' svn:entry:uuid\n') ] ) ] ) (C {(test_expect_success)} {(SQ <'test proplist'>)} { (DQ ('\n') ('\tgit svn proplist . | cmp - prop.expect &&\n') ('\tgit svn proplist nested/directory/.keep | cmp - prop2.expect\n') ('\t') ) } ) (C {(test_done)}) ] )