(List (Com {[LIT_CHARS set]} {[LIT_CHARS -o]} {[LIT_CHARS errexit]} ) (Com {[LIT_CHARS set]} {[LIT_CHARS -o]} {[LIT_CHARS nounset]} ) (Com {[LIT_CHARS set]} {[LIT_CHARS -o]} {[LIT_CHARS pipefail]} ) (= scope= flags=1 words=[] bindings=[('LANG', {[LIT_CHARS C]})]) (= scope= flags=1 words=[] bindings=[('LC_ALL', {[LIT_CHARS C]})]) (FunctionDef process_content [] (List (= scope= flags=0 words=[] bindings=[('package', {[VarSub 1]})]) (= scope= flags=0 words=[] bindings=[('type', {[VarSub 2]})]) (= scope= flags=0 words=[{[LIT_CHARS package_root]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS ensure_pattern]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS dir_root]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS find_maxdepth]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS find_names]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS -a]}] bindings=[('local_files', {[Array ]})]) (Case to_match={[VarSub type]}, pat_word_list=[[{[LIT_CHARS LICENSE]}], [{[LIT_CHARS COPYRIGHT]}]] (List (= scope= flags=0 words=[] bindings=[('find_names', {[Array {[LIT_CHARS -iname]} {[SQ ]}]})]) (= scope= flags=0 words=[] bindings=[('find_maxdepth', {[LIT_CHARS 1]})]) (= scope= flags=0 words=[] bindings=[('ensure_pattern', {[DQ [LIT_CHARS "license|copyright"]]})]) ) (List (= scope= flags=0 words=[] bindings=[('find_names', {[Array {[LIT_CHARS -iname]} {[SQ ]} {[LIT_CHARS -o]} {[LIT_CHARS -iname]} {[SQ ]}]})]) (= scope= flags=0 words=[] bindings=[('find_maxdepth', {[LIT_CHARS 3]})]) (= scope= flags=0 words=[] bindings=[('ensure_pattern', {[DQ [LIT_CHARS copyright]]})]) ) ) (Case to_match={[VarSub package]}, pat_word_list=[[{[LIT_CHARS github.com/] [LIT_OTHER "*"]}, {[LIT_CHARS golang.org/] [LIT_OTHER "*"]}, {[LIT_CHARS bitbucket.org/] [LIT_OTHER "*"]}], [{[LIT_CHARS go4.org/] [LIT_OTHER "*"]}], [{[LIT_OTHER "*"]}]] (= scope= flags=0 words=[] bindings=[('package_root', {[ComSub (Pipeline (Com {[LIT_CHARS echo]} {[VarSub package]}) (Com {[LIT_CHARS awk]} {[LIT_CHARS -F/]} {[SQ ]}) )]})]) (= scope= flags=0 words=[] bindings=[('package_root', {[ComSub (Pipeline (Com {[LIT_CHARS echo]} {[VarSub package]}) (Com {[LIT_CHARS awk]} {[LIT_CHARS -F/]} {[SQ ]}) )]})]) (= scope= flags=0 words=[] bindings=[('package_root', {[ComSub (Pipeline (Com {[LIT_CHARS echo]} {[VarSub package]}) (Com {[LIT_CHARS awk]} {[LIT_CHARS -F/]} {[SQ ]}) )]})]) ) (= scope= flags=0 words=[] bindings=[('local_files', {[Array {[ComSub (Pipeline (For dir_root [{[VarSub package]}, {[VarSub package_root]}]) (List (AndOr OP_OR_IF (DBracket {B1 UNARY_FILE_d {[VarSub DEPS_DIR] [LIT_CHARS /] [VarSub dir_root]}}) (Com {[LIT_CHARS continue]}) ) (Com {[LIT_CHARS find]} {[VarSub DEPS_DIR] [LIT_CHARS /] [VarSub dir_root]} {[LIT_CHARS -xdev]} {[LIT_CHARS -follow]} {[LIT_CHARS -maxdepth]} {[VarSub find_maxdepth]} {[LIT_CHARS -type]} {[LIT_CHARS f]} {[DQ [VarSub find_names bracket_op=(Index {A Atom NODE_ARITH_WORD {AS_OP_AT "@"}})]]}) ) ) (Com {[LIT_CHARS sort]} {[LIT_CHARS -u]}) )]}]})]) (= scope= flags=0 words=[{[LIT_CHARS index]}] bindings=[]) (= scope= flags=0 words=[{[LIT_CHARS f]}] bindings=[]) (= scope= flags=0 words=[] bindings=[('index', {[DQ [VarSub package][LIT_CHARS -][VarSub type]]})]) (If (DBracket {B1 UNARY_STRING_z {[DQ [VarSub CONTENT bracket_op=(Index {A Atom NODE_ARITH_WORD {[VarSub index]}}) test_op=VS_TEST_HYPHEN {}]]}}) (For f [{[VarSub local_files bracket_op=(Index {A Atom NODE_ARITH_WORD {AS_OP_AT "@"}}) test_op=VS_TEST_HYPHEN {}]}]) (If (Com {[LIT_CHARS egrep]} {[LIT_CHARS -i]} {[LIT_CHARS -wq]} {[DQ [VarSub ensure_pattern]]} {[DQ [VarSub f]]} ) (List (Com {[LIT_CHARS CONTENT] [LIT_DBRACKET_LIKE "["] [VarSub index] [LIT_DBRACKET_LIKE "]="] [DQ [VarSub f]]} ) (Com {[LIT_CHARS break]} ) ) ) ) ) ) ) (= scope= flags=0 words=[] bindings=[('KUBE_ROOT', {[ComSub (Com {[LIT_CHARS dirname]} {[DQ [VarSub BASH_SOURCE]]})] [LIT_CHARS /..]})]) (Com {[LIT_CHARS source]} {[DQ [VarSub KUBE_ROOT][LIT_CHARS /hack/lib/init.sh]]} ) (If (DParen {A2 AS_OP_LESS {A Atom NODE_ARITH_WORD {[VarSub BASH_VERSINFO bracket_op=(Index {A Atom NODE_ARITH_WORD {[AS_NUM_LITERAL 0]}})]}} {A Atom NODE_ARITH_WORD {[AS_NUM_LITERAL 4]}}}) (List (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "ERROR: Bash v4+ required."]]} ) (If (DBracket {B2 BINARY_STRING_EQUAL {[DQ [ComSub (Com {[LIT_CHARS uname]} {[LIT_CHARS -s]})]]} {[DQ [LIT_CHARS Darwin]]}}) (List (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "Ensure you are up to date on the following packages:"]]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_OTHER "$"][LIT_CHARS " brew install md5sha1sum bash jq"]]} ) ) ) (Com {[LIT_CHARS echo]} ) ) ) (= scope= flags=0 words=[] bindings=[('LICENSE_ROOT', {[DQ [VarSub LICENSE_ROOT test_op=VS_TEST_COLON_HYPHEN {[VarSub KUBE_ROOT]}]]})]) (Com {[LIT_CHARS cd]} {[DQ [VarSub LICENSE_ROOT]]} ) (= scope= flags=0 words=[] bindings=[('GODEPS_LICENSE_FILE', {[DQ [LIT_CHARS Godeps/LICENSES]]})]) (= scope= flags=0 words=[] bindings=[('TMP_LICENSE_FILE', {[DQ [LIT_CHARS /tmp/Godeps.LICENSES.][VarSub $]]})]) (= scope= flags=0 words=[] bindings=[('DEPS_DIR', {[DQ [LIT_CHARS vendor]]})]) (= scope= flags=0 words=[{[LIT_CHARS -Ag]}, {[LIT_CHARS CONTENT]}] bindings=[]) (Subshell (List (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "================================================================================"]]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "= Kubernetes licensed under: ="]]} ) (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS cat]} {[VarSub LICENSE_ROOT] [LIT_CHARS /LICENSE]} ) (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "= LICENSE "][ComSub (Pipeline (Com {[LIT_CHARS cat]} {[VarSub LICENSE_ROOT] [LIT_CHARS /LICENSE]}) (Com {[LIT_CHARS md5sum]}) )]]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "================================================================================"]]} ) ) ) (For PACKAGE [{[ComSub (Pipeline (Com {[LIT_CHARS cat]} {[LIT_CHARS Godeps/Godeps.json]}) (Com {[LIT_CHARS jq]} {[LIT_CHARS -r]} {[DQ [LIT_CHARS ".Deps[].ImportPath"]]}) (Com {[LIT_CHARS sort]} {[LIT_CHARS -f]}) )]}]) (List (Com {[LIT_CHARS process_content]} {[VarSub PACKAGE]} {[LIT_CHARS LICENSE]} ) (Com {[LIT_CHARS process_content]} {[VarSub PACKAGE]} {[LIT_CHARS COPYRIGHT]} ) (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "================================================================================"]]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "= "][VarSub DEPS_DIR][LIT_CHARS /][VarSub PACKAGE][LIT_CHARS " licensed under: ="]]} ) (Com {[LIT_CHARS echo]} ) (= scope= flags=0 words=[] bindings=[('file', {[DQ ]})]) (If (DBracket {B1 UNARY_STRING_n {[DQ [VarSub CONTENT bracket_op=(Index {A2 AS_OP_MINUS {A Atom NODE_ARITH_WORD {[VarSub PACKAGE]}} {A Atom NODE_ARITH_WORD {[VarSub LICENSE]}}}) test_op=VS_TEST_HYPHEN {}]]}}) (= scope= flags=0 words=[] bindings=[('file', {[DQ [VarSub CONTENT bracket_op=(Index {A2 AS_OP_MINUS {A Atom NODE_ARITH_WORD {[VarSub PACKAGE]}} {A Atom NODE_ARITH_WORD {[VarSub LICENSE]}}}) test_op=VS_TEST_HYPHEN {}]]})]) (DBracket {B1 UNARY_STRING_n {[DQ [VarSub CONTENT bracket_op=(Index {A2 AS_OP_MINUS {A Atom NODE_ARITH_WORD {[VarSub PACKAGE]}} {A Atom NODE_ARITH_WORD {[VarSub COPYRIGHT]}}}) test_op=VS_TEST_HYPHEN {}]]}}) (= scope= flags=0 words=[] bindings=[('file', {[DQ [VarSub CONTENT bracket_op=(Index {A2 AS_OP_MINUS {A Atom NODE_ARITH_WORD {[VarSub PACKAGE]}} {A Atom NODE_ARITH_WORD {[VarSub COPYRIGHT]}}}) test_op=VS_TEST_HYPHEN {}]]})]) ) (If (DBracket {B1 UNARY_STRING_z {[DQ [VarSub file]]}}) (List (Com {[LIT_CHARS cat]} < (FilenameRedirectNode filename={[LIT_CHARS /dev/stderr]} "> 1), (HereDocRedirectNode here_end='__EOF__' do_expansion=True body_word={[DQ [LIT_CHARS "No license could be found for "][VarSub PACKAGE][LIT_CHARS " - aborting.\n"][LIT_CHARS "\n"][LIT_CHARS "Options:\n"][LIT_CHARS "1. Check if the upstream repository has a newer version with LICENSE and/or\n"][LIT_CHARS " COPYRIGHT files.\n"][LIT_CHARS "2. Contact the author of the package to ensure there is a LICENSE and/or\n"][LIT_CHARS " COPYRIGHT file present.\n"][LIT_CHARS "3. Do not use this package in Kubernetes.\n"]]} 0), > ) (Com {[LIT_CHARS exit]} {[LIT_CHARS 9]} ) ) ) (Com {[LIT_CHARS cat]} {[DQ [VarSub file]]} ) (Com {[LIT_CHARS echo]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "= "][VarSub file][LIT_CHARS " "][ComSub (Pipeline (Com {[LIT_CHARS cat]} {[VarSub file]}) (Com {[LIT_CHARS md5sum]}) )]]} ) (Com {[LIT_CHARS echo]} {[DQ [LIT_CHARS "================================================================================"]]} ) (Com {[LIT_CHARS echo]} ) ) ) (Com {[LIT_CHARS cat]} {[VarSub TMP_LICENSE_FILE]} < (FilenameRedirectNode filename={[VarSub GODEPS_LICENSE_FILE]} "> 1), > ) )