(command.CommandList
  children: [
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_Pound '#'))} 
                      {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <1>)} {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.Simple
              words: [
                {<echo>}
                {
                  (DQ <'Usage: '> 
                    (command_sub
                      left_token: <Id.Left_Backtick '`'>
                      child: (C {<basename>} {($ Id.VSub_Number 0)})
                      right: <Id.Backtick_Right '`'>
                    ) <' \'character\''>
                  )
                }
              ]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              more_env: []
              do_fork: T
            )
            (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
          ]
          spids: [48 66]
        )
      ]
      else_action: []
      redirects: []
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.Pipeline
                      children: [
                        (C {<echo>} {($ Id.VSub_DollarName LANG)})
                        (C {<grep>} {<-qi>} {(SQ <'UTF.*8'>)})
                      ]
                      negated: F
                      stderr_indices: []
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'lang='> name:lang)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_Backtick '`'>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<echo>} {($ Id.VSub_DollarName LANG)})
                              (C {<sed>} {(SQ <'s/\\(.._..\\).*/\\1/'>)})
                            ]
                            negated: F
                            stderr_indices: []
                          )
                        right: <Id.Backtick_Right '`'>
                      )
                    }
                  spids: [114]
                )
              ]
              redirects: []
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'codeset='> name:codeset)
                  op: assign_op.Equal
                  rhs: {<UTF-8>}
                  spids: [138]
                )
              ]
              redirects: []
            )
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'character='> name:character)
                  op: assign_op.Equal
                  rhs: {(DQ ($ Id.VSub_Number 1))}
                  spids: [142]
                )
              ]
              redirects: []
            )
          ]
          spids: [94 111]
        )
      ]
      else_action: [
        (command.Simple
          words: [{<echo>} {(DQ <'Sorry, only UTF-8 is supported at present'>)}]
          redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
          more_env: []
          do_fork: T
        )
        (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
      ]
      redirects: []
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'dir='> name:dir)
          op: assign_op.Equal
          rhs: {<'/usr/share/X11/locale'>}
          spids: [175]
        )
      ]
      redirects: []
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-d>} {(DQ ($ Id.VSub_DollarName dir))} 
                      {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'dir='> name:dir)
                  op: assign_op.Equal
                  rhs: {<'/usr/X11R6/lib/X11/locale'>}
                  spids: [199]
                )
              ]
              redirects: []
            )
          ]
          spids: [181 196]
        )
      ]
      else_action: []
      redirects: []
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-f>} 
                      {(DQ ($ Id.VSub_DollarName dir) <'/locale.dir'>)} {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.Simple
              words: [{<echo>} {(DQ <'Sorry, couldn\'t find your X windows locale data'>)}]
              redirects: [(redir op:<Id.Redir_GreatAnd '>&'> loc:(redir_loc.Fd fd:1) arg:{<2>})]
              more_env: []
              do_fork: T
            )
            (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})
          ]
          spids: [207 223]
        )
      ]
      else_action: []
      redirects: []
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'dir='> name:dir)
          op: assign_op.Equal
          rhs: 
            {
              (DQ ($ Id.VSub_DollarName dir) <'/'> 
                (command_sub
                  left_token: <Id.Left_Backtick '`'>
                  child: 
                    (command.Simple
                      words: [
                        {<sed>}
                        {<-n>}
                        {
                          (DQ <'s#'> <Id.Lit_BadBackslash '\\'> <'([^/]*'> <Id.Lit_BadBackslash '\\'> 
                            <')/.*:.*'> ($ Id.VSub_DollarName lang) <.> ($ Id.VSub_DollarName codeset) <'#'> <Id.Lit_BadBackslash '\\'> <'1#p'>
                          )
                        }
                      ]
                      redirects: [
                        (redir
                          op: <Id.Redir_Less '<'>
                          loc: (redir_loc.Fd fd:0)
                          arg: {($ Id.VSub_DollarName dir) <'/locale.dir'>}
                        )
                      ]
                      more_env: []
                      do_fork: T
                    )
                  right: <Id.Backtick_Right '`'>
                )
              )
            }
          spids: [243]
        )
      ]
      redirects: []
    )
    (command.Simple
      words: [
        {<grep>}
        {<-F>}
        {
          (DQ (word_part.EscapedLiteral token:<Id.Lit_EscapedChar '\\"'> ch:'"') 
            ($ Id.VSub_DollarName character) (word_part.EscapedLiteral token:<Id.Lit_EscapedChar '\\"'> ch:'"')
          )
        }
        {($ Id.VSub_DollarName dir) <'/Compose'>}
      ]
      redirects: []
      more_env: [(env_pair name:LANG val:{<C>} spids:[285])]
      do_fork: T
    )
  ]
)