(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: [95] ) ] 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: [122] ) ] redirects: [] ) ] spids: [99 119] ) ] 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-Backup>)}) (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-Backup>)} spids: [170] ) ] 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: {(SQ )} spids: [176] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'MENU_LASTITEM='> name:MENU_LASTITEM) op: assign_op.Equal rhs: {(SQ )} spids: [181] ) ] 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: [186] ) ] 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: [190] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'TARGETMENUID='> name:TARGETMENUID) op: assign_op.Equal rhs: {<0>} spids: [194] ) ] redirects: [] ) (command.ShFunction name: Menu_Main body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<local>} {<Id.Lit_VarLike 'backup_last_completed_system='> (SQ <'System backup not found. Create one.'>) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'backup_last_completed_system='> name: backup_last_completed_system ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<grep>} {(SQ <Completed>)} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } ) (C {<tail>} {<-1>}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } spids: [237] ) ] redirects: [] ) ] spids: [218 233] ) ] else_action: [] redirects: [] ) (C {<local>} {<Id.Lit_VarLike 'backup_last_completed_userdata='> (SQ <'User data backup not found (requires "Full" backup mode)'>) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'backup_last_completed_userdata='> name: backup_last_completed_userdata ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<grep>} {(SQ <Completed>)} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } ) (C {<tail>} {<-1>}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } spids: [291] ) ] redirects: [] ) ] spids: [272 287] ) ] else_action: [] redirects: [] ) (C {<local>} {<Id.Lit_VarLike 'text_backup_mode='> (SQ <'System only'>)}) (C {<local>} {<Id.Lit_VarLike 'text_start_mode_desc='> (SQ <system>)}) (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 BACKUP_MODE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'text_backup_mode='> name: text_backup_mode ) op: assign_op.Equal rhs: {(SQ <Full>)} spids: [352] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'text_start_mode_desc='> name: text_start_mode_desc ) op: assign_op.Equal rhs: {(SQ <'system and user data'>)} spids: [358] ) ] redirects: [] ) ] spids: [334 348] ) ] else_action: [] 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: {(SQ <DietPi-Backup>)} spids: [369] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'OPTION='> name:OPTION) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Simple words: [ {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--menu>} { (DQ <'Current backup and restore location:'> <Id.Lit_BadBackslash '\\'> <'n - '> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <'n - '> ($ Id.VSub_DollarName backup_last_completed_system) <Id.Lit_BadBackslash '\\'> <'n - '> ($ Id.VSub_DollarName backup_last_completed_userdata) ) } {<--cancel-button>} {(DQ <Exit>)} {<--default-item>} {(DQ ($ Id.VSub_DollarName MENU_LASTITEM))} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<16>} {<80>} {<5>} {(DQ <Help>)} {(DQ <'What does DietPi-Backup do?'>)} {(DQ <Location>)} {(DQ <'Change where your backup will be saved and restored from.'>)} {(DQ <'Backup mode'>)} {(DQ <': '> ($ Id.VSub_DollarName text_backup_mode))} {(DQ <Backup>)} {(DQ <'Create (or update) a backup of this system.'>)} {(DQ <Restore>)} {(DQ <'Restore this system from a previous backup.'>)} ] redirects: [ (redir op: <Id.Redir_GreatAnd '3>&'> loc: (redir_loc.Fd fd:3) arg: {<1>} ) (redir op: <Id.Redir_GreatAnd '1>&'> loc: (redir_loc.Fd fd:1) arg: {<2>} ) (redir op: <Id.Redir_GreatAnd '2>&'> loc: (redir_loc.Fd fd:2) arg: {<3>} ) ] more_env: [] do_fork: T ) right: <Id.Eof_RParen _> ) } spids: [375] ) ] redirects: [] ) (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: [487] ) ] 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 'MENU_LASTITEM='> name: MENU_LASTITEM ) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName OPTION))} spids: [509] ) ] redirects: [] ) (command.Case to_match: {(DQ ($ Id.VSub_DollarName OPTION))} arms: [ (case_arm pat_list: [{<Location>}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGETMENUID='> name: TARGETMENUID ) op: assign_op.Equal rhs: {<1>} spids: [531] ) ] redirects: [] ) ] spids: [526 527 536 -1] ) (case_arm pat_list: [{(DQ <'Backup mode'>)}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'OPTION='> name:OPTION) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Simple words: [ {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--menu>} { (DQ <'Please select a backup mode:'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'n - System only'> <Id.Lit_BadBackslash '\\'> < 'nOnly the system is backed up and restored, this does not include your DietPi user data (' > ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA) <').'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'n - Full:'> <Id.Lit_BadBackslash '\\'> <'nSystem and user data ('> ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA) <') is backed up and restored.'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nMore information on what DietPi user data is:'> <Id.Lit_BadBackslash '\\'> <'nhttp://dietpi.com/phpbb/viewtopic.php?f=8&t=478#p2087'> ) } {<--cancel-button>} {(DQ <Exit>)} {<--default-item>} {(DQ ($ Id.VSub_DollarName BACKUP_MODE))} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<20>} {<80>} {<2>} {(DQ <0>)} {(DQ <'System only'>)} {(DQ <1>)} {(DQ <'Full (includes user data)'>)} ] redirects: [ (redir op: <Id.Redir_GreatAnd '3>&'> loc: (redir_loc.Fd fd:3) arg: {<1>} ) (redir op: <Id.Redir_GreatAnd '1>&'> loc: (redir_loc.Fd fd:1) arg: {<2>} ) (redir op: <Id.Redir_GreatAnd '2>&'> loc: (redir_loc.Fd fd:2) arg: {<3>} ) ] more_env: [] do_fork: T ) right: <Id.Eof_RParen _> ) } spids: [547] ) ] redirects: [] ) (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: [640] ) ] 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 'BACKUP_MODE='> name: BACKUP_MODE ) op: assign_op.Equal rhs: {($ Id.VSub_DollarName OPTION)} spids: [662] ) ] redirects: [] ) ] spids: [644 658] ) ] else_action: [] redirects: [] ) ] spids: [540 543 671 -1] ) (case_arm pat_list: [{<Help>}] action: [ (C {<whiptail>} {<--title>} {(DQ <'DietPi-Backup Help'>)} {<--msgbox>} { (DQ < 'DietPi-Backup is a program that allows you to Backup and Restore your DietPi system.' > <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> < 'nIf you have broken your system, or want to reset your system to an earlier date, this can all be done with DietPi-Backup.' > <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> < 'nSimply choose a location where you want to save and restore your backups from, then, select Backup or Restore.' > <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nMore information:'> <Id.Lit_BadBackslash '\\'> <'n - http://dietpi.com/phpbb/viewtopic.php?f=8&t=5&p=256#p255'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<20>} {<75>} ) ] spids: [675 676 720 -1] ) (case_arm pat_list: [{<Backup>}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'WHIP_TITLE='> name: WHIP_TITLE ) op: assign_op.Equal rhs: {(SQ <' Start backup? '>)} spids: [729] ) ] redirects: [] ) (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--yesno>} { (DQ <'Your '> ($ Id.VSub_DollarName text_start_mode_desc) <' will be backed up to:'> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nDo you wish to continue?'> ) } {<--yes-button>} {(DQ <Ok>)} {<--no-button>} {(DQ <Back>)} {<--defaultno>} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<65>} ) (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: [783] ) ] 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: [(C {<Run_Backup>})] spids: [787 801] ) ] else_action: [] redirects: [] ) ] spids: [724 725 813 -1] ) (case_arm pat_list: [{<Restore>}] action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'WHIP_TITLE='> name: WHIP_TITLE ) op: assign_op.Equal rhs: {(SQ <' Start restore? '>)} spids: [822] ) ] redirects: [] ) (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--yesno>} { (DQ <'Your '> ($ Id.VSub_DollarName text_start_mode_desc) <' will be restored from:'> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nDo you wish to continue?'> ) } {<--yes-button>} {(DQ <Ok>)} {<--no-button>} {(DQ <Back>)} {<--defaultno>} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<65>} ) (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: [876] ) ] 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: [(C {<Run_Restore>})] spids: [880 894] ) ] else_action: [] redirects: [] ) ] spids: [817 818 906 -1] ) ] redirects: [] ) ] spids: [491 505] ) ] else_action: [(C {<Menu_Exit>})] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Menu_Exit body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'WHIP_TITLE='> name:WHIP_TITLE) op: assign_op.Equal rhs: {(SQ <' Exit DietPi-Backup? '>)} spids: [937] ) ] redirects: [] ) (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--yesno>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--yes-button>} {(DQ <Ok>)} {<--no-button>} {(DQ <Back>)} {<--defaultno>} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<10>} {<50>} ) (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: [982] ) ] 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 'TARGETMENUID='> name: TARGETMENUID ) op: assign_op.Equal rhs: {<-1>} spids: [1009] ) ] redirects: [] ) ] spids: [991 1005] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Menu_Set_Directory body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<local>} {<Id.Lit_VarLike 'current_directory='> (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'WHIP_TITLE='> name:WHIP_TITLE) op: assign_op.Equal rhs: {(SQ <'Select your backup and restore location'>)} spids: [1042] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'OPTION='> name:OPTION) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Simple words: [ {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName WHIP_TITLE))} {<--menu>} { (DQ < 'Please select the location where your system backup will be saved, and restored from.' > <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nYour current location:'> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName FP_TARGET_BACKUP) ) } {<--cancel-button>} {(DQ <Back>)} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<15>} {<75>} {<3>} {(DQ <Search>)} {(DQ <'Find previous backups in /mnt/*'>)} {(DQ <List>)} {(DQ <'Select from a list of available mounts/drives'>)} {(DQ <Manual>)} {(DQ <'Manually type a directory to use.'>)} ] redirects: [ (redir op: <Id.Redir_GreatAnd '3>&'> loc: (redir_loc.Fd fd:3) arg: {<1>} ) (redir op: <Id.Redir_GreatAnd '1>&'> loc: (redir_loc.Fd fd:1) arg: {<2>} ) (redir op: <Id.Redir_GreatAnd '2>&'> loc: (redir_loc.Fd fd:2) arg: {<3>} ) ] more_env: [] do_fork: T ) right: <Id.Eof_RParen _> ) } spids: [1048] ) ] redirects: [] ) (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: [1130] ) ] 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.Case to_match: {(DQ ($ Id.VSub_DollarName OPTION))} arms: [ (case_arm pat_list: [{<Search>}] action: [ (C {<local>} {<Id.Lit_VarLike 'fp_search_results='> (DQ <'/tmp/.dietpi-backup_search_results'>) } ) (C {<echo>} {<-e>} { (DQ <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nSearching /mnt/* for previous backups, please wait... '> <Id.Lit_BadBackslash '\\'> <'n '> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<find>} {<'/mnt'>} {<-type>} {<f>} {<-name>} {(DQ ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM))} ] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName fp_search_results))} ) ] 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_Great left: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<cat>} { (DQ ($ Id.VSub_DollarName fp_search_results ) ) } ) (C {<wc>} {<-l>}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Simple words: [{<readarray>} {<search_results_list>}] redirects: [ (redir op: <Id.Redir_Less '<'> loc: (redir_loc.Fd fd:0) arg: {(DQ ($ Id.VSub_DollarName fp_search_results))} ) ] more_env: [] do_fork: T ) (C {<local>} {<Id.Lit_VarLike 'search_results_whiptail='> (sh_array_literal left: <Id.Op_LParen _> words: [] ) } ) (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 search_results_list> var_name: search_results_list 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: [ (C {<local>} {<Id.Lit_VarLike 'last_backup_date='> (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<grep>} {(SQ <Completed>)} { (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name search_results_list> var_name: search_results_list bracket_op: (bracket_op.ArrayIndex expr: {($ Id.VSub_DollarName i)} ) right: <Id.Right_DollarBrace '}'> ) } ) (C {<tail>} {<-1>}) (C {<sed>} {(SQ <'s/.*: //'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } ) (C {<local>} {<Id.Lit_VarLike 'backup_directory='> (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<echo>} {<-e>} { (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name search_results_list> var_name: search_results_list bracket_op: (bracket_op.ArrayIndex expr: {($ Id.VSub_DollarName i)} ) right: <Id.Right_DollarBrace '}'> ) } ) (C {<sed>} {(SQ <'s/\\/'>) (DQ ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM ) ) (SQ <'//g'>) } ) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'search_results_whiptail+='> name: search_results_whiptail ) op: assign_op.PlusEqual rhs: { (sh_array_literal left: <Id.Op_LParen _> words: [ { (DQ ($ Id.VSub_DollarName backup_directory) ) } { (DQ <': '> ($ Id.VSub_DollarName last_backup_date) ) } ] ) } spids: [1373] ) ] redirects: [] ) ] ) redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'OPTION='> name: OPTION ) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Simple words: [ {<whiptail>} {<--title>} {(DQ <'Backups found.'>)} {<--menu>} { (DQ < 'Please select a previous backup to use:' > ) } {<--cancel-button>} {(DQ <Back>)} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<12>} {<70>} {<3>} { (DQ (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name search_results_whiptail> var_name: search_results_whiptail bracket_op: (bracket_op.WholeArray op_id: Id.Lit_At ) right: <Id.Right_DollarBrace '}'> ) ) } ] redirects: [ (redir op: <Id.Redir_GreatAnd '3>&'> loc: (redir_loc.Fd fd:3) arg: {<1>} ) (redir op: <Id.Redir_GreatAnd '1>&'> loc: (redir_loc.Fd fd:1) arg: {<2>} ) (redir op: <Id.Redir_GreatAnd '2>&'> loc: (redir_loc.Fd fd:2) arg: {<3>} ) ] more_env: [] do_fork: T ) right: <Id.Eof_RParen _> ) } spids: [1391] ) ] redirects: [] ) (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: [1445] ) ] 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 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName OPTION))} spids: [1467] ) ] redirects: [] ) ] spids: [1449 1463] ) ] else_action: [] redirects: [] ) (C {<unset>} {<search_results_list>}) (C {<unset>} {<search_results_whiptail>}) (command.Simple words: [{<rm>} {(DQ ($ Id.VSub_DollarName fp_search_results))}] redirects: [ (redir op: <Id.Redir_AndGreat '&>'> loc: (redir_loc.Fd fd:1) arg: {<'/dev/null'>} ) ] more_env: [] do_fork: T ) ] spids: [1218 1244] ) ] else_action: [ (C {<whiptail>} {<--title>} {(DQ <'No results'>)} {<--msgbox>} {(DQ <'No previous backups were found in /mnt/*'>)} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<10>} {<60>} ) ] redirects: [] ) ] spids: [1163 1164 1538 -1] ) (case_arm pat_list: [{<Manual>}] action: [(C {<Input_User_Directory>})] spids: [1542 1543 1551 -1] ) (case_arm pat_list: [{<List>}] action: [ (C {<'/DietPi/dietpi/dietpi-drive_manager'>} {<1>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<cat>} {<'/tmp/dietpi-drive_manager_selmnt'>}) right: <Id.Eof_RParen _> ) ) } spids: [1565] ) ] redirects: [] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} {<Id.Lit_Equals '='>} {(DQ <'/'>)} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: {(SQ <'/mnt'>)} spids: [1596] ) ] redirects: [] ) ] spids: [1575 1592] ) ] else_action: [] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_TARGET_BACKUP+='> name: FP_TARGET_BACKUP ) op: assign_op.PlusEqual rhs: {(SQ <'/dietpi-backup'>)} spids: [1607] ) ] redirects: [] ) ] spids: [1555 1556 1614 -1] ) ] redirects: [] ) ] spids: [1135 1149] ) ] else_action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'TARGETMENUID='> name:TARGETMENUID) op: assign_op.Equal rhs: {<0>} spids: [1630] ) ] redirects: [] ) ] redirects: [] ) (C {<Check_Supported_Directory_Location>}) (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 TARGET_DIRECTORY_SUPPORTED)} 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 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName current_directory))} spids: [1664] ) ] redirects: [] ) ] spids: [1646 1660] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Input_User_Directory body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'OPTION='> name:OPTION) op: assign_op.Equal rhs: { (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Simple words: [ {<whiptail>} {<--inputbox>} { (DQ <'Please enter the filepath to your directory. '> <Id.Lit_BadBackslash '\\'> <'neg: /mnt/dietpi-backup'> <Id.Lit_BadBackslash '\\'> <'n - Must be located inside /mnt/* '> <Id.Lit_BadBackslash '\\'> <'n - Must be symlink compatible filesystem (ext2/3/4)'> ) } {<10>} {<70>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} {<--title>} {(DQ <'Manual backup directory'>)} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} ] redirects: [ (redir op: <Id.Redir_GreatAnd '3>&'> loc: (redir_loc.Fd fd:3) arg: {<1>} ) (redir op: <Id.Redir_GreatAnd '1>&'> loc: (redir_loc.Fd fd:1) arg: {<2>} ) (redir op: <Id.Redir_GreatAnd '2>&'> loc: (redir_loc.Fd fd:2) arg: {<3>} ) ] more_env: [] do_fork: T ) right: <Id.Eof_RParen _> ) } spids: [1686] ) ] redirects: [] ) (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: [1733] ) ] 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 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: {(DQ ($ Id.VSub_DollarName OPTION))} spids: [1755] ) ] redirects: [] ) ] spids: [1737 1751] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Error_Filesystem_Not_Supported body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<G_DIETPI-NOTIFY>} {<1>} {(DQ <'Filesystem not supported in '> ($ Id.VSub_DollarName FP_TARGET_BACKUP))} ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ <Error>)} {<--msgbox>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <' Has a filesystem of: '> ($ Id.VSub_DollarName TARGET_FILESYSTEM_TYPE) <', and is not supported.'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nThe filesystem must be EXT2/3/4 for symlink compatibility.'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<70>} ) ] spids: [1800 1810] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Error_Not_Mnt_Directory body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ <'Target directory is not inside /mnt ('> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <')'> ) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ <'Directory not supported'>)} {<--msgbox>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nYour current location is not supported.'> <Id.Lit_BadBackslash '\\'> <'nThe location must be inside the /mnt/* directory.'> <Id.Lit_BadBackslash '\\'> <'n - eg: /mnt/dietpi-backup'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<70>} ) ] spids: [1874 1884] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Error_DietpiUserdata_Directory body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ <'Target directory can not be contained within DietPi user data location ('> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <')'> ) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ <'Directory not supported'>)} {<--msgbox>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nYour current location is not supported.'> <Id.Lit_BadBackslash '\\'> < 'nTarget directory can not be contained within DietPi user data location (' > ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA) <')'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<13>} {<70>} ) ] spids: [1949 1959] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Error_Rsync_Already_Running body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<G_DIETPI-NOTIFY>} {<1>} {(DQ <'Another Rsync process is already running.'>)}) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' failed: '> (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<date>} {<Id.Lit_Other '+'> (DQ <'%d-%m-%Y_%H%M'>)}) right: <Id.Eof_RParen _> ) <'. Rsync is already running.'> ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } ) ] more_env: [] do_fork: T ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Error'>)} {<--msgbox>} { (DQ <'A '> ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' could not be started as rsync is already running.'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<13>} {<60>} ) ] spids: [2054 2064] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Error_Rsync_Failed body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<G_DIETPI-NOTIFY>} {<1>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' failed.'>)}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' failed'>)} {<--msgbox>} { (DQ <'Your '> ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' has failed. Please see the Log file for more information:'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName LOGFILE) ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<12>} {<60>} ) ] spids: [2127 2137] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name:RSYNC_MODE_TEXT) op: assign_op.Equal rhs: {<0>} spids: [2195] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'BACKUP_MODE='> name:BACKUP_MODE) op: assign_op.Equal rhs: {<1>} spids: [2199] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'LOGFILE='> name:LOGFILE) op: assign_op.Equal rhs: {(SQ <'/var/log/dietpi-backup.log'>)} spids: [2211] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FP_SOURCE_SYSTEM='> name:FP_SOURCE_SYSTEM) op: assign_op.Equal rhs: {(SQ <'/'>)} spids: [2222] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FP_TARGET_BACKUP='> name:FP_TARGET_BACKUP) op: assign_op.Equal rhs: {(SQ <'/mnt/dietpi-backup'>)} spids: [2228] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'G_FP_DIETPI_USERDATA_ACTUAL='> name: G_FP_DIETPI_USERDATA_ACTUAL ) op: assign_op.Equal rhs: { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<readlink>} {<-f>} {<'/mnt/dietpi_userdata'>}) right: <Id.Eof_RParen _> ) ) } spids: [2234] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_STATS_FILENAME_SYSTEM='> name: BACKUP_STATS_FILENAME_SYSTEM ) op: assign_op.Equal rhs: {(SQ <.dietpi-backup_system_stats>)} spids: [2251] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_STATS_FILENAME_USERDATA='> name: BACKUP_STATS_FILENAME_USERDATA ) op: assign_op.Equal rhs: {(SQ <.dietpi-backup_userdata_stats>)} spids: [2257] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP='> name: FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP ) op: assign_op.Equal rhs: {(SQ <'/tmp/.dietpi-backup_filter_inc_exc'>)} spids: [2268] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FP_EXCLUDE_USER='> name:FP_EXCLUDE_USER) op: assign_op.Equal rhs: {(SQ <'/DietPi/dietpi/.dietpi-backup_exclude'>)} spids: [2274] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left:<Id.Lit_VarLike 'FP_INCLUDE_USER='> name:FP_INCLUDE_USER) op: assign_op.Equal rhs: {(SQ <'/DietPi/dietpi/.dietpi-backup_include'>)} spids: [2280] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGET_FILESYSTEM_TYPE='> name: TARGET_FILESYSTEM_TYPE ) op: assign_op.Equal rhs: {<0>} spids: [2291] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGET_DIRECTORY_SUPPORTED='> name: TARGET_DIRECTORY_SUPPORTED ) op: assign_op.Equal rhs: {<0>} spids: [2295] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'aSUPPORTED_FILESYSTEMS='> name: aSUPPORTED_FILESYSTEMS ) op: assign_op.Equal rhs: { (sh_array_literal left: <Id.Op_LParen _> words: [{(SQ <ext4>)} {(SQ <ext3>)} {(SQ <ext2>)} {(SQ <nfs>)} {(SQ <nfs4>)} {(SQ <btrfs>)}] ) } spids: [2299] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_RUN_OPTIONS_SYSTEM_BACKUP='> name: RSYNC_RUN_OPTIONS_SYSTEM_BACKUP ) op: assign_op.Equal rhs: { (DQ <'-alHpvP --delete --log-file='> ($ Id.VSub_DollarName LOGFILE) <' --include-from='> ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP) ) } spids: [2341] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_RUN_OPTIONS_USERDATA_BACKUP='> name: RSYNC_RUN_OPTIONS_USERDATA_BACKUP ) op: assign_op.Equal rhs: {(DQ <'-alHpvP --delete --log-file='> ($ Id.VSub_DollarName LOGFILE))} spids: [2350] ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<0>} spids: [2362] ) ] redirects: [] ) (command.ShFunction name: Print_Date body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (C {<echo>} {<-e>} { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<date>} {<Id.Lit_Other '+'> (DQ <'%d-%m-%Y %H:%M'>)}) right: <Id.Eof_RParen _> ) ) } ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Create_Filter_Include_Exclude body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (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: 2426 stdin_parts: [<'#INCLUDE\n'> <'#Global - Folders\n'> <'#+ /example/\n'>] ) ) (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))} ) ] more_env: [] do_fork: T ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} {(DQ ($ Id.VSub_DollarName FP_INCLUDE_USER))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Simple words: [{<echo>} {<-e>} {(DQ <Id.Lit_BadBackslash '\\'> <'n#User include file'>)}] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))} ) ] more_env: [] do_fork: T ) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands:[(C {<read>} {<-r>} {<line>})]) body: (command.DoGroup children: [ (command.Simple words: [{<echo>} {<-e>} {(DQ <'+ '> ($ Id.VSub_DollarName line))}] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP) ) } ) ] more_env: [] do_fork: T ) ] ) redirects: [ (redir op: <Id.Redir_Less '<'> loc: (redir_loc.Fd fd:0) arg: {(DQ ($ Id.VSub_DollarName FP_INCLUDE_USER))} ) ] ) ] spids: [2433 2446] ) ] else_action: [] 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: 2569 stdin_parts: [ <'\n'> <'#EXCLUDE\n'> <'#Global - Folders\n'> <'- '> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/\n'> <'- /mnt/\n'> <'- /media/\n'> <'- /dev/\n'> <'- /proc/\n'> <'- /sys/\n'> <'- /tmp/\n'> <'- /run/\n'> <'\n'> <'#Apt package cache (.deb)\n'> <'- /var/cache/apt/archives/\n'> <'\n'> <'#Manpages / Docs\n'> <'- /usr/share/man/\n'> <'- /usr/share/doc/\n'> <'\n'> <'#Global - Files\n'> <'- '> ($ Id.VSub_DollarName LOGFILE) <'\n'> <'- '> ($ Id.VSub_DollarName FP_DIETPIBACKUP_SETTINGS) <'\n'> <'- '> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) <'\n'> <'- '> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) <'\n'> <'- /var/swap\n'> <'- fake-hwclock.data\n'> <'- *.tmp\n'> <'\n'> <'#MS Windows specific\n'> <'- Thumbs.db\n'> <'- desktop.ini\n'> ] ) ) (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))} ) ] more_env: [] do_fork: T ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} {(DQ ($ Id.VSub_DollarName FP_EXCLUDE_USER))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.Simple words: [{<echo>} {<-e>} {(DQ <Id.Lit_BadBackslash '\\'> <'n#User exclude file'>)}] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))} ) ] more_env: [] do_fork: T ) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands:[(C {<read>} {<-r>} {<line>})]) body: (command.DoGroup children: [ (command.Simple words: [{<echo>} {<-e>} {(DQ <'- '> ($ Id.VSub_DollarName line))}] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP) ) } ) ] more_env: [] do_fork: T ) ] ) redirects: [ (redir op: <Id.Redir_Less '<'> loc: (redir_loc.Fd fd:0) arg: {(DQ ($ Id.VSub_DollarName FP_EXCLUDE_USER))} ) ] ) ] spids: [2576 2589] ) ] else_action: [] redirects: [] ) (C {<cp>} {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))} {<'/tmp/.dietpi-backup_inc_exc_list'>} ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Services_Stop body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [(C {<'/DietPi/dietpi/dietpi-services'>} {<stop>})] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Services_Start body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [(C {<'/DietPi/dietpi/dietpi-services'>} {<start>})] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Run_Backup body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(DQ <Backup>)} spids: [2708] ) ] redirects: [] ) (C {<G_DIETPI-NOTIFY>} {<3>} {<DietPi-Backup>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT))}) (C {<Check_Supported_Directory_Location>}) (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 TARGET_DIRECTORY_SUPPORTED)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<mkdir>} {<-p>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-d>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' failed.'>)} {<--msgbox>} {(DQ <'Unable to create '> ($ Id.VSub_DollarName FP_TARGET_BACKUP))} {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<10>} {<60>} ) ] spids: [2794 2804] ) ] else_action: [] redirects: [] ) ] spids: [2775 2790] ) (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>} {(DQ <'[r]sync'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_Rsync_Already_Running>})] spids: [2844 2874] ) ] else_action: [ (command.Simple words: [ {<echo>} {<-e>} { (DQ <'DietPi-Backup Log File. '> (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<date>} {<Id.Lit_Other '+'> (DQ <'%d-%m-%Y_%H%M'>)}) right: <Id.Eof_RParen _> ) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <n> ) } ] redirects: [ (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName LOGFILE))} ) ] more_env: [] do_fork: T ) (C {<Create_Filter_Include_Exclude>}) (C {<Services_Stop>}) (C {<G_DIETPI-NOTIFY>} {<2>} {(DQ <'Backing up to: '> ($ Id.VSub_DollarName FP_TARGET_BACKUP))} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<0>} spids: [2942] ) ] redirects: [] ) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands:[(C {<true>})]) body: (command.DoGroup children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <'Backup (system)'>)} spids: [2960] ) ] redirects: [] ) (C {<rsync>} {($ Id.VSub_DollarName RSYNC_RUN_OPTIONS_SYSTEM_BACKUP)} {(DQ ($ Id.VSub_DollarName FP_SOURCE_SYSTEM))} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP)) <'/dietpi-backup_system/'>} ) (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 {<G_DIETPI-NOTIFY>} {<0>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM ) ) } ) ] more_env: [] do_fork: T ) ] spids: [2981 2995] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } ) ] more_env: [] do_fork: T ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<1>} spids: [3071] ) ] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <'Backup (user data)'>)} spids: [3087] ) ] 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 BACKUP_MODE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<rsync>} {($ Id.VSub_DollarName RSYNC_RUN_OPTIONS_USERDATA_BACKUP)} {(DQ ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA_ACTUAL)) <'/'>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP)) <'/dietpi-backup_userdata/'> } ) (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 {<G_DIETPI-NOTIFY>} {<0>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } ) ] more_env: [] do_fork: T ) ] spids: [3127 3141] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } ) ] more_env: [] do_fork: T ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<1>} spids: [3217] ) ] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] redirects: [] ) ] spids: [3094 3108] ) ] else_action: [] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] ) redirects: [] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName BACKUP_RESTORE_FAILED)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_Rsync_Failed>})] spids: [3245 3255] ) ] else_action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <Backup>)} spids: [3281] ) ] redirects: [] ) (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' completed'>)} {<--msgbox>} { (DQ <'Your '> ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' was saved to:'> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nLog file: '> ($ Id.VSub_DollarName LOGFILE) ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<60>} ) ] spids: [3267 3277] ) ] else_action: [] redirects: [] ) ] redirects: [] ) (C {<Services_Start>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGETMENUID='> name: TARGETMENUID ) op: assign_op.Equal rhs: {<0>} spids: [3340] ) ] redirects: [] ) ] redirects: [] ) ] spids: [2739 2753] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Run_Restore body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(DQ <Restore>)} spids: [3363] ) ] redirects: [] ) (C {<G_DIETPI-NOTIFY>} {<3>} {<DietPi-Backup>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT))}) (C {<Check_Supported_Directory_Location>}) (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 TARGET_DIRECTORY_SUPPORTED)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-f>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ <'No Backup was found in '> ($ Id.VSub_DollarName FP_TARGET_BACKUP) ) } ) (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Failed.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' failed'>)} {<--msgbox>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) <' does not exist'> <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nHave you created a backup?'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<11>} {<70>} ) ] spids: [3459 3469] ) ] else_action: [] redirects: [] ) ] spids: [3416 3433] ) (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>} {(DQ <'[r]sync'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) } right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_Rsync_Already_Running>})] spids: [3515 3545] ) ] else_action: [ (C {<Create_Filter_Include_Exclude>}) (C {<Services_Stop>}) (C {<G_DIETPI-NOTIFY>} {<2>} {(DQ <'Restoring from: '> ($ Id.VSub_DollarName FP_TARGET_BACKUP))} ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<0>} spids: [3584] ) ] redirects: [] ) (command.WhileUntil keyword: <Id.KW_While while> cond: (condition.Shell commands:[(C {<true>})]) body: (command.DoGroup children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <'Restore (system)'>)} spids: [3602] ) ] redirects: [] ) (C {<rsync>} {($ Id.VSub_DollarName RSYNC_RUN_OPTIONS_SYSTEM_BACKUP)} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP)) <'/dietpi-backup_system/'> } {(DQ ($ Id.VSub_DollarName FP_SOURCE_SYSTEM))} ) (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 {<G_DIETPI-NOTIFY>} {<0>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM ) ) } ) ] more_env: [] do_fork: T ) ] spids: [3623 3637] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_SYSTEM) ) } ) ] more_env: [] do_fork: T ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED='> name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<1>} spids: [3712] ) ] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <'Restore (user data)'>)} spids: [3728] ) ] 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 BACKUP_MODE)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<rsync>} { ($ Id.VSub_DollarName RSYNC_RUN_OPTIONS_USERDATA_BACKUP ) } {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP)) <'/dietpi-backup_userdata/'>} { (DQ ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA_ACTUAL ) ) <'/'> } ) (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 {<G_DIETPI-NOTIFY>} {<0>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' Completed : '> (command_sub left_token: <Id.Left_DollarParen '$('> child: (C {<Print_Date>}) right: <Id.Eof_RParen _> ) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP ) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } ) ] more_env: [] do_fork: T ) ] spids: [3791 3805] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<1>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED.'> <Id.Lit_BadBackslash '\\'> <n> ) } ) (command.Simple words: [ {<echo>} {<-e>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' FAILED : '> (command_sub left_token:<Id.Left_DollarParen '$('> child:(C {<Print_Date>}) right:<Id.Eof_RParen _>) ) } ] redirects: [ (redir op: <Id.Redir_DGreat '>>'> loc: (redir_loc.Fd fd:1) arg: { (DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP ) <'/'> ($ Id.VSub_DollarName BACKUP_STATS_FILENAME_USERDATA) ) } ) ] more_env: [] do_fork: T ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'BACKUP_RESTORE_FAILED=' > name: BACKUP_RESTORE_FAILED ) op: assign_op.Equal rhs: {<1>} spids: [3880] ) ] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] redirects: [] ) ] spids: [3757 3772] ) ] else_action: [ (C {<G_DIETPI-NOTIFY>} {<2>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <': No backup exists, skipping...'> <Id.Lit_BadBackslash '\\'> <n> ) } ) ] redirects: [] ) ] spids: [3735 3749] ) ] else_action: [] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] ) redirects: [] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName BACKUP_RESTORE_FAILED)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_Rsync_Failed>})] spids: [3929 3939] ) ] else_action: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: {($ Id.VSub_DollarName G_USER_INPUTS)} redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'RSYNC_MODE_TEXT='> name: RSYNC_MODE_TEXT ) op: assign_op.Equal rhs: {(SQ <Restore>)} spids: [3965] ) ] redirects: [] ) (C {<whiptail>} {<--title>} {(DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' completed'>)} {<--msgbox>} { (DQ ($ Id.VSub_DollarName RSYNC_MODE_TEXT) <' completed from:'> <Id.Lit_BadBackslash '\\'> <n> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nLog file: '> ($ Id.VSub_DollarName LOGFILE) <Id.Lit_BadBackslash '\\'> <n> <Id.Lit_BadBackslash '\\'> <'nA Reboot is required.'> ) } {<--backtitle>} {(DQ ($ Id.VSub_DollarName WHIP_BACKTITLE))} {<13>} {<60>} ) ] spids: [3951 3961] ) ] else_action: [] redirects: [] ) ] redirects: [] ) (C {<Services_Start>}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGETMENUID='> name: TARGETMENUID ) op: assign_op.Equal rhs: {<0>} spids: [4027] ) ] redirects: [] ) ] redirects: [] ) ] spids: [3394 3408] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Check_Install_PreReqs body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [(C {<G_AG_CHECK_INSTALL_PREREQ>} {<rsync>})] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Check_Supported_Directory_Location body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGET_DIRECTORY_SUPPORTED='> name: TARGET_DIRECTORY_SUPPORTED ) op: assign_op.Equal rhs: {<0>} spids: [4068] ) ] redirects: [] ) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.AndOr ops: [Id.Op_DPipe] children: [ (command.DBracket expr: (bool_expr.Binary op_id: Id.BoolBinary_GlobDEqual left: {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} right: {(DQ ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA)) <Id.Lit_Other '*'> } ) redirects: [] ) (command.DBracket expr: (bool_expr.Binary op_id: Id.BoolBinary_GlobDEqual left: {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} right: {(DQ ($ Id.VSub_DollarName G_FP_DIETPI_USERDATA_ACTUAL)) <Id.Lit_Other '*'> } ) redirects: [] ) ] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_DietpiUserdata_Directory>})] spids: [4077 4113] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DBracket expr: (bool_expr.Binary op_id: Id.BoolBinary_GlobDEqual left: {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} right: {(DQ <'/mnt/'>) <Id.Lit_Other '*'>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<local>} {<Id.Lit_VarLike 'directory_generated='> <0>}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<Id.KW_Bang '!'>} {<-d>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (C {<mkdir>} {<-p>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))}) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'directory_generated='> name: directory_generated ) op: assign_op.Equal rhs: {<1>} spids: [4185] ) ] redirects: [] ) ] spids: [4157 4172] ) ] else_action: [] redirects: [] ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGET_FILESYSTEM_TYPE='> name: TARGET_FILESYSTEM_TYPE ) op: assign_op.Equal rhs: { (DQ (command_sub left_token: <Id.Left_DollarParen '$('> child: (command.Pipeline children: [ (C {<df>} {<-T>} {($ Id.VSub_DollarName FP_TARGET_BACKUP)}) (C {<sed>} {<-n>} {(SQ <2p>)}) (C {<awk>} {(SQ <'{print $2}'>)}) ] negated: F stderr_indices: [] ) right: <Id.Eof_RParen _> ) ) } spids: [4194] ) ] redirects: [] ) (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 aSUPPORTED_FILESYSTEMS> var_name: aSUPPORTED_FILESYSTEMS 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.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {(DQ ($ Id.VSub_DollarName TARGET_FILESYSTEM_TYPE))} {<Id.Lit_Equals '='>} { (DQ (braced_var_sub left: <Id.Left_DollarBrace '${'> token: <Id.VSub_Name aSUPPORTED_FILESYSTEMS> var_name: aSUPPORTED_FILESYSTEMS bracket_op: (bracket_op.ArrayIndex expr: {($ Id.VSub_DollarName i)} ) right: <Id.Right_DollarBrace '}'> ) ) } {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'TARGET_DIRECTORY_SUPPORTED='> name: TARGET_DIRECTORY_SUPPORTED ) op: assign_op.Equal rhs: {<1>} spids: [4280] ) ] redirects: [] ) (command.ControlFlow token: <Id.ControlFlow_Break break> ) ] spids: [4254 4276] ) ] else_action: [] redirects: [] ) ] ) 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 directory_generated)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<rm>} {<-R>} {(DQ ($ Id.VSub_DollarName FP_TARGET_BACKUP))})] spids: [4300 4314] ) ] 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: {($ Id.VSub_DollarName TARGET_DIRECTORY_SUPPORTED)} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Error_Filesystem_Not_Supported>})] spids: [4336 4350] ) ] else_action: [] redirects: [] ) ] spids: [4125 4143] ) ] else_action: [(C {<Error_Not_Mnt_Directory>})] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_DIETPIBACKUP_SETTINGS='> name: FP_DIETPIBACKUP_SETTINGS ) op: assign_op.Equal rhs: {(DQ <'/DietPi/dietpi/.dietpi-backup_settings'>)} spids: [4398] ) ] redirects: [] ) (command.ShFunction name: Write_Settings_File body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (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: 4431 stdin_parts: [ <'FP_TARGET_BACKUP='> ($ Id.VSub_DollarName FP_TARGET_BACKUP) <'\n'> <'BACKUP_MODE='> ($ Id.VSub_DollarName BACKUP_MODE) <'\n'> ] ) ) (redir op: <Id.Redir_Great '>'> loc: (redir_loc.Fd fd:1) arg: {(DQ ($ Id.VSub_DollarName FP_DIETPIBACKUP_SETTINGS))} ) ] more_env: [] do_fork: T ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (command.ShFunction name: Read_Settings_File body: (BraceGroup left: <Id.Lit_LBrace '{'> children: [ (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-f>} {(DQ ($ Id.VSub_DollarName FP_DIETPIBACKUP_SETTINGS))} {<Id.Lit_RBracket ']'>} ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<.>} {(DQ ($ Id.VSub_DollarName FP_DIETPIBACKUP_SETTINGS))})] spids: [4445 4458] ) ] else_action: [] redirects: [] ) ] redirects: [] right: <Id.Lit_RBrace '}'> ) ) (C {<Check_Install_PreReqs>}) (C {<Read_Settings_File>}) (command.If arms: [ (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (C {<Id.Lit_LBracket '['>} {<-n>} {(DQ ($ Id.VSub_Number 2))} {<Id.Lit_RBracket ']'>}) terminator: <Id.Op_Semi _> ) ] ) action: [ (command.ShAssignment pairs: [ (assign_pair lhs: (sh_lhs_expr.Name left: <Id.Lit_VarLike 'FP_TARGET_BACKUP='> name: FP_TARGET_BACKUP ) op: assign_op.Equal rhs: {($ Id.VSub_Number 2)} spids: [4528] ) ] redirects: [] ) ] spids: [4511 4524] ) ] 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: {($ Id.VSub_DollarName INPUT)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Run_Backup>})] spids: [4545 4559] ) (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: (arith_expr.Unary op_id:Id.Node_UnaryMinus child:{<Id.Lit_Digits 1>}) ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Run_Restore>})] spids: [4571 4586] ) (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 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [ (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_DollarName TARGETMENUID)} right: (arith_expr.Unary op_id: Id.Node_UnaryMinus child: {<Id.Lit_Digits 1>} ) ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) body: (command.DoGroup children: [ (C {<clear>}) (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 TARGETMENUID)} right: {<Id.Lit_Digits 0>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Menu_Main>})] spids: [4643 4657] ) (if_arm cond: (condition.Shell commands: [ (command.Sentence child: (command.DParen child: (arith_expr.Binary op_id: Id.Arith_DEqual left: {($ Id.VSub_DollarName TARGETMENUID)} right: {<Id.Lit_Digits 1>} ) redirects: [] ) terminator: <Id.Op_Semi _> ) ] ) action: [(C {<Menu_Set_Directory>})] spids: [4665 4679] ) ] else_action: [] redirects: [] ) ] ) redirects: [] ) (C {<Write_Settings_File>}) ] spids: [4602 4616] ) ] else_action: [] redirects: [] ) (command.Simple words: [{<rm>} {(DQ ($ Id.VSub_DollarName FP_FILTER_INCLUDE_EXCLUDE_SYSTEM_BACKUP))}] redirects: [(redir op:<Id.Redir_AndGreat '&>'> loc:(redir_loc.Fd fd:1) arg:{<'/dev/null'>})] more_env: [] do_fork: T ) (C {<unset>} {<aSUPPORTED_FILESYSTEMS>}) (command.ControlFlow token:<Id.ControlFlow_Exit exit> arg_word:{<0>}) ] redirects: [] right: <Id.Lit_RBrace '}'> )