(command.CommandList
  children: [
    (C {<readonly>} {<Id.Lit_VarLike 'file='> (DQ ($ Id.VSub_Number '$1'))})
    (C {<readonly>} 
      {<Id.Lit_VarLike 'name='> 
        (DQ 
          (command_sub
            left_token: <Id.Left_DollarParen '$('>
            child: (C {<basename>} {(DQ ($ Id.VSub_Number '$1'))})
          )
        )
      }
    )
    (C {<readonly>} 
      {<Id.Lit_VarLike 'dir='> 
        (DQ 
          (command_sub
            left_token: <Id.Left_DollarParen '$('>
            child: (C {<dirname>} {(DQ ($ Id.VSub_Number '$1'))})
          )
        )
      }
    )
    (command.Case
      to_match: {($ Id.VSub_DollarName '$file')}
      arms: [
        (case_arm
          pat_list: [
            {<AUTHORS>}
            {<CONTRIBUTORS>}
            {<WORKSPACE>}
            {<'third_party/'> <Id.Lit_Star '*'>}
            {<'tools/'> <Id.Lit_Star '*'>}
            {<Id.Lit_Star '*'> <.md>}
            {<BUILD>}
            {<Id.Lit_Star '*'> <'/BUILD'>}
            {<Id.Lit_Star '*'> <'/testdata/'> <Id.Lit_Star '*'>}
            {<Id.Lit_Star '*'> <.yaml>}
            {<Id.Lit_Star '*'> <.json>}
            {<Id.Lit_Star '*'> <.html>}
            {<Id.Lit_Star '*'> <.pb.go>}
            {<.arclint>}
            {<.gitignore>}
            {<Id.Lit_Star '*'> <'/.gitignore'>}
            {<.arcconfig>}
            {<Id.Lit_Star '*'> <'/__phutil_'> <Id.Lit_Star '*'>}
            {<Id.Lit_Star '*'> <.bzl>}
            {<.kythe>}
            {<'kythe/web/site/'> <Id.Lit_Star '*'>}
          ]
          spids: [113 169 172 -1]
        )
        (case_arm
          pat_list: [{<Id.Lit_Star '*'> <.sh>} {<Id.Lit_Star '*'> <.bash>}]
          action: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (command.AndOr
                              ops: [Id.Op_DAmp]
                              children: [
                                (command.Simple
                                  words: [{<command>} {<-v>} {<shellcheck>}]
                                  redirects: [
                                    (redir
                                      op: <Id.Redir_AndGreat '&>'>
                                      loc: (redir_loc.Fd fd:1)
                                      arg: {<'/dev/null'>}
                                    )
                                  ]
                                  do_fork: T
                                )
                                (command.Simple
                                  words: [{<command>} {<-v>} {<jq>}]
                                  redirects: [
                                    (redir
                                      op: <Id.Redir_AndGreat '&>'>
                                      loc: (redir_loc.Fd fd:1)
                                      arg: {<'/dev/null'>}
                                    )
                                  ]
                                  do_fork: T
                                )
                              ]
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (command.Pipeline
                      children: [
                        (C {<shellcheck>} {<-f>} {<json>} {(DQ ($ Id.VSub_DollarName '$file'))})
                        (C {<jq>} {<-r>} 
                          {
                            (SQ 
                              <
'.[] | "shellcheck::" + (if .level == "info" then "advice" else .level end) + ":" + (.line | tostring) + " " + .message'
                              >
                            )
                          }
                        )
                      ]
                      negated: F
                    )
                  ]
                  spids: [186 209]
                )
              ]
            )
          ]
          spids: [178 183 237 -1]
        )
        (case_arm
          pat_list: [{<Id.Lit_Star '*'>}]
          action: [
            (command.If
              arms: [
                (if_arm
                  cond: 
                    (condition.Shell
                      commands: [
                        (command.Sentence
                          child: 
                            (command.Pipeline
                              children: [
                                (C {<grep>} {<-q>} 
                                  {(SQ <'Copyright 201[4-9] Google Inc. All rights reserved.'>)} {(DQ ($ Id.VSub_DollarName '$file'))}
                                )
                              ]
                              negated: T
                            )
                          terminator: <Id.Op_Semi _>
                        )
                      ]
                    )
                  action: [
                    (C {<echo>} {(SQ <'copyright header::error:1 File missing copyright header'>)})
                  ]
                  spids: [244 261]
                )
              ]
            )
          ]
          spids: [240 241 273 -1]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.Simple
                      words: [{<grep>} {<-q>} {<Id.Lit_LBracket '['> <A-Z> <Id.Lit_RBracket ']'>}]
                      redirects: [
                        (redir
                          op: <Id.Redir_TLess '<<<'>
                          loc: (redir_loc.Fd fd:0)
                          arg: {(DQ ($ Id.VSub_DollarName '$dir'))}
                        )
                      ]
                      do_fork: T
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (C {<echo>} 
              {
                (DQ <'case-insensitivity::error:1 '> ($ Id.VSub_DollarName '$dir') 
                  <' directory contains an uppercase letter'>
                )
              }
            )
          ]
          spids: [281 297]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.DBracket
                      expr: 
                        (bool_expr.Binary
                          op_id: Id.BoolBinary_gt
                          left: 
                            {
                              (command_sub
                                left_token: <Id.Left_DollarParen '$('>
                                child: 
                                  (command.Pipeline
                                    children: [
                                      (C {<find>} {(DQ ($ Id.VSub_DollarName '$dir'))} {<-maxdepth>} 
                                        {<0>} {<-iname>} {(DQ ($ Id.VSub_DollarName '$name'))}
                                      )
                                      (C {<wc>} {<-l>})
                                    ]
                                    negated: F
                                  )
                              )
                            }
                          right: {<1>}
                        )
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (C {<echo>} 
              {
                (DQ <'case-insensitivity::error:1 '> ($ Id.VSub_DollarName '$name') 
                  <' filename clashes on case-insensitive file systems'>
                )
              }
            )
          ]
          spids: [310 345]
        )
      ]
    )
  ]
)