(command.CommandList
  children: [
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:CONFFILE)
          op: assign_op.Equal
          rhs: {(word_part.TildeSub token:<Id.Lit_TildeLike '~'>) <'/.appprc'>}
          spids: [20]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:SEP)
          op: assign_op.Equal
          rhs: {(DQ <'-=-=-=-=-=-=-=-=-=# Don\'t remove this line #=-=-=-=-=-=-=-=-=-'>)}
          spids: [25]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {<-e>} {(DQ ($ Id.VSub_DollarName '$CONFFILE'))} 
                      {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.ShAssignment
              pairs: [
                (assign_pair
                  lhs: (sh_lhs_expr.Name name:LAST_DIR)
                  op: assign_op.Equal
                  rhs: 
                    {
                      (command_sub
                        left_token: <Id.Left_DollarParen '$('>
                        child: 
                          (command.Pipeline
                            children: [
                              (C {<grep>} {<-m>} {<1>} {(DQ <'^LAST_DIR='>)} 
                                {(DQ (${ Id.VSub_Name CONFFILE))}
                              )
                              (C {<sed>} {<-e>} {(SQ <'s/^LAST_DIR=//'>)})
                            ]
                            negated: F
                          )
                      )
                    }
                  spids: [47]
                )
              ]
            )
            (C {<cd>} {(DQ (${ Id.VSub_Name LAST_DIR))})
          ]
          spids: [30 44]
        )
      ]
      else_action: [
        (command.Simple
          words: [{<cd>}]
          redirects: [(redir op:<Id.Redir_Great '>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})]
          do_fork: T
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:PATCH)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: (C {<zenity>} {<--file-selection>})
              )
            }
          spids: [95]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_QMark '$?'))} 
                      {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <0>)} {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [(command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>})]
          spids: [103 122]
        )
      ]
    )
    (command.Simple
      words: [{<cd>} {<->}]
      redirects: [(redir op:<Id.Redir_Great '>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})]
      do_fork: T
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:SUBJECT)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: (C {<sed>} {<-n>} {<-e>} {(SQ <'/^Subject: /p'>)} {(DQ (${ Id.VSub_Name PATCH))})
              )
            }
          spids: [145]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:HEADERS)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: 
                  (C {<sed>} {<-e>} {(SQ <'/^'>) (DQ (${ Id.VSub_Name SEP)) (SQ <'$/,$d'>)} 
                    {($ Id.VSub_Number '$1')}
                  )
              )
            }
          spids: [164]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:BODY)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: 
                  (C {<sed>} {<-e>} {(DQ <'1,/'> (${ Id.VSub_Name SEP) <'/d'>)} {($ Id.VSub_Number '$1')})
              )
            }
          spids: [185]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:CMT_MSG)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: 
                  (C {<sed>} {<-e>} {(SQ <'1,/^$/d'>)} {<-e>} {(SQ <'/^---$/,$d'>)} 
                    {(DQ (${ Id.VSub_Name PATCH))}
                  )
              )
            }
          spids: [202]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:DIFF)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: (C {<sed>} {<-e>} {(SQ <'1,/^---$/d'>)} {(DQ (${ Id.VSub_Name PATCH))})
              )
            }
          spids: [225]
        )
      ]
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:CCS)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: 
                  (command.Pipeline
                    children: [
                      (C {<echo>} {<-e>} 
                        {
                          (DQ ($ Id.VSub_DollarName '$CMT_MSG') <Id.Lit_BadBackslash '\\'> <n> 
                            ($ Id.VSub_DollarName '$HEADERS')
                          )
                        }
                      )
                      (C {<sed>} {<-n>} {<-e>} {(SQ <'s/^Cc: \\(.*\\)$/\\1,/gp'>)} {<-e>} 
                        {(SQ <'s/^Signed-off-by: \\(.*\\)/\\1,/gp'>)}
                      )
                    ]
                    negated: F
                  )
              )
            }
          spids: [243]
        )
      ]
    )
    (command.Simple
      words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$SUBJECT'))}]
      redirects: [(redir op:<Id.Redir_Great '>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})]
      do_fork: T
    )
    (command.Simple
      words: [{<echo>} {(DQ <'Cc: '> ($ Id.VSub_DollarName '$CCS'))}]
      redirects: [
        (redir op:<Id.Redir_DGreat '>>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})
      ]
      do_fork: T
    )
    (command.Pipeline
      children: [
        (C {<echo>} {(DQ ($ Id.VSub_DollarName '$HEADERS'))})
        (command.Simple
          words: [{<sed>} {<-e>} {(SQ <'/^Subject: /d'>)} {<-e>} {(SQ <'/^Cc: /d'>)}]
          redirects: [
            (redir
              op: <Id.Redir_DGreat '>>'>
              loc: (redir_loc.Fd fd:1)
              arg: {($ Id.VSub_Number '$1')}
            )
          ]
          do_fork: T
        )
      ]
      negated: F
    )
    (command.Simple
      words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$SEP'))}]
      redirects: [
        (redir op:<Id.Redir_DGreat '>>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})
      ]
      do_fork: T
    )
    (command.Simple
      words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$CMT_MSG'))}]
      redirects: [
        (redir op:<Id.Redir_DGreat '>>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})
      ]
      do_fork: T
    )
    (command.Simple
      words: [{<echo>} {(DQ <--->)}]
      redirects: [
        (redir op:<Id.Redir_DGreat '>>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})
      ]
      do_fork: T
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {(DQ <x> (${ Id.VSub_Name BODY) <x>)} 
                      {<Id.KW_Bang '!'> <Id.Lit_Equals '='>} {(DQ <xx>)} {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.Simple
              words: [{<echo>}]
              redirects: [
                (redir
                  op: <Id.Redir_DGreat '>>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {($ Id.VSub_Number '$1')}
                )
              ]
              do_fork: T
            )
            (command.Simple
              words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$BODY'))}]
              redirects: [
                (redir
                  op: <Id.Redir_DGreat '>>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {($ Id.VSub_Number '$1')}
                )
              ]
              do_fork: T
            )
            (command.Simple
              words: [{<echo>}]
              redirects: [
                (redir
                  op: <Id.Redir_DGreat '>>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {($ Id.VSub_Number '$1')}
                )
              ]
              do_fork: T
            )
          ]
          spids: [356 379]
        )
      ]
    )
    (command.Simple
      words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$DIFF'))}]
      redirects: [
        (redir op:<Id.Redir_DGreat '>>'> loc:(redir_loc.Fd fd:1) arg:{($ Id.VSub_Number '$1')})
      ]
      do_fork: T
    )
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:LAST_DIR)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: (C {<dirname>} {(DQ (${ Id.VSub_Name PATCH))})
              )
            }
          spids: [419]
        )
      ]
    )
    (command.Simple
      words: [{<grep>} {<-v>} {(DQ <'^LAST_DIR='>)} {(DQ (${ Id.VSub_Name CONFFILE))}]
      redirects: [
        (redir
          op: <Id.Redir_Great '>'>
          loc: (redir_loc.Fd fd:1)
          arg: {(DQ (${ Id.VSub_Name CONFFILE) <_>)}
        )
      ]
      do_fork: T
    )
    (command.Simple
      words: [{<echo>} {(DQ <'LAST_DIR='> (${ Id.VSub_Name LAST_DIR))}]
      redirects: [
        (redir
          op: <Id.Redir_DGreat '>>'>
          loc: (redir_loc.Fd fd:1)
          arg: {(DQ (${ Id.VSub_Name CONFFILE) <_>)}
        )
      ]
      do_fork: T
    )
    (C {<mv>} {(DQ (${ Id.VSub_Name CONFFILE) <_>)} {(DQ (${ Id.VSub_Name CONFFILE))})
  ]
)