(command.CommandList children: [ (command.ShAssignment left: <Id.Lit_VarLike 'PERMS='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'PERMS='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'PERMS='> name:PERMS) op: assign_op.Equal rhs: {($ Id.VSub_Number 1)} ) ] redirects: [] ) (command.Simple blame_tok:<shift> more_env:[] words:[{<shift>}] redirects:[] do_fork:T) (command.ShAssignment left: <Id.Lit_VarLike 'ARGS='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'ARGS='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'ARGS='> name:ARGS) op: assign_op.Equal rhs: {(DQ )} ) ] redirects: [] ) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands: [ (command.Sentence child: (command.Simple blame_tok: <Id.Lit_LBracket '['> more_env: [] words: [ {<Id.Lit_LBracket '['>} {($ Id.VSub_Pound '#')} {<-gt>} {<1>} {<Id.Lit_RBracket ']'>} ] redirects: [] do_fork: T ) terminator: <Id.Op_Semi _> ) ] ) body: (command.DoGroup left: <Id.KW_Do do> children: [ (command.ShAssignment left: <Id.Lit_VarLike 'ARGS='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'ARGS='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'ARGS='> name:ARGS) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName ARGS) <' '> ($ Id.VSub_Number 1))} ) ] redirects: [] ) (command.Simple blame_tok: <shift> more_env: [] words: [{<shift>}] redirects: [] do_fork: T ) ] right: <Id.KW_Done done> ) redirects: [] ) (command.ShAssignment left: <Id.Lit_VarLike 'DEST='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'DEST='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'DEST='> name:DEST) op: assign_op.Equal rhs: {($ Id.VSub_Number 1)} ) ] redirects: [] ) (command.ForEach keyword: <Id.KW_For for> iter_names: [SRC] iterable: (for_iter.Words words:[{($ Id.VSub_DollarName ARGS)}]) semi_tok: <Id.Op_Semi _> body: (command.DoGroup left: <Id.KW_Do do> children: [ (command.Simple blame_tok: <cp> more_env: [] words: [{<cp>} {<-a>} {($ Id.VSub_DollarName SRC)} {($ Id.VSub_DollarName DEST)}] redirects: [] do_fork: T ) (command.If if_kw: <Id.KW_If if> arms: [ (IfArm keyword: <Id.KW_If if> cond: (condition.Shell commands: [ (command.Sentence child: (command.Simple blame_tok: <Id.Lit_LBracket '['> more_env: [] words: [ {<Id.Lit_LBracket '['>} {<-d>} {(DQ ($ Id.VSub_DollarName DEST))} {<Id.Lit_RBracket ']'>} ] redirects: [] do_fork: T ) terminator: <Id.Op_Semi _> ) ] ) then_kw: <Id.KW_Then then> action: [ (command.ShAssignment left: <Id.Lit_VarLike 'DESTFILE='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'DESTFILE='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'DESTFILE='> name:DESTFILE) op: assign_op.Equal rhs: { (DQ ($ Id.VSub_DollarName DEST) <'/'> (CommandSub left_token: <Id.Left_DollarParen '$('> child: (command.Simple blame_tok: <basename> more_env: [] words: [{<basename>} {(DQ ($ Id.VSub_DollarName SRC))}] redirects: [] do_fork: T ) right: <Id.Eof_RParen _> ) ) } ) ] redirects: [] ) ] spids: [78 91] ) ] else_kw: <Id.KW_Else else> else_action: [ (command.ShAssignment left: <Id.Lit_VarLike 'DESTFILE='> pairs: [ (AssignPair left: <Id.Lit_VarLike 'DESTFILE='> lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'DESTFILE='> name:DESTFILE) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName DEST))} ) ] redirects: [] ) ] fi_kw: <Id.KW_Fi fi> redirects: [] ) (command.Simple blame_tok: <chmod> more_env: [] words: [{<chmod>} {($ Id.VSub_DollarName PERMS)} {($ Id.VSub_DollarName DESTFILE)}] redirects: [(Redir op:<Id.Redir_Great '2>'> loc:(redir_loc.Fd fd:2) arg:{<'/dev/null'>})] do_fork: T ) ] right: <Id.KW_Done done> ) redirects: [] ) (command.ControlFlow keyword:<Id.ControlFlow_Exit exit> arg_word:{<0>}) ] )