(command.CommandList children: [ (command.FuncDef name: relpath body: (command.BraceGroup children: [ (command.AndOr ops: [Op_DAmp Op_DPipe] children: [ (C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-ge)} {(1)} {(Lit_Other ']')}) (C {(Lit_Other '[')} {($ VSub_Pound '$#')} {(-le)} {(2)} {(Lit_Other ']')}) (command.ControlFlow token:<ControlFlow_Return return> arg_word:{(1)}) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:current spids:[51]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Number 2> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {(DQ ($ VSub_Number '$1'))} ) spids: [53 59] ) ) } spids: [51] ) ] spids: [51] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:target spids:[63]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Number 2> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonHyphen arg_word: {(DQ ($ VSub_Number '$1'))} ) spids: [65 71] ) ) } spids: [63] ) ] spids: [63] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(Lit_Other '[')} {(DQ ($ VSub_DollarName '$target'))} {(KW_Bang '!') (Lit_Other '=')} {(.)} {(Lit_Other ']')} ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:target spids:[90]) op: Equal rhs: {(/)} spids: [90] ) ] spids: [90] ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:target spids:[94]) op: Equal rhs: { (DQ (/) (word_part.BracedVarSub token: <VSub_Name target> suffix_op: (suffix_op.StringUnary op_id:VOp1_DPound arg_word:{(Lit_Slash /)}) spids: [97 101] ) ) } spids: [94] ) ] spids: [94] ) (command.AndOr ops: [Op_DPipe] children: [ (C {(Lit_Other '[')} {(DQ ($ VSub_DollarName '$current'))} {(KW_Bang '!') (Lit_Other '=')} {(.)} {(Lit_Other ']')} ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:current spids:[120]) op: Equal rhs: {(/)} spids: [120] ) ] spids: [120] ) ] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:current spids:[124]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Name current> suffix_op: (suffix_op.StringUnary op_id:VTest_ColonEquals arg_word:{(DQ (/))}) spids: [126 132] ) ) } spids: [124] ) ] spids: [124] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:current spids:[136]) op: Equal rhs: { (DQ (/) (word_part.BracedVarSub token: <VSub_Name current> suffix_op: (suffix_op.StringUnary op_id:VOp1_DPound arg_word:{(Lit_Slash /)}) spids: [139 143] ) ) } spids: [136] ) ] spids: [136] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:appendix spids:[147]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Name target> suffix_op: (suffix_op.StringUnary op_id:VOp1_DPound arg_word:{(Lit_Slash /)}) spids: [149 153] ) ) } spids: [147] ) ] spids: [147] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:relative spids:[157]) op: Equal rhs: {(SQ )} spids: [157] ) ] spids: [157] ) (command.WhileUntil keyword: <KW_While while> cond: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:appendix spids:[164]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Name target> suffix_op: (suffix_op.StringUnary op_id: VOp1_Pound arg_word: {(DQ ($ VSub_DollarName '$current')) (Lit_Slash /)} ) spids: [166 173] ) ) } spids: [164] ) ] spids: [164] ) (command.Sentence child: (command.AndOr ops: [Op_DAmp] children: [ (C {(Lit_Other '[')} {(DQ ($ VSub_DollarName '$current'))} {(KW_Bang '!') (Lit_Other '=')} {(SQ </>)} {(Lit_Other ']')} ) (C {(Lit_Other '[')} {(DQ ($ VSub_DollarName '$appendix'))} {(Lit_Other '=')} {(DQ ($ VSub_DollarName '$target'))} {(Lit_Other ']')} ) ] ) terminator: <Op_Semi ';'> ) ] body: (command.DoGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Lit_Other '[')} {(DQ ($ VSub_DollarName '$current'))} {(Lit_Other '=')} {(DQ ($ VSub_DollarName '$appendix'))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:relative spids:[232]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Name relative> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonHyphen arg_word: {(.)} ) spids: [234 238] ) ) } spids: [232] ) ] spids: [232] ) (C {(echo)} { (DQ (word_part.BracedVarSub token: <VSub_Name relative> suffix_op: (suffix_op.StringUnary op_id: VOp1_Pound arg_word: {(Lit_Slash /)} ) spids: [245 249] ) ) } ) (command.ControlFlow token: <ControlFlow_Return return> arg_word: {(0)} ) ] spids: [16777215 229] ) ] spids: [16777215 258] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:current spids:[261]) op: Equal rhs: { (DQ (word_part.BracedVarSub token: <VSub_Name current> suffix_op: (suffix_op.StringUnary op_id: VOp1_Percent arg_word: {(Lit_Slash /) ('*')} ) spids: [263 268] ) ) } spids: [261] ) ] spids: [261] ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:relative spids:[272]) op: Equal rhs: { (DQ ($ VSub_DollarName '$relative') (word_part.BracedVarSub token: <VSub_Name relative> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {(Lit_Slash /)} ) spids: [275 279] ) (..) ) } spids: [272] ) ] spids: [272] ) ] spids: [209 284] ) ) (command.Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (lhs_expr.LhsName name:relative spids:[287]) op: Equal rhs: { (DQ ($ VSub_DollarName '$relative') (word_part.BracedVarSub token: <VSub_Name relative> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: { (word_part.BracedVarSub token: <VSub_Name appendix> suffix_op: (suffix_op.StringUnary op_id: VTest_ColonPlus arg_word: {(Lit_Slash /)} ) spids: [293 297] ) } ) spids: [290 298] ) (word_part.BracedVarSub token: <VSub_Name appendix> suffix_op: (suffix_op.StringUnary op_id:VOp1_Pound arg_word:{(Lit_Slash /)}) spids: [299 303] ) ) } spids: [287] ) ] spids: [287] ) (C {(echo)} {(DQ ($ VSub_DollarName '$relative'))}) ] spids: [19] ) spids: [14 18] ) (C {(relpath)} {(DQ ($ VSub_At '$@'))}) ] )