(BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'INPUT='> name:INPUT) op: assign_op.Equal rhs: {<0>} spids: [78] ) ] redirects: [] ) (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_Number 1)} right: {<Id.Lit_Other '^'> <-> <Id.Lit_Other '?'> <Id.Lit_Other '['> <0-9> <Id.Lit_Other ']'> <Id.Lit_Other '+'> <Id.Lit_Other '$'> } ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'INPUT='> name:INPUT) op: assign_op.Equal rhs: {($ Id.VSub_Number 1)} spids: [106] ) ] redirects: [] ) ] spids: [82 102] ) ] else_action: [] redirects: [] ) (C {<.>} {<'/DietPi/dietpi/func/dietpi-globals'>}) (C {<G_CHECK_ROOT_USER>}) (C {<G_CHECK_ROOTFS_RW>}) (C {<export>} {<Id.Lit_VarLike 'G_PROGRAM_NAME='> (SQ <DietPi-Update>)}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'GITBRANCH='> name:GITBRANCH) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<grep>} {<-m1>} {(SQ <'^DEV_GITBRANCH='>)} {<'/DietPi/dietpi.txt'>}) (C {<sed>} {(SQ <'s/.*=//'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } spids: [155] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'GITFORKOWNER='> name:GITFORKOWNER) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<grep>} {<-m1>} {(SQ <'^DEV_GITOWNER='>)} {<'/DietPi/dietpi.txt'>}) (C {<sed>} {(SQ <'s/.*=//'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } spids: [177] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FP_LOG='> name:FP_LOG) op: assign_op.Equal rhs: {(SQ <'/var/tmp/dietpi/logs/dietpi-update.log'>)} spids: [212] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'DIETPIUPDATE_COREVERSION_CURRENT='> name: DIETPIUPDATE_COREVERSION_CURRENT ) op: assign_op.Equal rhs: {<6>} spids: [218] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FILEPATH_TEMP='> name:FILEPATH_TEMP) op: assign_op.Equal rhs: {(DQ <'/tmp/dietpi-update'>)} spids: [226] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'SERVER_ONLINE='> name:SERVER_ONLINE) op: assign_op.Equal rhs: {<0>} spids: [233] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'UPDATE_AVAILABLE='> name:UPDATE_AVAILABLE) op: assign_op.Equal rhs: {<0>} spids: [237] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'UPDATE_REQUIRESNEWIMAGE='> name: UPDATE_REQUIRESNEWIMAGE ) op: assign_op.Equal rhs: {<0>} spids: [241] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'RUN_UPDATE='> name:RUN_UPDATE) op: assign_op.Equal rhs: {<0>} spids: [245] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'COREVERSION_CURRENT='> name: COREVERSION_CURRENT ) op: assign_op.Equal rhs: {<0>} spids: [250] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'SUBVERSION_CURRENT='> name:SUBVERSION_CURRENT) op: assign_op.Equal rhs: {<0>} spids: [254] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'COREVERSION_SERVER='> name:COREVERSION_SERVER) op: assign_op.Equal rhs: {<0>} spids: [259] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'SUBVERSION_SERVER='> name:SUBVERSION_SERVER) op: assign_op.Equal rhs: {<0>} spids: [263] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'URL_MIRROR_INDEX='> name:URL_MIRROR_INDEX) op: assign_op.Equal rhs: {<0>} spids: [268] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'URL_MIRROR_SERVERVERSION='> name: URL_MIRROR_SERVERVERSION ) op: assign_op.Equal rhs: { (sh_array_literal left: <Id.Op_LParen _> words: [ { (DQ <'http://dietpi.com/downloads/dietpi-update_mirror/'> ($ Id.VSub_DollarName GITBRANCH) <'/server_version-6'> ) } { (DQ <'https://raw.githubusercontent.com/'> (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name GITFORKOWNER> var_name: GITFORKOWNER suffix_op: (suffix_op.Unary op:<Id.VTest_ColonHyphen _> arg_word:{<Fourdee>}) right: <Id.Right_DollarBrace '}'> ) <'/DietPi/'> ($ Id.VSub_DollarName GITBRANCH) <'/dietpi/server_version-6'> ) } ] ) } spids: [272] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'URL_MIRROR_ZIP='> name:URL_MIRROR_ZIP) op: assign_op.Equal rhs: { (sh_array_literal left: <Id.Op_LParen _> words: [ { (DQ <'http://dietpi.com/downloads/dietpi-update_mirror/'> ($ Id.VSub_DollarName GITBRANCH) <'/DietPi-'> ($ Id.VSub_DollarName GITBRANCH) <.zip> ) } { (DQ <'https://github.com/'> (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name GITFORKOWNER> var_name: GITFORKOWNER suffix_op: (suffix_op.Unary op:<Id.VTest_ColonHyphen _> arg_word:{<Fourdee>}) right: <Id.Right_DollarBrace '}'> ) <'/DietPi/archive/'> ($ Id.VSub_DollarName GITBRANCH) <.zip> ) } ] ) } spids: [302] ) ] redirects: [] ) (command.ShFunction name: Get_Client_Version body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'COREVERSION_CURRENT='> name: COREVERSION_CURRENT ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<sed>} {<-n>} {<1p>} {<'/DietPi/dietpi/.version'>}) right: <Id.Eof_RParen _> ) } spids: [341] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'SUBVERSION_CURRENT='> name: SUBVERSION_CURRENT ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<sed>} {<-n>} {<2p>} {<'/DietPi/dietpi/.version'>}) right: <Id.Eof_RParen _> ) } spids: [353] ) ] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Get_Server_Version body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ForExpr init: (arith_expr.BinaryAssign op_id: Id.Arith_Equal left: ($ Id.Lit_ArithVarLike i) right: {<Id.Lit_Digits 0>} ) cond: (arith_expr.Binary op_id: Id.Arith_Less left: ($ Id.Lit_ArithVarLike i) right: { (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_SERVERVERSION> var_name: URL_MIRROR_SERVERVERSION prefix_op: <Id.VSub_Pound '#'> bracket_op: (bracket_op.WholeArray op_id:Id.Lit_At) right: <Id.Right_DollarBrace '}'> ) } ) update: (arith_expr.UnaryAssign op_id:Id.Node_PostDPlus child:($ Id.Lit_ArithVarLike i)) body: (command.DoGroup children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'URL_MIRROR_INDEX='> name: URL_MIRROR_INDEX ) op: assign_op.Equal rhs: {($ Id.VSub_DollarName i)} spids: [410] ) ] redirects: [] ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Checking Mirror : '> (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_SERVERVERSION> var_name: URL_MIRROR_SERVERVERSION bracket_op: (bracket_op.ArrayIndex expr:{($ Id.VSub_DollarName i)}) right: <Id.Right_DollarBrace '}'> ) ) } ) (command.Simple words: [ {<curl>} {<-k>} {<-L>} { (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_SERVERVERSION> var_name: URL_MIRROR_SERVERVERSION bracket_op: (bracket_op.ArrayIndex expr:{($ Id.VSub_DollarName i)}) right: <Id.Right_DollarBrace '}'> ) } ] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/server_version'>} ) ] more_env: [] do_fork: T ) (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_QMark '?')} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'COREVERSION_SERVER='> name: COREVERSION_SERVER ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<sed>} {<-n>} {<1p>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/server_version'> } ) right: <Id.Eof_RParen _> ) } spids: [473] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'SUBVERSION_SERVER='> name: SUBVERSION_SERVER ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<sed>} {<-n>} {<2p>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/server_version'> } ) right: <Id.Eof_RParen _> ) } spids: [488] ) ] redirects: [] ) (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_DollarName SUBVERSION_SERVER)} right: {<Id.Lit_Other '^'> <-> <Id.Lit_Other '?'> <Id.Lit_Other '['> <0-9> <Id.Lit_Other ']'> <Id.Lit_Other '+'> <Id.Lit_Other '$'> } ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'SERVER_ONLINE='> name: SERVER_ONLINE ) op: assign_op.Equal rhs: {<1>} spids: [532] ) ] redirects: [] ) (C {<G_DIETPI-NOTIFY>} {<0>} { (DQ <'Using update server: '> (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_SERVERVERSION> var_name: URL_MIRROR_SERVERVERSION bracket_op: (bracket_op.ArrayIndex expr: {($ Id.VSub_DollarName i)} ) right: <Id.Right_DollarBrace '}'> ) ) } ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] spids: [508 528] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<2>} {(DQ <'Invalid server version and/or update file unavailable'>)} ) ] redirects: [] ) ] spids: [451 465] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'No response from: '> (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_SERVERVERSION> var_name: URL_MIRROR_SERVERVERSION bracket_op: (bracket_op.ArrayIndex expr:{($ Id.VSub_DollarName i)}) right: <Id.Right_DollarBrace '}'> ) ) } ) ] redirects: [] ) ] ) redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Check_Update_Available body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.Simple words: [{<rm>} {<'/DietPi/dietpi/.update_available'>}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName SERVER_ONLINE)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_Less left: {($ Id.VSub_DollarName DIETPIUPDATE_COREVERSION_CURRENT)} right: {($ Id.VSub_DollarName COREVERSION_SERVER)} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'UPDATE_REQUIRESNEWIMAGE='> name: UPDATE_REQUIRESNEWIMAGE ) op: assign_op.Equal rhs: {<1>} spids: [667] ) ] redirects: [] ) (command.Simple words: [{<echo>} {<-e>} {(DQ <-1>)}] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {<'/DietPi/dietpi/.update_available'>} ) ] more_env: [] do_fork: T ) ] spids: [649 663] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_Less left: {($ Id.VSub_DollarName SUBVERSION_CURRENT)} right: {($ Id.VSub_DollarName SUBVERSION_SERVER)} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'UPDATE_AVAILABLE='> name: UPDATE_AVAILABLE ) op: assign_op.Equal rhs: {<1>} spids: [707] ) ] redirects: [] ) (C {<echo>} {<-e>} {(DQ )}) (C {<G_DIETPI-NOTIFY>} {<0>} {(DQ <'Update available'>)}) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Current Version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Server Version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) ) } ) (command.Simple words: [{<cat>}] redirects: [ (redir op: <Id.Redir_DLess '<<'> loc: (redir_loc.Fd fd:0) arg: (redir_param.HereDoc here_begin: {<_EOF_>} here_end_span_id: 772 stdin_parts: [ ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) <'\n'> ] ) ) (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {<'/DietPi/dietpi/.update_available'>} ) ] more_env: [] do_fork: T ) ] spids: [689 703] ) ] else_action: [] redirects: [] ) ] spids: [631 641] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ < 'Unable to access update servers. Please check your connection, then run dietpi-update again.' > ) } ) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>}) ] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'WHIP_BACKTITLE='> name:WHIP_BACKTITLE) op: assign_op.Equal rhs: {(SQ <DietPi-Update>)} spids: [818] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'WHIP_TITLE='> name:WHIP_TITLE) op: assign_op.Equal rhs: {($ Id.VSub_DollarName WHIP_BACKTITLE)} spids: [824] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'CHOICE='> name:CHOICE) op: assign_op.Equal rhs: {<0>} spids: [828] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'OPTION='> name:OPTION) op: assign_op.Equal rhs: {<0>} spids: [832] ) ] redirects: [] ) (command.ShFunction name: Menu_Update body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--yesno>} { (DQ <'Update available : https://goo.gl/G9ikqn\n'> <'Installed version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <'\n'> <'Latest version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) <'\n'> <'\n'> <'---------------------------------Notice-------------------------------------\n'> < 'The benefit of DietPi is we use standard linux configurations and commands. The downside is we can\'t possibly accommodate or predict, every modifcation to Linux configurations files by the end user, during the update.\n' > <'\n'> < 'Although we test the updates thoroughly, if you have made custom changes to Linux configuration files, outside of the DietPi programs, we highly recommend you create a backup of your system, before updating.\n' > <'\n'> <'You can create a system backup, by running:\n'> <' - dietpi-backup\n'> <'----------------------------------------------------------------------------\n'> <'\n'> <'Do you wish to continue and update DietPi to v'> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) <'?'> ) } {<--yes-button>} {(DQ <Ok>)} {<--no-button>} {(DQ <Exit>)} {<--defaultno>} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<24>} {<80>} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'CHOICE='> name:CHOICE) op: assign_op.Equal rhs: {($ Id.VSub_QMark '?')} spids: [908] ) ] redirects: [] ) (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_DollarName CHOICE)} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'RUN_UPDATE='> name:RUN_UPDATE) op: assign_op.Equal rhs: {<1>} spids: [930] ) ] redirects: [] ) ] spids: [912 926] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Run_Update body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.Simple words: [ {<curl>} {<-k>} {<-L>} { (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name URL_MIRROR_ZIP> var_name: URL_MIRROR_ZIP bracket_op: (bracket_op.ArrayIndex expr:{($ Id.VSub_DollarName URL_MIRROR_INDEX)}) right: <Id.Right_DollarBrace '}'> ) } ] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/update.zip'>} ) ] more_env: [] do_fork: T ) (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_QMark '?')} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<unzip>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/update.zip'>} {<-d>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/'>} ) (command.Simple words: [ {<rm>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/DietPi-'> (DQ ($ Id.VSub_DollarName GITBRANCH)) <'/dietpi/.'> <Id.Lit_Star '*'> } ] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (C {<cp>} {<-Rf>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP)) <'/DietPi-'> (DQ ($ Id.VSub_DollarName GITBRANCH)) <'/dietpi'> } {<'/DietPi/'>} ) (C {<chmod>} {<-R>} {<Id.Lit_Other '+'> <x>} {<'/DietPi'>}) (C {<'/DietPi/dietpi/func/dietpi-set_software'>} {<verify_dietpi.txt>}) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_Less left: {($ Id.VSub_DollarName SUBVERSION_CURRENT)} right: {($ Id.VSub_DollarName SUBVERSION_SERVER)} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) body: (command.DoGroup children: [ (C {<G_DIETPI-NOTIFY>} {<3>} {(SQ <'DietPi-Update Updating DietPi'>)}) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Current Version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Server Version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) <Id.Lit_BadBackslash '\\'> <n> ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Patching '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <' to '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> (word_part.ArithSub anode: (arith_expr.Binary op_id: Id.Arith_Plus left: {($ Id.VSub_DollarName SUBVERSION_CURRENT)} right: {<Id.Lit_Digits 1>} ) ) ) } ) (C {<'/DietPi/dietpi/patch_file'>} {($ Id.VSub_DollarName SUBVERSION_CURRENT)} {($ Id.VSub_DollarName SUBVERSION_SERVER)} ) (command.DParen child: (arith_expr.UnaryAssign op_id: Id.Node_PostDPlus child: ($ Id.Lit_ArithVarLike SUBVERSION_CURRENT) ) redirects: [] ) (command.Simple words: [{<cat>}] redirects: [ (redir op: <Id.Redir_DLess '<<'> loc: (redir_loc.Fd fd:0) arg: (redir_param.HereDoc here_begin: {<_EOF_>} here_end_span_id: 1228 stdin_parts: [ ($ Id.VSub_DollarName COREVERSION_CURRENT) <'\n'> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <'\n'> ] ) ) (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {<'/DietPi/dietpi/.version'>} ) ] more_env: [] do_fork: T ) (C {<G_DIETPI-NOTIFY>} {<0>} { (DQ <'Patch '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <' completed'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (C {<Get_Client_Version>}) ] ) redirects: [] ) (command.Simple words: [{<rm>} {<'/DietPi/dietpi/patch_file'>}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (command.Simple words: [{<rm>} {<'/DietPi/dietpi/server_version'>}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (command.Simple words: [{<rm>} {<-R>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP))}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) ] spids: [988 1002] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ < 'Download failed, unable to run update. Please try running dietpi-update again.' > ) } ) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<1>}) ] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (C {<G_DIETPI-NOTIFY>} {<3>} {<DietPi-Update>} {(SQ <'Checking for DietPi updates'>)}) (command.Simple words: [{<rm>} {<-R>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP))}] redirects: [(redir op:<Id.Redir_AndGreat '&>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})] more_env: [] do_fork: T ) (command.Simple words: [{<mkdir>} {<-p>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP))}] redirects: [(redir op:<Id.Redir_AndGreat '&>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})] more_env: [] do_fork: T ) (C {<Get_Client_Version>}) (C {<Get_Server_Version>}) (C {<Check_Update_Available>}) (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_DollarName INPUT)} right: {<Id.Lit_Digits 2>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Simple words: [ {<echo>} {<-e>} {(DQ <'Do nothing, now contained within Check_Update_Available()'>)} ] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) ] spids: [1425 1439] ) ] else_action: [ (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_DollarName SERVER_ONLINE)} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ <'Error - Server Offline'>)} {<--msgbox>} { (DQ <'http://github.com is either offline, or, unable to connect '> <Id.Lit_BadBackslash '\\'> <'n '> <Id.Lit_BadBackslash '\\'> <'n No updates applied.'> ) } {<12>} {<60>} ) ] spids: [1477 1491] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: {($ Id.VSub_DollarName UPDATE_REQUIRESNEWIMAGE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ <'New image required'>)} {<--msgbox>} { (DQ <' Your version of DietPi is now obsolete and cannot be updated. '> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'n Please download the latest DietPi image:'> <Id.Lit_BadBackslash '\\'> <'n - http://dietpi.com/downloads/images '> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'n - Current Version : '> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <' '> <Id.Lit_BadBackslash '\\'> <'n - Server Version : '> ($ Id.VSub_DollarName SUBVERSION_SERVER) <' '> <Id.Lit_BadBackslash '\\'> <'n '> ) } {<13>} {<70>} ) (C {<G_DIETPI-NOTIFY>} {<1>} {(DQ <'Your version of DietPi is now obsolete and cannot be updated.'>)} ) (C {<echo>} {<-e>} { (DQ <'Please download the latest DietPi image:'> <Id.Lit_BadBackslash '\\'> <'n - http://dietpi.com/download '> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'n - Current Version : '> ($ Id.VSub_DollarName SUBVERSION_CURRENT) <' '> <Id.Lit_BadBackslash '\\'> <'n - Server Version : '> ($ Id.VSub_DollarName SUBVERSION_SERVER) <' '> <Id.Lit_BadBackslash '\\'> <'n '> ) } ) ] spids: [1523 1537] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: {($ Id.VSub_DollarName UPDATE_AVAILABLE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<'/DietPi/dietpi/dietpi-drive_manager'>} {<2>}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_NEqual left: {($ Id.VSub_QMark '?')} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Simple words: [{<echo>} {<1>}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) ] spids: [1647 1661] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: {($ Id.VSub_DollarName INPUT)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<G_DIETPI-NOTIFY>} {<0>} {(DQ <'Updates have been found and are being applied, please wait...'>)} ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Current Version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Server Version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) ) } ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RUN_UPDATE='> name: RUN_UPDATE ) op: assign_op.Equal rhs: {<1>} spids: [1734] ) ] redirects: [] ) ] spids: [1682 1696] ) ] else_action: [(C {<Menu_Update>})] redirects: [] ) ] spids: [1620 1634] ) ] else_action: [ (C {<echo>} {<-e>} {(DQ )}) (C {<G_DIETPI-NOTIFY>} {<0>} { (DQ <'No updates required, your DietPi installation is up to date.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Current Version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Server Version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) ) } ) (C {<sleep>} {<2>}) ] redirects: [] ) (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_DollarName RUN_UPDATE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<'/DietPi/dietpi/dietpi-services'>} {<stop>}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.AndOr ops: [Id.Op_DAmp] children: [ (C {<Id.Lit_LBracket '['>} {<-f>} {<'/DietPi/dietpi/.installed'>} {<Id.Lit_RBracket ']'>} ) (command.DParen child: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<cat>} {<'/DietPi/dietpi/.installed'>}) (C {<grep>} {<-ci>} {<-m1>} {(SQ <'^aSOFTWARE_INSTALL_STATE\\[93\\]=2'>)} ) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } redirects: [] ) ] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<systemctl>} {<start>} {<dnsmasq>}) (C {<sleep>} {<2>})] spids: [1856 1893] ) ] else_action: [] redirects: [] ) (command.Simple words: [{<rm>} {(DQ ($ Id.VSub_DollarName FP_LOG))}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (command.Pipeline children: [(C {<Run_Update>}) (C {<tee>} {<-a>} {(DQ ($ Id.VSub_DollarName FP_LOG))})] negated: F stderr_indices: [] ) (command.Simple words: [{<echo>} {<0>}] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {<'/DietPi/dietpi/.update_stage'>} ) ] more_env: [] do_fork: T ) (command.Simple words: [{<rm>} {<'/DietPi/dietpi/.update_available'>}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) (C {<sync>}) (C {<G_DIETPI-NOTIFY>} {<3>} {<DietPi-Update>} {(DQ <Completed>)}) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Current Version : '> ($ Id.VSub_DollarName COREVERSION_CURRENT) <.> ($ Id.VSub_DollarName SUBVERSION_CURRENT) ) } ) (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'Server Version : '> ($ Id.VSub_DollarName COREVERSION_SERVER) <.> ($ Id.VSub_DollarName SUBVERSION_SERVER) ) } ) (C {<G_DIETPI-NOTIFY>} {<0>} {(DQ <'Update completed'>)}) (C {<echo>} {<-e>} {(DQ )}) (C {<echo>} {<-e>} { (DQ <'Please reboot your system now, using the command '> <Id.Lit_BadBackslash '\\'> <'e[31;49;1mreboot'> <Id.Lit_BadBackslash '\\'> <'e[0m'> ) } ) ] spids: [1824 1838] ) ] else_action: [] redirects: [] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<ps>} {<aux>}) (C {<grep>} {<-ci>} {<-m1>} {(SQ <'[l]xpanel'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<read>} {<-p>} {(DQ <'Press any key to exit DietPi-Update...'>)})] spids: [2062 2092] ) ] else_action: [] redirects: [] ) ] redirects: [] ) (command.Simple words: [{<rm>} {<-R>} {(DQ ($ Id.VSub_DollarName FILEPATH_TEMP))}] redirects: [(redir op:<Id.Redir_AndGreat '&>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})] more_env: [] do_fork: T ) (C {<unset>} {<URL_MIRROR_SERVERVERSION>}) (C {<unset>} {<URL_MIRROR_ZIP>}) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>}) ] redirects: [] right: <Id.Lit_RBrace '}'> )