(command.CommandList
  children: [
    (command.ShFunction
      name: printname
      body: 
        (BraceGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:NAME)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_Number '$1')}
                  spids: [18]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:save_IFS)
                  op: assign_op.Equal
                  rhs: {($ Id.VSub_DollarName '$IFS')}
                  spids: [22]
                )
              ]
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:IFS)
                  op: assign_op.Equal
                  rhs: {<'/'>}
                  spids: [26]
                )
              ]
            )
            (C {<set>} {<-->} 
              {
                (command_sub
                  left_token: <Id.Left_Backtick '`'>
                  child: (C {<echo>} {(DQ ($ Id.VSub_DollarName '$NAME'))})
                )
              }
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:IFS)
                  op: assign_op.Equal
                  rhs: {(DQ ($ Id.VSub_DollarName '$save_IFS'))}
                  spids: [45]
                )
              ]
            )
            (command.WhileUntil
              keyword: <Id.KW_While while>
              cond: 
                (condition.Shell
                  commands: [
                    (command.Sentence
                      child: 
                        (C {<Id.Lit_LBracket '['>} {($ Id.VSub_Pound '$#')} {<-ge>} {<1>} 
                          {<Id.Lit_RBracket ']'>}
                        )
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
              body: 
                (command.DoGroup
                  children: [
                    (command.If
                      arms: [
                        (if_arm
                          cond: 
                            (condition.Shell
                              commands: [
                                (command.Sentence
                                  child: 
                                    (C {<Id.Lit_LBracket '['>} {(DQ <x> ($ Id.VSub_Number '$1'))} 
                                      {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <x>)} {<Id.Lit_RBracket ']'>}
                                    )
                                  terminator: <Id.Op_Semi _>
                                )
                              ]
                            )
                          action: [(C {<echo>} {(DQ <'D0755 0 '> ($ Id.VSub_Number '$1'))})]
                          spids: [68 87]
                        )
                      ]
                    )
                    (command.Sentence
                      child: (C {<shift>})
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                )
            )
          ]
        )
    )
    (command.WhileUntil
      keyword: <Id.KW_While while>
      cond: 
        (condition.Shell
          commands: [
            (command.Sentence
              child: 
                (C {<test>} {(DQ <x> ($ Id.VSub_Number '$1'))} {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} 
                  {(DQ <x>)}
                )
              terminator: <Id.Op_Semi _>
            )
          ]
        )
      body: 
        (command.DoGroup
          children: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:arg)
                  op: assign_op.Equal
                  rhs: {(DQ ($ Id.VSub_Number '$1'))}
                  spids: [133]
                )
              ]
            )
            (C {<shift>})
          ]
        )
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:BAD)
          op: assign_op.Equal
          rhs: {(DQ <'../../../../../../../../../../../../../'> (${ Id.VSub_Name DIR) <'/dotpathdir'>)}
          spids: [144]
        )
      ]
    )
    (command.Case
      to_match: {(DQ ($ Id.VSub_DollarName '$SCPTESTMODE'))}
      arms: [
        (case_arm
          pat_list: [{<badserver_0>}]
          action: [
            (C {<echo>} {(DQ <'D0755 0 /'> (${ Id.VSub_Name DIR) <'/rootpathdir'>)})
            (C {<echo>} {(DQ <'C755 2 rootpathfile'>)})
            (C {<echo>} {(DQ <X>)})
          ]
          spids: [162 163 191 -1]
        )
        (case_arm
          pat_list: [{<badserver_1>}]
          action: [
            (C {<echo>} {(DQ <'D0755 0 '> ($ Id.VSub_DollarName '$BAD'))})
            (C {<echo>} {(DQ <'C755 2 file'>)})
            (C {<echo>} {(DQ <X>)})
          ]
          spids: [193 194 219 -1]
        )
        (case_arm
          pat_list: [{<badserver_2>}]
          action: [
            (C {<echo>} {(DQ <'D0755 0 '> ($ Id.VSub_DollarName '$BAD'))})
            (C {<echo>} {(DQ <'C755 2 file'>)})
            (C {<echo>} {(DQ <X>)})
          ]
          spids: [221 222 247 -1]
        )
        (case_arm
          pat_list: [{<badserver_3>}]
          action: [
            (C {<printname>} {($ Id.VSub_DollarName '$BAD')})
            (C {<echo>} {(DQ <'C755 2 file'>)})
            (C {<echo>} {(DQ <X>)})
          ]
          spids: [249 250 272 -1]
        )
        (case_arm
          pat_list: [{<badserver_4>}]
          action: [
            (C {<printname>} {($ Id.VSub_DollarName '$BAD')})
            (C {<echo>} {(DQ <'D0755 0 ..'>)})
            (C {<echo>} {(DQ <'C755 2 file'>)})
            (C {<echo>} {(DQ <X>)})
          ]
          spids: [274 275 304 -1]
        )
        (case_arm
          pat_list: [{<Id.Lit_Star '*'>}]
          action: [
            (C {<set>} {<-->} {($ Id.VSub_DollarName '$arg')})
            (C {<shift>})
            (C {<exec>} {($ Id.VSub_DollarName '$SCP')} {(DQ ($ Id.VSub_At '$@'))})
          ]
          spids: [306 307 329 -1]
        )
      ]
    )
  ]
)