(command.CommandList children: [ (C {<Setup.require>} {<base>}) (C {<Setup.provide>} {<Config>} {<0.1>}) (C {<Id.Lit_Colon ':'>} { (braced_var_sub token: <Id.VSub_Name CONFIG_PREFIX> suffix_op: (suffix_op.Unary tok: <Id.VTest_Equals '='> arg_word: {<Id.Lit_Slash '/'> ($ Id.VSub_DollarName '$SETUP_PREFIX') <.config>} ) ) } ) (C {<declare>} {<-gA>} {<Id.Lit_VarLike 'CONFIG_MANIFESTS='> (sh_array_literal left:<Id.Op_LParen _>)} ) (command.ShFunction name: Config.param body: (BraceGroup children: [ (C {<local>} {<relpath>} {<fullpath>}) (command.Case to_match: {(DQ ($ Id.VSub_Number '$1'))} arms: [ (case_arm pat_list: [{<'/'> <Id.Lit_Star '*'>}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:relpath) op: assign_op.Equal rhs: { (DQ ($ Id.VSub_DollarName '$CONFIG_PREFIX') <'/'> ($ Id.VSub_Number '$1') <.conf> ) } spids: [64] ) ] ) ] spids: [60 62 71 -1] ) (case_arm pat_list: [{<Id.Lit_Star '*'>}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:relpath) op: assign_op.Equal rhs: { (DQ <'/'> ($ Id.VSub_DollarName '$SETUP_PREFIX') <'.config/'> ($ Id.VSub_Number '$1') <.conf> ) } spids: [77] ) ] ) ] spids: [74 75 85 -1] ) ] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:fullpath) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName '$SETUP_ROOT') ($ Id.VSub_DollarName '$relpath'))} spids: [91] ) ] ) (C {<mkdir>} {<-p>} { (DQ (braced_var_sub token: <Id.VSub_Name fullpath> suffix_op: (suffix_op.Unary tok: <Id.VOp1_Percent '%'> arg_word: {<Id.Lit_Slash '/'> <Id.Lit_Other '*'>} ) ) ) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: {($ Id.VSub_Pound '$#')} right: {<Id.Lit_Digits 1>} ) ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<printf>} {(DQ <'%s'> <Id.Lit_BadBackslash '\\'> <n>)} {(DQ ($ Id.VSub_DollarName '$relpath'))} ) ] spids: [112 124] ) ] else_action: [ (command.Sentence child: (C {<local>} {<Id.Lit_VarLike 'name='> (DQ ($ Id.VSub_Number '$1'))}) terminator: <Id.Op_Semi _> ) (C {<shift>}) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_Great left: {($ Id.VSub_Pound '$#')} right: {<Id.Lit_Digits 0>} ) ) terminator: <Id.Op_Semi _> ) ] ) body: (command.DoGroup children: [ (command.Case to_match: {(DQ ($ Id.VSub_Number '$1'))} arms: [ (case_arm pat_list: [{<Id.Lit_Colon ':'>}] action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-e>} {(DQ ($ Id.VSub_DollarName '$fullpath'))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<local>} {<param>}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:param) op: assign_op.Equal rhs: { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<Setup.params>} { (DQ ($ Id.VSub_DollarName '$name' ) ) } ) ) ) } spids: [209] ) ] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Id.Lit_Colon ':'>})] spids: [207 221] ) ] else_action: [ (C {<read>} {<-p>} { (DQ <'Please enter '> (braced_var_sub token: <Id.VSub_Star '*'> suffix_op: (suffix_op.Slice begin: {<Id.Lit_Digits 2>} ) ) <' (\''> ($ Id.VSub_DollarName '$name') <'\'): '> ) } {<param>} ) ] ) (command.Simple words: [{<echo>} {(DQ ($ Id.VSub_DollarName '$param'))}] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName '$fullpath'))} ) ] do_fork: T ) ] spids: [184 199] ) ] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] spids: [180 181 270 -1] ) (case_arm pat_list: [{<Id.Lit_Other '+'>}] action: [ (C {<local>} {<arg>}) (command.ForEach iter_name: arg iter_words: [ { (DQ (braced_var_sub token: <Id.VSub_At '@'> suffix_op: (suffix_op.Slice begin:{<Id.Lit_Digits 2>}) ) ) } ] do_arg_iter: F body: (command.DoGroup children: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<grep>} {<-qxF>} {(DQ ($ Id.VSub_DollarName '$arg'))} {(DQ ($ Id.VSub_DollarName '$fullpath'))} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Sentence child: (C {<Id.Lit_Colon ':'>}) terminator: <Id.Op_Semi _> ) ] spids: [300 315] ) ] else_action: [ (C {<printf>} {(DQ <'%s'> <Id.Lit_BadBackslash '\\'> <n>)} {(DQ ($ Id.VSub_DollarName '$arg'))} ) ] ) ] ) redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName '$fullpath'))} ) ] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] spids: [273 274 351 -1] ) ] ) ] ) ) ] ) ] ) ) (command.ShFunction name: Config.manifest body: (BraceGroup children: [ (C {<local>} {<Id.Lit_VarLike 'manifest='> (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<Config.param>} {(DQ ($ Id.VSub_Number '$1') <.manifest>)}) ) ) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-z>} { (DQ (braced_var_sub token: <Id.VSub_Name CONFIG_MANIFESTS> bracket_op: (bracket_op.ArrayIndex expr:{($ Id.VSub_Number '$1')}) ) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.IndexedName name: CONFIG_MANIFESTS index: {($ Id.VSub_Number '$1')} ) op: assign_op.Equal rhs: {<1>} spids: [409] ) ] ) (command.Simple words: [{<printf>} {(SQ )}] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName '$SETUP_ROOT') ($ Id.VSub_DollarName '$manifest') ) } ) ] do_fork: T ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Setup.params>} {<-> (DQ ($ Id.VSub_Number '$1'))}) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<recipe>} {(DQ <'.build/'> ($ Id.VSub_Number '$1'))} {<Id.Lit_Equals '='>} {<Target>} {<Id.Lit_Other '%'> <Id.Lit_At '@'> (DQ ($ Id.VSub_DollarName '$manifest'))} ) ] spids: [430 440] ) ] ) ] spids: [388 406] ) ] ) (C {<Config.param>} {(DQ ($ Id.VSub_Number '$1') <.manifest>)} {<Id.Lit_Other '+'>} { (DQ (braced_var_sub token: <Id.VSub_At '@'> suffix_op: (suffix_op.Slice begin:{<Id.Lit_Digits 2>}) ) ) } ) ] ) ) (command.ShFunction name: Target body: (BraceGroup children: [ (command.Sentence child: (C {<mkpdir>} {(DQ ($ Id.VSub_Number '$1'))}) terminator: <Id.Op_Semi _> ) (command.Sentence child: (command.Simple words: [ {<printf>} {(DQ <'%s'> <Id.Lit_BadBackslash '\\'> <n>)} { (DQ (braced_var_sub token: <Id.VSub_At '@'> suffix_op: (suffix_op.Slice begin:{<Id.Lit_Digits 2>}) ) ) } ] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_Number '$1'))} ) ] do_fork: T ) terminator: <Id.Op_Semi _> ) ] ) ) ] )