(command.CommandList
  children: [
    (C {<touch>} {($ Id.VSub_DollarName '$HOME') <'/.utoprc'>})
    (C {<touch>} {($ Id.VSub_DollarName '$HOME') <'/.utop-history'>})
    (command.ShAssignment
      pairs: [
        (assign_pair
          lhs: (sh_lhs_expr.Name name:DIR)
          op: assign_op.Equal
          rhs: 
            {
              (command_sub
                left_token: <Id.Left_DollarParen '$('>
                child: 
                  (command.AndOr
                    ops: [Id.Op_DAmp]
                    children: [
                      (C {<cd>} 
                        {
                          (DQ 
                            (command_sub
                              left_token: <Id.Left_DollarParen '$('>
                              child: 
                                (C {<dirname>} 
                                  {
                                    (DQ 
                                      (braced_var_sub
                                        token: <Id.VSub_Name BASH_SOURCE>
                                        bracket_op: (bracket_op.ArrayIndex expr:{<Id.Lit_Digits 0>})
                                      )
                                    )
                                  }
                                )
                            )
                          )
                        }
                      )
                      (C {<pwd>})
                    ]
                  )
              )
            }
          spids: [49]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-f>} 
                      {($ Id.VSub_DollarName '$HOME') <'/.reasoninit'>} {<Id.Lit_RBracket ']'>}
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.Simple
              words: [
                {<echo>}
                {
                  (DQ <'/* Added by rtop */\n'> <'let () =\n'> 
                    <'  try (Topdirs.dir_directory (Sys.getenv '> (word_part.EscapedLiteral token:<Id.Lit_EscapedChar '\\"'>) <OCAML_TOPLEVEL_PATH> 
                    (word_part.EscapedLiteral token:<Id.Lit_EscapedChar '\\"'>) <')) {\n'> <'  | Not_found => ()\n'> <'  };'>
                  )
                }
              ]
              redirects: [
                (redir
                  op: <Id.Redir_Great '>'>
                  loc: (redir_loc.Fd fd:1)
                  arg: {($ Id.VSub_DollarName '$HOME') <'/.reasoninit'>}
                )
              ]
              do_fork: T
            )
          ]
          spids: [79 93]
        )
      ]
    )
    (command.If
      arms: [
        (if_arm
          cond: 
            (condition.Shell
              commands: [
                (command.Sentence
                  child: 
                    (command.DBracket
                      expr: 
                        (bool_expr.Binary
                          op_id: Id.BoolBinary_EqualTilde
                          left: {($ Id.VSub_At '$@')}
                          right: {(DQ <stdin>)}
                        )
                    )
                  terminator: <Id.Op_Semi _>
                )
              ]
            )
          action: [
            (command.Pipeline
              children: [
                (C {<refmt>} {<-parse>} {<re>} {<-print>} {<ml>} {<-use-stdin>} {<true>} {<-is-interface-pp>} 
                  {<false>}
                )
                (C {<utop>} {($ Id.VSub_At '$@')})
              ]
              negated: F
            )
          ]
          spids: [126 141]
        )
      ]
      else_action: [
        (C {<utop>} {<-init>} {($ Id.VSub_DollarName '$DIR') <'/rtop_init.ml'>} {($ Id.VSub_At '$@')} 
          {<-I>} {($ Id.VSub_DollarName '$HOME')} {<-safe-string>}
        )
      ]
    )
  ]
)