(CommandList
  children: [
    (C {(set)} {(-euo)} {(pipefail)})
    (If
      arms: [
        (if_arm
          cond: [
            (Sentence
              child: 
                (Pipeline
                  children: [
                    (C 
                      {
                        (CommandSubPart
                          command_list: 
                            (CommandList
                              children: [
                                (SimpleCommand
                                  words: [{(which)} {(DQ (spacejam))}]
                                  redirects: [
                                    (Redir
                                      op_id: Redir_Great
                                      fd: -1
                                      arg_word: {(/dev/null)}
                                      spids: [26]
                                    )
                                    (Redir
                                      op_id: Redir_Great
                                      fd: 2
                                      arg_word: {(/dev/null)}
                                      spids: [29]
                                    )
                                  ]
                                )
                              ]
                            )
                          left_token: <Left_CommandSub '$('>
                          spids: [19 31]
                        )
                      }
                    )
                  ]
                  negated: True
                )
              terminator: <Op_Semi ';'>
            )
          ]
          action: [
            (C {(echo)} 
              {
                (DQ 
                  (
"Couldn't find executable 'spacejam' - try installing the package from npm with 'sudo -H npm install -g spacejam'?"
                  )
                )
              }
            )
            (C {(exit)} {(1)})
          ]
          spids: [-1 35]
        )
      ]
      spids: [-1 49]
    )
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:SCRIPT_DIR)
          op: Equal
          rhs: 
            {
              (CommandSubPart
                command_list: 
                  (CommandList
                    children: [
                      (AndOr
                        children: [
                          (C {(cd)} 
                            {
                              (DQ 
                                (CommandSubPart
                                  command_list: 
                                    (CommandList
                                      children: [
                                        (C {(dirname)} 
                                          {
                                            (DQ 
                                              (BracedVarSub
                                                token: <VSub_Name BASH_SOURCE>
                                                bracket_op: 
                                                  (ArrayIndex
                                                    expr: (ArithWord w:{(Lit_Digits 0)})
                                                  )
                                                spids: [61 66]
                                              )
                                            )
                                          }
                                        )
                                      ]
                                    )
                                  left_token: <Left_CommandSub '$('>
                                  spids: [57 68]
                                )
                              )
                            }
                          )
                          (C {(pwd)})
                        ]
                        op_id: Op_DAmp
                      )
                    ]
                  )
                left_token: <Left_CommandSub '$('>
                spids: [53 74]
              )
            }
          spids: [52]
        )
      ]
      spids: [52]
    )
    (C {(cd)} {(DQ ($ VSub_Name '$SCRIPT_DIR'))})
    (FuncDef
      name: run_build
      body: 
        (BraceGroup
          children: [
            (Subshell
              child: 
                (AndOr
                  children: [
                    (C {(cd)} {(DQ ($ VSub_Name '$SCRIPT_DIR') (/..))})
                    (C {(make)} {(shell-env)})
                  ]
                  op_id: Op_DAmp
                )
              spids: [90 103]
            )
            (C {(cd)} {(DQ ($ VSub_Name '$SCRIPT_DIR'))})
          ]
          spids: [87]
        )
      spids: [83 86]
    )
    (Assignment
      keyword: Assign_None
      pairs: [(assign_pair lhs:(LhsName name:SKIP_BUILD) op:Equal rhs:{(DQ (no))} spids:[115])]
      spids: [115]
    )
    (FuncDef
      name: handle_args
      body: 
        (BraceGroup
          children: [
            (While
              cond: [(Sentence child:(C {(getopts)} {(DQ (f))} {(opt)}) terminator:<Op_Semi ';'>)]
              body: 
                (DoGroup
                  children: [
                    (Case
                      to_match: {($ VSub_Name '$opt')}
                      arms: [
                        (case_arm
                          pat_list: [{(f)}]
                          action: [
                            (Assignment
                              keyword: Assign_None
                              pairs: [
                                (assign_pair
                                  lhs: (LhsName name:SKIP_BUILD)
                                  op: Equal
                                  rhs: {(DQ (yes))}
                                  spids: [152]
                                )
                              ]
                              spids: [152]
                            )
                          ]
                          spids: [148 149 158 -1]
                        )
                        (case_arm
                          pat_list: [{(Lit_Other '*')}]
                          action: [
                            (C {(echo)} {(DQ ("You can add '-f' to skip the build step"))})
                            (C {(exit)} {(1)})
                          ]
                          spids: [161 162 177 -1]
                        )
                      ]
                      spids: [141 145 180]
                    )
                  ]
                  spids: [138 183]
                )
            )
          ]
          spids: [124]
        )
      spids: [120 123]
    )
    (C {(handle_args)} {(DQ ($ VSub_At '$@'))})
    (If
      arms: [
        (if_arm
          cond: [
            (Sentence
              child: 
                (C {(Lit_Other '[')} {(DQ (yes))} {(KW_Bang '!') (Lit_Other '=')} 
                  {(DQ ($ VSub_Name '$SKIP_BUILD'))} {(Lit_Other ']')}
                )
              terminator: <Op_Semi ';'>
            )
          ]
          action: [(C {(run_build)})]
          spids: [-1 212]
        )
      ]
      spids: [-1 217]
    )
    (Assignment
      keyword: Assign_None
      pairs: [
        (assign_pair
          lhs: (LhsName name:SETTINGS)
          op: Equal
          rhs: 
            {
              (CommandSubPart
                command_list: (CommandList children:[(C {(mktemp)})])
                left_token: <Left_CommandSub '$('>
                spids: [221 223]
              )
            }
          spids: [220]
        )
      ]
      spids: [220]
    )
    (SimpleCommand
      words: [{(cat)}]
      redirects: [
        (Redir op_id:Redir_Great fd:-1 arg_word:{($ VSub_Name '$SETTINGS')} spids:[228])
        (HereDoc
          op_id: Redir_DLess
          fd: -1
          body: 
            {
              (DQ ('{\n') ('  ') (Right_DoubleQuote '"') (public) (Right_DoubleQuote '"') (': {\n') 
                ('    ') (Right_DoubleQuote '"') (buildstamp) (Right_DoubleQuote '"') (': ') (Right_DoubleQuote '"') 
                ('[local dev front-end]') (Right_DoubleQuote '"') (',\n') ('    ') (Right_DoubleQuote '"') (allowDemoAccounts) 
                (Right_DoubleQuote '"') (': true,\n') ('    ') (Right_DoubleQuote '"') (allowDevAccounts) (Right_DoubleQuote '"') (': true,\n') 
                ('    ') (Right_DoubleQuote '"') (allowUninvited) (Right_DoubleQuote '"') (': ') 
                (BracedVarSub
                  token: <VSub_Name ALLOW_UNINVITED>
                  suffix_op: (StringUnary op_id:VTest_ColonHyphen arg_word:{(false)})
                  spids: [266 270]
                ) (',\n') ('    ') (Right_DoubleQuote '"') (isTesting) (Right_DoubleQuote '"') (': true,\n') ('    ') 
                (Right_DoubleQuote '"') (wildcardHost) (Right_DoubleQuote '"') (': ') (Right_DoubleQuote '"') ('*.local.sandstorm.io') 
                (Right_DoubleQuote '"') ('\n') ('  }\n') ('}\n')
              )
            }
          do_expansion: True
          here_end: __EOF__
          was_filled: True
          spids: [232]
        )
      ]
    )
    (C {(export)} 
      {(Lit_VarLike 'PYTHONPATH=') 
        (CommandSubPart
          command_list: 
            (CommandList
              children: [(C {(DQ ($ VSub_Name '$SCRIPT_DIR') (/../find-meteor-dev-bundle.sh))})]
            )
          left_token: <Left_CommandSub '$('>
          spids: [299 304]
        ) (/lib/node_modules/npm/node_modules/node-gyp/gyp/pylib)
      }
    )
    (C {(exec)} {(spacejam)} {(test-packages)} {(--settings)} {($ VSub_Name '$SETTINGS')} 
      {(./packages/sandstorm-permissions)}
    )
  ]
)