(command.CommandList children: [ (command.ShFunction name: readablesize body: (command.BraceGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_Number '$1')} {(-ge)} {(1048576)} {(Id.Lit_RBracket ']')} ) terminator: (Token id:Id.Op_Semi val:';' span_id:37) ) ] action: [ (C {(echo)} { (DQ (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:45) command_list: (command.CommandList children: [ (C {(scriptbc)} {(-p)} {(2)} {($ Id.VSub_Number '$1')} {(/)} {(1048576)}) ] ) ) (Gb) ) } ) ] spids: [25 39] ) (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_Number '$1')} {(-ge)} {(1024)} {(Id.Lit_RBracket ']')} ) terminator: (Token id:Id.Op_Semi val:';' span_id:74) ) ] action: [ (C {(echo)} { (DQ (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:82) command_list: (command.CommandList children: [ (C {(scriptbc)} {(-p)} {(2)} {($ Id.VSub_Number '$1')} {(/)} {(1024)}) ] ) ) (Mb) ) } ) ] spids: [62 76] ) ] else_action: [(C {(echo)} {(DQ (${ Id.VSub_Number 1) (Kb))})] ) ] ) ) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_Pound '$#')} {(-gt)} {(1)} {(Id.Lit_RBracket ']')}) terminator: (Token id:Id.Op_Semi val:';' span_id:137) ) ] action: [ (command.Sentence child: (command.Simple words: [{(echo)} {(DQ ('Usage: ') ($ Id.VSub_Number '$0') (' [dirname]'))}] redirects: [ (redir.Redir op: (Token id:Id.Redir_GreatAnd val:'>&' span_id:150) fd: -1 arg_word: {(2)} ) ] ) terminator: (Token id:Id.Op_Semi val:';' span_id:152) ) (command.ControlFlow token: (Token id:Id.ControlFlow_Exit val:exit span_id:154) arg_word: {(1)} ) ] spids: [125 139] ) (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_Pound '$#')} {(-eq)} {(1)} {(Id.Lit_RBracket ']')}) terminator: (Token id:Id.Op_Semi val:';' span_id:170) ) ] action: [ (C {(cd)} {(DQ ($ Id.VSub_At '$@'))}) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_QMark '$?')} {(-ne)} {(0)} {(Id.Lit_RBracket ']')} ) terminator: (Token id:Id.Op_Semi val:';' span_id:200) ) ] action: [ (command.ControlFlow token: (Token id:Id.ControlFlow_Exit val:exit span_id:208) arg_word: {(1)} ) ] spids: [188 202] ) ] ) ] spids: [158 172] ) ] ) (command.Pipeline children: [ (command.ForEach iter_name: file iter_words: [{(Id.Lit_Star '*')}] do_arg_iter: F body: (command.DoGroup children: [ (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {(-d)} {(DQ ($ Id.VSub_DollarName '$file'))} {(Id.Lit_RBracket ']')} ) terminator: (Token id:Id.Op_Semi val:';' span_id:242) ) ] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:size) op: assign_op.Equal rhs: { (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:248) command_list: (command.CommandList children: [ (command.Pipeline children: [ (C {(ls)} {(DQ ($ Id.VSub_DollarName '$file'))}) (C {(wc)} {(-l)}) (C {(sed)} { (SQ (Token id: Id.Lit_Chars val: 's/[^[:digit:]]//g' span_id: 266 ) ) } ) ] negated: F ) ] ) ) } spids: [247] ) ] ) (command.If arms: [ (if_arm cond: [ (command.Sentence child: (C {(Id.Lit_LBracket '[')} {($ Id.VSub_DollarName '$size')} {(-eq)} {(1)} {(Id.Lit_RBracket ']')} ) terminator: (Token id:Id.Op_Semi val:';' span_id:283) ) ] action: [ (C {(echo)} { (DQ ($ Id.VSub_DollarName '$file') (' (') ($ Id.VSub_DollarName '$size') (' entry)|') ) } ) ] spids: [271 285] ) ] else_action: [ (C {(echo)} { (DQ ($ Id.VSub_DollarName '$file') (' (') ($ Id.VSub_DollarName '$size') (' entries)|') ) } ) ] ) ] spids: [230 244] ) ] else_action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name name:size) op: assign_op.Equal rhs: { (DQ (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:319) command_list: (command.CommandList children: [ (command.Pipeline children: [ (C {(ls)} {(-sk)} {(DQ ($ Id.VSub_DollarName '$file'))}) (C {(awk)} { (SQ (Token id: Id.Lit_Chars val: '{print $1}' span_id: 333 ) ) } ) ] negated: F ) ] ) ) ) } spids: [317] ) ] ) (C {(echo)} { (DQ ($ Id.VSub_DollarName '$file') (' (') (command_sub left_token: (Token id:Id.Left_DollarParen val:'$(' span_id:344) command_list: (command.CommandList children: [(C {(readablesize)} {($ Id.VSub_DollarName '$size')})] ) ) (')|') ) } ) ] ) ] ) ) (C {(sed)} {(SQ (Token id:Id.Lit_Chars val:'s/ /^^^/g' span_id:364))}) (C {(xargs)} {(-n)} {(2)}) (C {(sed)} {(SQ (Token id:Id.Lit_Chars val:'s/\\^\\^\\^/ /g' span_id:384))}) (C {(awk)} {(-F) (word_part.EscapedLiteral token:(Token id:Id.Lit_EscapedChar val:'\\|' span_id:394))} {(SQ (Token id:Id.Lit_Chars val:'{ printf "%-39s %-39s\\n", $1, $2 }' span_id:397))} ) ] negated: F ) (command.ControlFlow token:(Token id:Id.ControlFlow_Exit val:exit span_id:401) arg_word:{(0)}) ] )