(command.CommandList
  children: [
    (command.AndOr
      ops: [Id.Op_DPipe]
      children: [
        (command.Simple
          words: [{(which)} {(grub-editenv)}]
          redirects: [
            (redir.Redir
              op: (Token id:Id.Redir_Great val:'>' span_id:41)
              fd: -1
              arg_word: {(/dev/null)}
            )
            (redir.Redir
              op: (Token id:Id.Redir_GreatAnd val:'2>&' span_id:44)
              fd: 2
              arg_word: {(1)}
            )
          ]
        )
        (command.ControlFlow
          token: (Token id:Id.ControlFlow_Exit val:exit span_id:49)
          arg_word: {(0)}
        )
      ]
    )
    (C {(.)} {(/lib/init/vars.sh)})
    (C {(.)} {(/lib/lsb/init-functions)})
    (command.Case
      to_match: {($ Id.VSub_Number '$1')}
      arms: [
        (case_arm
          pat_list: [{(start)} {(restart)} {(force-reload)}]
          action: [
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                  {(Id.KW_Bang '!') (Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                )
                (C {(log_action_msg)} {(DQ ('Recording successful boot for GRUB'))})
              ]
            )
            (command.AndOr
              ops: [Id.Op_DPipe]
              children: [
                (C {(Id.Lit_LBracket '[')} {(-s)} {(/boot/grub/grubenv)} {(Id.Lit_RBracket ']')})
                (C {(rm)} {(-f)} {(/boot/grub/grubenv)})
              ]
            )
            (C {(mkdir)} {(-p)} {(/boot/grub)})
            (C {(grub-editenv)} {(/boot/grub/grubenv)} {(unset)} {(recordfail)})
            (command.AndOr
              ops: [Id.Op_DAmp]
              children: [
                (C {(Id.Lit_LBracket '[')} {(DQ ($ Id.VSub_DollarName '$VERBOSE'))} 
                  {(Id.KW_Bang '!') (Id.Lit_Equals '=')} {(no)} {(Id.Lit_RBracket ']')}
                )
                (C {(log_end_msg)} {($ Id.VSub_QMark '$?')})
              ]
            )
          ]
          spids: [80 85 163 -1]
        )
        (case_arm pat_list:[{(stop)}] spids:[166 167 170 -1])
        (case_arm
          pat_list: [{(status)}]
          action: [
            (command.ControlFlow
              token: (Token id:Id.ControlFlow_Exit val:exit span_id:177)
              arg_word: {(0)}
            )
          ]
          spids: [173 174 182 -1]
        )
        (case_arm
          pat_list: [{(Id.Lit_Star '*')}]
          action: [
            (command.Simple
              words: [
                {(echo)}
                {
                  (DQ ('Usage: ') ($ Id.VSub_Number '$0') (' {start|stop|status|restart|force-reload}'))
                }
              ]
              redirects: [
                (redir.Redir
                  op: (Token id:Id.Redir_GreatAnd val:'>&' span_id:197)
                  fd: -1
                  arg_word: {(2)}
                )
              ]
            )
            (command.ControlFlow
              token: (Token id:Id.ControlFlow_Exit val:exit span_id:201)
              arg_word: {(3)}
            )
          ]
          spids: [185 186 206 -1]
        )
      ]
    )
    (command.ControlFlow token:(Token id:Id.ControlFlow_Exit val:exit span_id:211) arg_word:{(0)})
  ]
)