(command.CommandList
  children: [
    (command.ShFunction
      name: gem_install
      body: 
        (command.BraceGroup
          children: [
            (command.If
              arms: [
                (if_arm
                  cond: [
                    (command.Sentence
                      child: 
                        (command.Pipeline
                          children: [
                            (C {<gem>} {<list>})
                            (C {<grep>} {<-e>} {(DQ <'^'> ($ Id.VSub_Number '$1') <' '>)})
                          ]
                          negated: T
                        )
                      terminator: <Id.Op_Semi _>
                    )
                  ]
                  action: [
                    (C {<sudo>} {<gem>} {<install>} {($ Id.VSub_DollarName '$i')} {<--no-ri>} {<--no-rdoc>})
                  ]
                  spids: [11 32]
                )
              ]
            )
          ]
        )
    )
    (C {<Id.KW_Set set>} {<-x>})
    (C {<gem_install>} {<foodcritic>})
    (C {<gem_install>} {<tailor>})
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:TOP)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_Backtick '`'>
                command_list: 
                  (command.CommandList
                    children: [(C {<git>} {<rev-parse>} {<--show-toplevel>})]
                  )
              )
            }
          spids: [66]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: [
            (command.Sentence
              child: 
                (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-L>} 
                  {(DQ ($ Id.VSub_DollarName '$TOP') </.git/hooks/pre-commit>)} {<Id.Lit_RBracket ']'>}
                )
              terminator: <Id.Op_Semi _>
            )
          ]
          action: [
            (C {<ln>} {<-s>} {<../../tests/pre-commit>} 
              {(DQ ($ Id.VSub_DollarName '$TOP') </.git/hooks/pre-commit>)}
            )
          ]
          spids: [77 93]
        )
      ]
    )
  ]
)