(CommandList children: [ (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:INPUT) op:Equal rhs:{(0)} spids:[75])] spids: [75] ) (If arms: [ (if_arm cond: [ (Sentence child: (DBracket expr: (BoolBinary op_id: BoolBinary_EqualTilde left: {($ VSub_Number '$1')} right: {(Lit_Other '^') (-) (Lit_Other '?') (Lit_Other '[') (0-9) (Lit_Other ']') (Lit_Other '+') (Lit_Other '$') } ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:INPUT) op: Equal rhs: {($ VSub_Number '$1')} spids: [102] ) ] spids: [102] ) ] spids: [16777215 99] ) ] spids: [16777215 106] ) (C {(.)} {(/DietPi/dietpi/func/dietpi-globals)}) (C {(G_CHECK_ROOT_USER)}) (C {(G_CHECK_ROOTFS_RW)}) (C {(export)} {(Lit_VarLike 'G_PROGRAM_NAME=') (SQ <DietPi-Sync>)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_BACKTITLE) op: Equal rhs: {(SQ <DietPi-Sync>)} spids: [150] ) ] spids: [150] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:WHIP_TITLE) op:Equal rhs:{(SQ )} spids:[156])] spids: [156] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:CHOICE) op:Equal rhs:{(0)} spids:[161])] spids: [161] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:OPTION) op:Equal rhs:{(0)} spids:[165])] spids: [165] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:TARGETMENUID) op:Equal rhs:{(0)} spids:[169])] spids: [169] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:FTP_MOUNT_AVAILABLE) op:Equal rhs:{(0)} spids:[174])] spids: [174] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FTP_MOUNT_TEXT) op: Equal rhs: {(SQ <'Not available'>)} spids: [178] ) ] spids: [178] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_AVAILABLE) op: Equal rhs: {(0)} spids: [184] ) ] spids: [184] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_TEXT) op: Equal rhs: {(SQ <'Not available'>)} spids: [188] ) ] spids: [188] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:SYNC_DRY_RUN) op:Equal rhs:{(0)} spids:[195])] spids: [195] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_MODE_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [200] ) ] spids: [200] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [206] ) ] spids: [206] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [212] ) ] spids: [212] ) (FuncDef name: Menu_Main body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_MODE_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [230] ) ] spids: [230] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_DELETE_MODE')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_MODE_TEXT) op: Equal rhs: {(SQ <Enabled>)} spids: [254] ) ] spids: [254] ) ] spids: [16777215 250] ) ] spids: [16777215 261] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [265] ) ] spids: [265] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_COMPRESSION')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION_TEXT) op: Equal rhs: {(SQ <Enabled>)} spids: [289] ) ] spids: [289] ) ] spids: [16777215 285] ) ] spids: [16777215 296] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY_TEXT) op: Equal rhs: {(SQ <Disabled>)} spids: [300] ) ] spids: [300] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_CRONDAILY')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY_TEXT) op: Equal rhs: {(SQ <Enabled>)} spids: [324] ) ] spids: [324] ) ] spids: [16777215 320] ) ] spids: [16777215 331] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:sync_last_completed) op: Equal rhs: {(SQ <'No previous sync found in target directory.'>)} spids: [337] ) ] spids: [335] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-f)} { (DQ ($ VSub_Name '$FP_TARGET') (/) ($ VSub_Name '$SYNC_STATS_FILENAME')) } {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:sync_last_completed) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(grep)} {(SQ <'^Sync completed'>)} { (DQ ($ VSub_Name '$FP_TARGET') (/) ($ VSub_Name '$SYNC_STATS_FILENAME') ) } ) (C {(tail)} {(-1)}) (C {(awk)} {(SQ <'{print $3}'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [363 389] ) } spids: [362] ) ] spids: [362] ) ] spids: [16777215 358] ) ] spids: [16777215 393] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <DietPi-Sync>)} spids: [397] ) ] spids: [397] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--menu)} { (DQ ('Source location:') (Lit_Other '\\') ('n ') ($ VSub_Name '$FP_SOURCE') (Lit_Other '\\') (n) (Lit_Other '\\') ('nTarget location:') (Lit_Other '\\') ('n ') ($ VSub_Name '$FP_TARGET') (Lit_Other '\\') (n) (Lit_Other '\\') ('nMost recent successful sync date:') (Lit_Other '\\') ('n ') ($ VSub_Name '$sync_last_completed') ) } {(--cancel-button)} {(DQ (Exit))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(23)} {(73)} {(8)} {(DQ (Help))} {(DQ ('What does DietPi-Sync do?'))} {(DQ ('Source Location'))} {(DQ ('Change the Source directory.'))} {(DQ ('Target Location'))} {(DQ ('Change the Target directory.'))} {(DQ ('Delete Mode'))} {(DQ ($ VSub_Name '$SYNC_MODE_TEXT'))} {(DQ (Compression))} {(DQ ($ VSub_Name '$SYNC_COMPRESSION_TEXT'))} {(DQ ('Sync: Daily'))} {(DQ ($ VSub_Name '$SYNC_CRONDAILY_TEXT'))} {(DQ ('Sync: Dry Run'))} {(DQ ('Run a test Sync without modifying any data.'))} {(DQ ('Sync: Now'))} {(DQ ('Sync the Source location to the Target location.'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [534] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [537] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [540] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [404 542] ) } spids: [403] ) ] spids: [403] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [546] ) ] spids: [546] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$OPTION'))} arms: [ (case_arm pat_list: [{(DQ ('Source Location'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(2)} spids: [584] ) ] spids: [584] ) ] spids: [578 580 589 16777215] ) (case_arm pat_list: [{(DQ ('Target Location'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(1)} spids: [600] ) ] spids: [600] ) ] spids: [594 596 605 16777215] ) (case_arm pat_list: [{(Help)}] action: [ (C {(whiptail)} {(--title)} {(DQ ('DietPi-Sync Help'))} {(--msgbox)} { (DQ ( 'DietPi-Sync is a program that allows you to duplicate a directory from one location (Source) to another (Target).' ) (Lit_Other '\\') (n) (Lit_Other '\\') ( 'nFor example: If we want to duplicate (sync) the data on our external USB HDD to another location, we simply select the USB HDD as the source, then, select a target location. The target location can be anything from a networked samba fileserver, or even a FTP server.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ( 'nIf you would like to test a sync without modifiying any data, simply select Dry Run.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ('nMore information:') (Lit_Other '\\') ( 'n - http://dietpi.com/phpbb/viewtopic.php?f=8&t=5&p=256#p256' ) ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(19)} {(75)} ) ] spids: [609 610 654 16777215] ) (case_arm pat_list: [{(DQ ('Delete Mode'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(3)} spids: [665] ) ] spids: [665] ) ] spids: [659 661 670 16777215] ) (case_arm pat_list: [{(Compression)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(4)} spids: [679] ) ] spids: [679] ) ] spids: [674 675 684 16777215] ) (case_arm pat_list: [{(DQ ('Sync: Daily'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(5)} spids: [695] ) ] spids: [695] ) ] spids: [689 691 700 16777215] ) (case_arm pat_list: [{(DQ ('Sync: Dry Run'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Test Dry Run Sync? '>)} spids: [711] ) ] spids: [711] ) (C {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--yesno)} { (DQ ('Source location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_SOURCE') ('/*') (Lit_Other '\\') (n) (Lit_Other '\\') ('nTarget location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_TARGET') ('/*') (Lit_Other '\\') (n) (Lit_Other '\\') ('nThis is a Dry Run for testing. No data will be modified.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nDo you wish to continue?') ) } {(--yes-button)} {(DQ (Ok))} {(--no-button)} {(DQ (Back))} {(--defaultno)} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(16)} {(72)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [776] ) ] spids: [776] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_DRY_RUN) op: Equal rhs: {(1)} spids: [798] ) ] spids: [798] ) (C {(Run_Sync)}) ] spids: [16777215 794] ) ] spids: [16777215 806] ) ] spids: [705 707 810 16777215] ) (case_arm pat_list: [{(DQ ('Sync: Now'))}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Start Sync? '>)} spids: [821] ) ] spids: [821] ) (C {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--yesno)} { (DQ ('Source location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_SOURCE') ('/*') (Lit_Other '\\') (n) (Lit_Other '\\') ('nTarget location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_TARGET') ('/*') (Lit_Other '\\') (n) (Lit_Other '\\') ( 'nA copy of all the files and folders inside your Source location, will be created at the Target location.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ('nDo you wish to continue?') ) } {(--yes-button)} {(DQ (Ok))} {(--no-button)} {(DQ (Back))} {(--defaultno)} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(16)} {(72)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [886] ) ] spids: [886] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_DRY_RUN) op: Equal rhs: {(0)} spids: [908] ) ] spids: [908] ) (C {(Run_Sync)}) ] spids: [16777215 904] ) ] spids: [16777215 916] ) ] spids: [815 817 920 16777215] ) ] spids: [568 574 924] ) ] spids: [16777215 564] ) ] else_action: [(C {(Menu_Exit)})] spids: [928 936] ) ] spids: [226] ) spids: [223 226] ) (FuncDef name: Menu_Exit body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Exit DietPi-Sync? '>)} spids: [951] ) ] spids: [951] ) (C {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--yesno)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--yes-button)} {(DQ (Ok))} {(--no-button)} {(DQ (Back))} {(--defaultno)} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(10)} {(50)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [996] ) ] spids: [996] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(-1)} spids: [1023] ) ] spids: [1023] ) ] spids: [16777215 1019] ) ] spids: [16777215 1028] ) ] spids: [947] ) spids: [944 947] ) (FuncDef name: Menu_Set_Directories body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:current_directory) op: Equal rhs: {(DQ ($ VSub_Name '$FP_TARGET'))} spids: [1058] ) ] spids: [1056] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:current_mode_text) op: Equal rhs: {(DQ (Target))} spids: [1066] ) ] spids: [1064] ) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:whip_description_text) op: Equal rhs: { (DQ ('Please select the ') ($ VSub_Name '$current_mode_text') (' location.') (Lit_Other '\\') ('nA copy of all the files and folders in the Source location will be created here.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nCurrent Target location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_TARGET') ) } spids: [1074] ) ] spids: [1072] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <'Select your Sync Target location'>)} spids: [1091] ) ] spids: [1091] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:current_directory) op: Equal rhs: {(DQ ($ VSub_Name '$FP_SOURCE'))} spids: [1115] ) ] spids: [1115] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:current_mode_text) op: Equal rhs: {(DQ (Source))} spids: [1121] ) ] spids: [1121] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:whip_description_text) op: Equal rhs: { (DQ ('Please select the ') ($ VSub_Name '$current_mode_text') (' location.') (Lit_Other '\\') ( 'nA copy of all the files and folder in this Source location, will be created at the Target location.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ('nCurrent Source location:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_SOURCE') ) } spids: [1127] ) ] spids: [1127] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <'Select your Sync Source location'>)} spids: [1144] ) ] spids: [1144] ) ] spids: [16777215 1111] ) ] spids: [16777215 1151] ) (C {(Check_Available_DietPi_Mounts)}) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--menu)} {(DQ ($ VSub_Name '$whip_description_text'))} {(--cancel-button)} {(DQ (Back))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(17)} {(75)} {(4)} {(DQ (Manual))} { (DQ ('Manually type your ') ($ VSub_Name '$current_mode_text') (' directory.') ) } {(DQ (List))} {(DQ ('Select from a list of available mounts/drives'))} {(DQ ('Samba Client'))} {(DQ ($ VSub_Name '$SAMBA_MOUNT_TEXT'))} {(DQ ('FTP Client'))} {(DQ ($ VSub_Name '$FTP_MOUNT_TEXT'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [1235] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [1238] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [1241] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [1160 1243] ) } spids: [1159] ) ] spids: [1159] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [1246] ) ] spids: [1246] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$OPTION'))} arms: [ (case_arm pat_list: [{(List)}] action: [ (C {(/DietPi/dietpi/dietpi-drive_manager)} {(1)}) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:return_value) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(cat)} {(/tmp/dietpi-drive_manager_selmnt)}) ] ) left_token: <Left_CommandSub '$('> spids: [1293 1297] ) } spids: [1292] ) ] spids: [1290] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(DQ ($ VSub_Name '$return_value'))} {(Lit_Other '=')} {(DQ (/))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:return_value) op: Equal rhs: {(SQ </mnt>)} spids: [1321] ) ] spids: [1321] ) ] spids: [16777215 1317] ) ] spids: [16777215 1328] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$return_value'))} spids: [1350] ) ] spids: [1350] ) ] spids: [16777215 1346] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: {(DQ ($ VSub_Name '$return_value') (/dietpi-sync))} spids: [1361] ) ] spids: [1361] ) ] spids: [1357 1369] ) ] spids: [1279 1280 1373 16777215] ) (case_arm pat_list: [{(Manual)}] action: [(C {(Input_User_Directory)})] spids: [1377 1378 1384 16777215] ) (case_arm pat_list: [{(DQ ('Samba Client'))}] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$SAMBA_MOUNT_AVAILABLE')} ) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$TARGETMENUID')} ) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$FP_SAMBA_MOUNT'))} spids: [1429] ) ] spids: [1429] ) ] spids: [16777215 1425] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: { (DQ ($ VSub_Name '$FP_SAMBA_MOUNT') (/dietpi-sync) ) } spids: [1440] ) ] spids: [1440] ) ] spids: [1436 1448] ) ] spids: [16777215 1407] ) ] else_action: [ (C {(Prompt_Setup_Samba_Mount)}) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$TARGETMENUID')} ) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$current_directory'))} spids: [1477] ) ] spids: [1477] ) ] spids: [16777215 1473] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: {(DQ ($ VSub_Name '$current_directory'))} spids: [1488] ) ] spids: [1488] ) ] spids: [1484 1495] ) ] spids: [1452 1499] ) ] spids: [1388 1390 1503 16777215] ) (case_arm pat_list: [{(DQ ('FTP Client'))}] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$FTP_MOUNT_AVAILABLE')} ) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$TARGETMENUID')} ) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$FP_FTP_MOUNT'))} spids: [1549] ) ] spids: [1549] ) ] spids: [16777215 1545] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: { (DQ ($ VSub_Name '$FP_FTP_MOUNT') (/dietpi-sync)) } spids: [1560] ) ] spids: [1560] ) ] spids: [1556 1568] ) ] spids: [16777215 1527] ) ] else_action: [ (C {(Prompt_Setup_FTP_Mount)}) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$TARGETMENUID')} ) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$current_directory'))} spids: [1597] ) ] spids: [1597] ) ] spids: [16777215 1593] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: {(DQ ($ VSub_Name '$current_directory'))} spids: [1608] ) ] spids: [1608] ) ] spids: [1604 1615] ) ] spids: [1572 1619] ) ] spids: [1508 1510 1623 16777215] ) ] spids: [1269 1275 1627] ) ] spids: [16777215 1265] ) ] else_action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(0)} spids: [1639] ) ] spids: [1639] ) ] spids: [1631 1644] ) ] spids: [1043] ) spids: [1040 1043] ) (FuncDef name: Menu_Set_Sync_Delete_Mode body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Sync Delete Mode '>)} spids: [1663] ) ] spids: [1663] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--menu)} { (DQ ('Please select the Sync delete mode.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nDisabled: (safe)') (Lit_Other '\\') ( 'nIf files and folders exist in the Target location, that are not in the Source, they will be left alone.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ('nEnabled: (WARNING, if in doubt, DO NOT enable)') (Lit_Other '\\') ( 'nAn exact copy of the Source location will be created at the Target location. If files are in the Target location that dont exist in the Source, they will be DELETED.' ) ) } {(--cancel-button)} {(DQ (Back))} {(--default-item)} {(DQ ($ VSub_Name '$SYNC_MODE_TEXT'))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(19)} {(75)} {(2)} {(DQ (Disabled))} { (DQ ( 'Ignores data that exists at Target Location and not Source.' ) ) } {(DQ (Enabled))} { (DQ ( 'Deletes data at Target location if not in Source Location.' ) ) } ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [1741] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [1744] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [1747] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [1670 1749] ) } spids: [1669] ) ] spids: [1669] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [1752] ) ] spids: [1752] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$OPTION'))} arms: [ (case_arm pat_list: [{(Disabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_DELETE_MODE) op: Equal rhs: {(0)} spids: [1790] ) ] spids: [1790] ) ] spids: [1785 1786 1795 16777215] ) (case_arm pat_list: [{(Enabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_DELETE_MODE) op: Equal rhs: {(1)} spids: [1804] ) ] spids: [1804] ) ] spids: [1799 1800 1809 16777215] ) ] spids: [1775 1781 1813] ) ] spids: [16777215 1771] ) ] spids: [16777215 1817] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(0)} spids: [1825] ) ] spids: [1825] ) ] spids: [1659] ) spids: [1656 1659] ) (FuncDef name: Menu_Set_Compression body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Sync Compression Mode '>)} spids: [1845] ) ] spids: [1845] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--menu)} { (DQ ('Please select the compression mode.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nDisabled:') (Lit_Other '\\') ('nNo compression will be used during data transfer.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nEnabled:') (Lit_Other '\\') ( 'nData will be compressed when its being transfered. Useful for slow connections, however, its CPU intensive.' ) ) } {(--cancel-button)} {(DQ (Back))} {(--default-item)} {(DQ ($ VSub_Name '$SYNC_COMPRESSION_TEXT'))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(17)} {(75)} {(2)} {(DQ (Disabled))} {(DQ ('Transfer data in its original state.'))} {(DQ (Enabled))} {(DQ ('Compress the data during transfer.'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [1923] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [1926] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [1929] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [1852 1931] ) } spids: [1851] ) ] spids: [1851] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [1934] ) ] spids: [1934] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$OPTION'))} arms: [ (case_arm pat_list: [{(Disabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION) op: Equal rhs: {(0)} spids: [1972] ) ] spids: [1972] ) ] spids: [1967 1968 1977 16777215] ) (case_arm pat_list: [{(Enabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION) op: Equal rhs: {(1)} spids: [1986] ) ] spids: [1986] ) ] spids: [1981 1982 1991 16777215] ) ] spids: [1957 1963 1995] ) ] spids: [16777215 1953] ) ] spids: [16777215 1999] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(0)} spids: [2007] ) ] spids: [2007] ) ] spids: [1841] ) spids: [1838 1841] ) (FuncDef name: Menu_Set_CronDaily body: (BraceGroup children: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:WHIP_TITLE) op: Equal rhs: {(SQ <' Sync Cron Daily '>)} spids: [2027] ) ] spids: [2027] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--title)} {(DQ ($ VSub_Name '$WHIP_TITLE'))} {(--menu)} { (DQ ('Disabled:') (Lit_Other '\\') ('nThe user must manually sync using dietpi-sync.') (Lit_Other '\\') (n) (Lit_Other '\\') ('nEnabled:') (Lit_Other '\\') ( 'nA cron job will be created that automatically runs dietpi-sync, once a day.' ) (Lit_Other '\\') (n) (Lit_Other '\\') ('n(NOTICE):') (Lit_Other '\\') ( 'nBefore enabling this feature, please run a test sync (Dry Run) to verify what will happen.' ) ) } {(--cancel-button)} {(DQ (Back))} {(--default-item)} {(DQ ($ VSub_Name '$SYNC_CRONDAILY_TEXT'))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(19)} {(75)} {(2)} {(DQ (Disabled))} {(DQ ('Manual sync.'))} {(DQ (Enabled))} {(DQ ('Automatically sync once a day.'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [2107] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2110] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [2113] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [2034 2115] ) } spids: [2033] ) ] spids: [2033] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [2118] ) ] spids: [2118] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Case to_match: {(DQ ($ VSub_Name '$OPTION'))} arms: [ (case_arm pat_list: [{(Disabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY) op: Equal rhs: {(0)} spids: [2156] ) ] spids: [2156] ) ] spids: [2151 2152 2161 16777215] ) (case_arm pat_list: [{(Enabled)}] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY) op: Equal rhs: {(1)} spids: [2170] ) ] spids: [2170] ) ] spids: [2165 2166 2175 16777215] ) ] spids: [2141 2147 2179] ) ] spids: [16777215 2137] ) ] spids: [16777215 2183] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(0)} spids: [2191] ) ] spids: [2191] ) ] spids: [2023] ) spids: [2020 2023] ) (FuncDef name: Input_User_Directory body: (BraceGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--inputbox)} { (DQ ( 'Please enter the filepath to your Target directory. ' ) (Lit_Other '\\') ('neg: /mnt/target') ) } {(8)} {(70)} {(DQ ($ VSub_Name '$FP_TARGET'))} {(--title)} {(DQ ('Manual sync directory'))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [2270] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2273] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [2276] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [2239 2278] ) } spids: [2238] ) ] spids: [2238] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [2281] ) ] spids: [2281] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: {(DQ ($ VSub_Name '$OPTION'))} spids: [2303] ) ] spids: [2303] ) ] spids: [16777215 2299] ) ] spids: [16777215 2310] ) ] spids: [16777215 2234] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 2)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:OPTION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (SimpleCommand words: [ {(whiptail)} {(--inputbox)} { (DQ ( 'Please enter the filepath to your Source directory. ' ) (Lit_Other '\\') ('neg: /mnt/source') ) } {(8)} {(70)} {(DQ ($ VSub_Name '$FP_SOURCE'))} {(--title)} {(DQ ('Manual sync directory'))} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} ] redirects: [ (Redir op_id: Redir_GreatAnd fd: 3 arg_word: {(1)} spids: [2368] ) (Redir op_id: Redir_GreatAnd fd: 1 arg_word: {(2)} spids: [2371] ) (Redir op_id: Redir_GreatAnd fd: 2 arg_word: {(3)} spids: [2374] ) ] ) ] ) left_token: <Left_CommandSub '$('> spids: [2337 2376] ) } spids: [2336] ) ] spids: [2336] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [2379] ) ] spids: [2379] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(DQ ($ VSub_Name '$OPTION'))} spids: [2401] ) ] spids: [2401] ) ] spids: [16777215 2397] ) ] spids: [16777215 2408] ) ] spids: [2318 2332] ) ] spids: [16777215 2412] ) ] spids: [2203] ) spids: [2200 2203] ) (FuncDef name: Prompt_Setup_Samba_Mount body: (BraceGroup children: [ (C {(whiptail)} {(--title)} {(DQ ('Not available. Setup Now?'))} {(--yesno)} { (DQ ($ VSub_Name '$SAMBA_MOUNT_TEXT') (Lit_Other '\\') (n) (Lit_Other '\\') ( 'nWould you like to run DietPi-Config and setup your Samba Client Mount now?' ) ) } {(--yes-button)} {(DQ (Ok))} {(--no-button)} {(DQ (Back))} {(--defaultno)} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(11)} {(70)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [2470] ) ] spids: [2470] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(/DietPi/dietpi/dietpi-config)} {(16)} {(1)})] spids: [16777215 2488] ) ] spids: [16777215 2504] ) ] spids: [2423] ) spids: [2420 2423] ) (FuncDef name: Prompt_Setup_FTP_Mount body: (BraceGroup children: [ (C {(whiptail)} {(--title)} {(DQ ('Not available. Setup Now?'))} {(--yesno)} { (DQ ($ VSub_Name '$FTP_MOUNT_TEXT') (Lit_Other '\\') (n) (Lit_Other '\\') ('nWould you like to run DietPi-Config and setup your FTP Client Mount now?') ) } {(--yes-button)} {(DQ (Ok))} {(--no-button)} {(DQ (Back))} {(--defaultno)} {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(11)} {(70)} ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:CHOICE) op: Equal rhs: {($ VSub_QMark '$?')} spids: [2562] ) ] spids: [2562] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$CHOICE')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(/DietPi/dietpi/dietpi-config)} {(16)} {(1)})] spids: [16777215 2580] ) ] spids: [16777215 2596] ) ] spids: [2515] ) spids: [2512 2515] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:LOGFILE) op: Equal rhs: {(SQ </var/log/dietpi-sync.log>)} spids: [2620] ) ] spids: [2620] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: {(SQ </mnt/Source>)} spids: [2631] ) ] spids: [2631] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: {(SQ </mnt/Target>)} spids: [2637] ) ] spids: [2637] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_FTP_MOUNT) op: Equal rhs: {(SQ </mnt/ftp_client>)} spids: [2648] ) ] spids: [2648] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SAMBA_MOUNT) op: Equal rhs: {(SQ </mnt/samba>)} spids: [2654] ) ] spids: [2654] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_STATS_FILENAME) op: Equal rhs: {(SQ <.dietpi-sync_stats>)} spids: [2665] ) ] spids: [2665] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_EXCLUDE_GLOBAL) op: Equal rhs: {(SQ </tmp/.dietpi-sync_exclude>)} spids: [2676] ) ] spids: [2676] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_INCLUDE_GLOBAL) op: Equal rhs: {(SQ </tmp/.dietpi-sync_include>)} spids: [2682] ) ] spids: [2682] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_EXCLUDE_USER) op: Equal rhs: {(SQ </DietPi/dietpi/.dietpi-sync_exclude>)} spids: [2688] ) ] spids: [2688] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_INCLUDE_USER) op: Equal rhs: {(SQ </DietPi/dietpi/.dietpi-sync_include>)} spids: [2694] ) ] spids: [2694] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:SYNC_DELETE_MODE) op:Equal rhs:{(0)} spids:[2705])] spids: [2705] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:SYNC_COMPRESSION) op:Equal rhs:{(0)} spids:[2709])] spids: [2709] ) (Assignment keyword: Assign_None pairs: [(assign_pair lhs:(LhsName name:SYNC_CRONDAILY) op:Equal rhs:{(0)} spids:[2713])] spids: [2713] ) (FuncDef name: Create_Exclude_File body: (BraceGroup children: [ (Sentence child: (C {(rm)} {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))}) terminator: <Op_Amp '&'> ) (SimpleCommand redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(/dev/null)} spids: [2737] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_TARGET'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2755] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/boot/dietpi/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2770] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/DietPi/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2785] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/dev/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2800] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/proc/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2815] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/sys/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2830] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/tmp/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2845] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('/run/*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2860] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$LOGFILE'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2880] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2895] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_EXCLUDE_USER'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2910] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_INCLUDE_USER'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2925] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$SYNC_STATS_FILENAME'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2940] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ (/var/swap))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2955] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('*.tmp'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2970] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ (Thumbs.db))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [2989] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ (desktop.ini))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [3004] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('SyncToy*'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [3019] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ('System Volume Information'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [3037] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-f)} {(DQ ($ VSub_Name '$FP_EXCLUDE_USER'))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)} {(DQ ($ VSub_Name '$FP_EXCLUDE_USER'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} spids: [3075] ) ] ) ] spids: [16777215 3065] ) ] spids: [16777215 3083] ) ] spids: [2722] ) spids: [2719 2722] ) (FuncDef name: Create_Include_File body: (BraceGroup children: [ (Sentence child: (C {(rm)} {(DQ ($ VSub_Name '$FP_INCLUDE_GLOBAL'))}) terminator: <Op_Amp '&'> ) (SimpleCommand redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(/dev/null)} spids: [3109] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ )}] redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_INCLUDE_GLOBAL'))} spids: [3126] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-f)} {(DQ ($ VSub_Name '$FP_INCLUDE_USER'))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [{(cat)} {(DQ ($ VSub_Name '$FP_INCLUDE_USER'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_INCLUDE_GLOBAL'))} spids: [3166] ) ] ) ] spids: [16777215 3156] ) ] spids: [16777215 3174] ) ] spids: [3094] ) spids: [3091 3094] ) (FuncDef name: Services_Stop body: (BraceGroup children:[(C {(/DietPi/dietpi/dietpi-services)} {(stop)})] spids:[3185]) spids: [3182 3185] ) (FuncDef name: Services_Start body: (BraceGroup children:[(C {(/DietPi/dietpi/dietpi-services)} {(start)})] spids:[3200]) spids: [3197 3200] ) (FuncDef name: Banner_Start body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:mode) op: Equal rhs: {(SQ <Sync>)} spids: [3221] ) ] spids: [3219] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_DRY_RUN')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:mode) op: Equal rhs: {(SQ <'Dry Run'>)} spids: [3249] ) ] spids: [3249] ) ] spids: [16777215 3245] ) ] spids: [16777215 3256] ) (C {(G_DIETPI-NOTIFY)} {(3)} {(DietPi-Sync)} {(DQ ($ VSub_Name '$mode'))}) ] spids: [3215] ) spids: [3212 3215] ) (FuncDef name: Run_Sync body: (BraceGroup children: [ (C {(Banner_Start)}) (C {(mkdir)} {(-p)} {(DQ ($ VSub_Name '$FP_TARGET'))}) (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(KW_Bang '!')} {(-d)} {(DQ ($ VSub_Name '$FP_TARGET'))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child:(ArithWord w:{($ VSub_Name '$G_USER_INPUTS')})) terminator: <Op_Semi ';'> ) ] action: [ (C {(whiptail)} {(--title)} {(DQ ('Sync failed.'))} {(--msgbox)} { (DQ ('Unable to create Target directory ') ($ VSub_Name '$FP_TARGET') ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(10)} {(60)} ) ] spids: [16777215 3335] ) ] spids: [16777215 3366] ) ] spids: [16777215 3321] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(ps)} {(aux)}) (C {(grep)} {(-ci)} {(-m1)} {(DQ ('[r]sync'))}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [3378 3394] ) } ) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} {(-e)} { (DQ ('Sync failed: ') (CommandSubPart command_list: (CommandList children: [(C {(date)} {(Lit_Other '+') (DQ ('%d-%m-%Y_%H%M'))})] ) left_token: <Left_CommandSub '$('> spids: [3414 3421] ) ('. Rsync is already running.') ) } ] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: { (DQ ($ VSub_Name '$FP_TARGET') (/) ($ VSub_Name '$SYNC_STATS_FILENAME') ) } spids: [3425] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child:(ArithWord w:{($ VSub_Name '$G_USER_INPUTS')})) terminator: <Op_Semi ';'> ) ] action: [ (C {(whiptail)} {(--title)} {(DQ ('Sync Error'))} {(--msgbox)} { (DQ ( 'A sync job could not be started as rsync is already running.' ) ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(13)} {(60)} ) ] spids: [16777215 3449] ) ] spids: [16777215 3479] ) ] spids: [3374 3404] ) ] else_action: [ (C {(Create_Exclude_File)}) (C {(Create_Include_File)}) (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: Equal rhs: {(DQ (-a))} spids: [3508] ) ] spids: [3506] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (v))} spids: [3518] ) ] spids: [3518] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (P))} spids: [3528] ) ] spids: [3528] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (4))} spids: [3538] ) ] spids: [3538] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_COMPRESSION')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (z))} spids: [3567] ) ] spids: [3567] ) ] spids: [16777215 3563] ) ] spids: [16777215 3574] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_DRY_RUN')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (n))} spids: [3600] ) ] spids: [3600] ) ] spids: [16777215 3596] ) ] spids: [16777215 3607] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_DELETE_MODE')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:rync_options) op: PlusEqual rhs: {(DQ (' --delete'))} spids: [3633] ) ] spids: [3633] ) ] spids: [16777215 3629] ) ] spids: [16777215 3640] ) (SimpleCommand words: [ {(echo)} {(-e)} { (DQ ('DietPi-Sync Log File.') (Lit_Other '\\') (n) (CommandSubPart command_list: (CommandList children: [ (C {(date)} {(Lit_Other '+') (Lit_Other '%') (d-) (Lit_Other '%') (m-) (Lit_Other '%') (Y_) (Lit_Other '%') (H) (Lit_Other '%') (M) } ) ] ) left_token: <Left_CommandSub '$('> spids: [3656 3670] ) (Lit_Other '\\') ('nSYNC_DRY_RUN=') ($ VSub_Name '$SYNC_DRY_RUN') (Lit_Other '\\') (n) (Lit_Other '\\') (n) ) } ] redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(DQ ($ VSub_Name '$LOGFILE'))} spids: [3680] ) ] ) (C {(rsync)} {($ VSub_Name '$rync_options')} {(--log-file) (Lit_Other '=') ($ VSub_Name '$LOGFILE')} {(--exclude-from) (Lit_Other '=') (DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))} {(--include-from) (Lit_Other '=') (DQ ($ VSub_Name '$FP_INCLUDE_GLOBAL'))} {(DQ ($ VSub_Name '$FP_SOURCE')) (/)} {(DQ ($ VSub_Name '$FP_TARGET')) (/)} ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_QMark '$?')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (SimpleCommand words: [ {(echo)} {(-e)} { (DQ ('Sync completed: ') (CommandSubPart command_list: (CommandList children: [ (C {(date)} {(Lit_Other '+') (DQ ('%d-%m-%Y_%H%M'))}) ] ) left_token: <Left_CommandSub '$('> spids: [3762 3769] ) ) } ] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: { (DQ ($ VSub_Name '$FP_TARGET') (/) ($ VSub_Name '$SYNC_STATS_FILENAME') ) } spids: [3772] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithWord w:{($ VSub_Name '$G_USER_INPUTS')}) ) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: {($ VSub_Name '$SYNC_DRY_RUN')} ) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(whiptail)} {(--title)} {(DQ ('Sync completed'))} {(--msgbox)} { (DQ ($ VSub_Name '$FP_SOURCE') (Lit_Other '\\') (n) (Lit_Other '\\') ('nHas been synced to:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_TARGET') (Lit_Other '\\') (n) (Lit_Other '\\') ('nLog file: ') ($ VSub_Name '$LOGFILE') ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(13)} {(60)} ) ] spids: [16777215 3814] ) ] else_action: [ (C {(whiptail)} {(--title)} {(DQ ('Dry Run Sync completed'))} {(--msgbox)} { (DQ ($ VSub_Name '$FP_SOURCE') (Lit_Other '\\') (n) (Lit_Other '\\') ('nHas been synced with a Dry Run (NO modifications) to:') (Lit_Other '\\') (n) ($ VSub_Name '$FP_TARGET') (Lit_Other '\\') (n) (Lit_Other '\\') ('nLog file: ') ($ VSub_Name '$LOGFILE') ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(13)} {(60)} ) ] spids: [3856 3898] ) ] spids: [16777215 3796] ) ] spids: [16777215 3902] ) ] spids: [16777215 3752] ) ] else_action: [ (SimpleCommand words: [ {(echo)} {(-e)} { (DQ ('Sync failed: ') (CommandSubPart command_list: (CommandList children: [(C {(date)} {(Lit_Other '+') (DQ ('%d-%m-%Y_%H%M'))})] ) left_token: <Left_CommandSub '$('> spids: [3920 3927] ) ) } ] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: { (DQ ($ VSub_Name '$FP_TARGET') (/) ($ VSub_Name '$SYNC_STATS_FILENAME') ) } spids: [3930] ) ] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child:(ArithWord w:{($ VSub_Name '$G_USER_INPUTS')})) terminator: <Op_Semi ';'> ) ] action: [ (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$SYNC_DRY_RUN')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (C {(whiptail)} {(--title)} {(DQ ('Sync failed'))} {(--msgbox)} { (DQ ( 'Your sync has failed. Please see the Log file for more information:' ) (Lit_Other '\\') (n) (Lit_Other '\\') (n) ($ VSub_Name '$LOGFILE') ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(13)} {(60)} ) ] spids: [16777215 3972] ) ] else_action: [ (C {(whiptail)} {(--title)} {(DQ ('Dry Run Sync failed'))} {(--msgbox)} { (DQ ( 'Your sync has failed. Please see the Log file for more information:' ) (Lit_Other '\\') (n) (Lit_Other '\\') (n) ($ VSub_Name '$LOGFILE') ) } {(--backtitle)} {(DQ ($ VSub_Name '$WHIP_BACKTITLE'))} {(13)} {(60)} ) ] spids: [4007 4042] ) ] spids: [16777215 3954] ) ] spids: [16777215 4046] ) ] spids: [3910 4049] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:TARGETMENUID) op: Equal rhs: {(0)} spids: [4057] ) ] spids: [4057] ) ] spids: [3487 4062] ) ] spids: [3280] ) spids: [3277 3280] ) (FuncDef name: Check_Install_PreReqs body: (BraceGroup children:[(C {(G_AG_CHECK_INSTALL_PREREQ)} {(rsync)})] spids:[4073]) spids: [4070 4073] ) (FuncDef name: Check_Available_DietPi_Mounts body: (BraceGroup children: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:temp_file_mounts) op: Equal rhs: {(DQ (/tmp/.dietpi-sync_dietpi_mounts))} spids: [4096] ) ] spids: [4094] ) (SimpleCommand words: [{(df)} {(-h)}] redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(DQ ($ VSub_Name '$temp_file_mounts'))} spids: [4106] ) ] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_AVAILABLE) op: Equal rhs: {(0)} spids: [4118] ) ] spids: [4118] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_TEXT) op: Equal rhs: { (DQ ('Not mounted (') ($ VSub_Name '$FP_SAMBA_MOUNT') ('). Select to setup.')) } spids: [4122] ) ] spids: [4122] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(cat)} {(DQ ($ VSub_Name '$temp_file_mounts'))} ) (C {(grep)} {(-ci)} {(-m1)} {(DQ (/mnt/samba))}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [4134 4152] ) } ) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_AVAILABLE) op: Equal rhs: {(1)} spids: [4166] ) ] spids: [4166] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SAMBA_MOUNT_TEXT) op: Equal rhs: { (DQ ('Size: ') (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(df)} {(-h)}) (C {(grep)} {(/mnt/samba)}) (C {(awk)} {(SQ <'{print $2}'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [4173 4191] ) ('B | Available: ') (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(df)} {(-h)}) (C {(grep)} {(/mnt/samba)}) (C {(awk)} {(SQ <'{print $4}'>)}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [4193 4211] ) (B) ) } spids: [4170] ) ] spids: [4170] ) ] spids: [16777215 4162] ) ] spids: [16777215 4217] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FTP_MOUNT_AVAILABLE) op: Equal rhs: {(0)} spids: [4225] ) ] spids: [4225] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FTP_MOUNT_TEXT) op: Equal rhs: { (DQ ('Not mounted (') ($ VSub_Name '$FP_FTP_MOUNT') ('). Select to setup.')) } spids: [4229] ) ] spids: [4229] ) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w: { (CommandSubPart command_list: (CommandList children: [ (Pipeline children: [ (C {(cat)} {(DQ ($ VSub_Name '$temp_file_mounts'))} ) (C {(grep)} {(-ci)} {(-m1)} {(DQ (/mnt/ftp_client))}) ] negated: F ) ] ) left_token: <Left_CommandSub '$('> spids: [4241 4259] ) } ) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FTP_MOUNT_AVAILABLE) op: Equal rhs: {(1)} spids: [4273] ) ] spids: [4273] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FTP_MOUNT_TEXT) op: Equal rhs: {(DQ ('Mounted and online.'))} spids: [4277] ) ] spids: [4277] ) ] spids: [16777215 4269] ) ] spids: [16777215 4284] ) (C {(rm)} {(DQ ($ VSub_Name '$temp_file_mounts'))}) ] spids: [4090] ) spids: [4087 4090] ) (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_DIETPISYNC_SETTINGS) op: Equal rhs: {(DQ (/DietPi/dietpi/.dietpi-sync_settings))} spids: [4316] ) ] spids: [4316] ) (FuncDef name: Write_Settings_File body: (BraceGroup children: [ (Sentence child: (C {(rm)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))}) terminator: <Op_Amp '&'> ) (SimpleCommand redirects: [ (Redir op_id: Redir_Great fd: 16777215 arg_word: {(/dev/null)} spids: [4337] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_SOURCE'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} spids: [4351] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$FP_TARGET'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} spids: [4366] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$SYNC_DELETE_MODE'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} spids: [4381] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$SYNC_COMPRESSION'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} spids: [4396] ) ] ) (SimpleCommand words: [{(echo)} {(-e)} {(DQ ($ VSub_Name '$SYNC_CRONDAILY'))}] redirects: [ (Redir op_id: Redir_DGreat fd: 16777215 arg_word: {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} spids: [4411] ) ] ) ] spids: [4326] ) spids: [4323 4326] ) (FuncDef name: Read_Settings_File body: (BraceGroup children: [ (If arms: [ (if_arm cond: [ (Sentence child: (C {(Lit_Other '[')} {(-f)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} {(Lit_Other ']')} ) terminator: <Op_Semi ';'> ) ] action: [ (Assignment keyword: Assign_Local pairs: [ (assign_pair lhs: (LhsName name:sed_index) op: Equal rhs: {(1)} spids: [4449] ) ] spids: [4447] ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_SOURCE) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(sed)} {(-n)} {(DQ ($ VSub_Name '$sed_index')) (p)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [4454 4467] ) } spids: [4453] ) ] spids: [4453] ) terminator: <Op_Semi ';'> ) (DParen child: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:sed_index)) ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:FP_TARGET) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(sed)} {(-n)} {(DQ ($ VSub_Name '$sed_index')) (p)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [4477 4490] ) } spids: [4476] ) ] spids: [4476] ) terminator: <Op_Semi ';'> ) (DParen child: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:sed_index)) ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_DELETE_MODE) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(sed)} {(-n)} {(DQ ($ VSub_Name '$sed_index')) (p)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [4500 4513] ) } spids: [4499] ) ] spids: [4499] ) terminator: <Op_Semi ';'> ) (DParen child: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:sed_index)) ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_COMPRESSION) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(sed)} {(-n)} {(DQ ($ VSub_Name '$sed_index')) (p)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [4523 4536] ) } spids: [4522] ) ] spids: [4522] ) terminator: <Op_Semi ';'> ) (DParen child: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:sed_index)) ) (Sentence child: (Assignment keyword: Assign_None pairs: [ (assign_pair lhs: (LhsName name:SYNC_CRONDAILY) op: Equal rhs: { (CommandSubPart command_list: (CommandList children: [ (C {(sed)} {(-n)} {(DQ ($ VSub_Name '$sed_index')) (p)} {(DQ ($ VSub_Name '$FP_DIETPISYNC_SETTINGS'))} ) ] ) left_token: <Left_CommandSub '$('> spids: [4546 4559] ) } spids: [4545] ) ] spids: [4545] ) terminator: <Op_Semi ';'> ) (DParen child: (UnaryAssign op_id:Node_PostDPlus child:(LhsName name:sed_index)) ) ] spids: [16777215 4443] ) ] spids: [16777215 4569] ) ] spids: [4426] ) spids: [4423 4426] ) (C {(Check_Install_PreReqs)}) (C {(Read_Settings_File)}) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$INPUT')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(Run_Sync)})] spids: [16777215 4628] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$INPUT')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [ (While cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_Great left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithUnary op_id: Node_UnaryMinus child: (ArithWord w:{(Lit_Digits 1)}) ) ) ) terminator: <Op_Semi ';'> ) ] body: (DoGroup children: [ (C {(clear)}) (If arms: [ (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 0)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(Menu_Main)})] spids: [16777215 4699] ) (if_arm cond: [ (Sentence child: (AndOr ops: [Op_DPipe] children: [ (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 1)}) ) ) (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 2)}) ) ) ] ) terminator: <Op_Semi ';'> ) ] action: [(C {(Menu_Set_Directories)})] spids: [4707 4735] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 3)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(Menu_Set_Sync_Delete_Mode)})] spids: [4743 4757] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 4)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(Menu_Set_Compression)})] spids: [4765 4779] ) (if_arm cond: [ (Sentence child: (DParen child: (ArithBinary op_id: Arith_DEqual left: (ArithWord w:{($ VSub_Name '$TARGETMENUID')}) right: (ArithWord w:{(Lit_Digits 5)}) ) ) terminator: <Op_Semi ';'> ) ] action: [(C {(Menu_Set_CronDaily)})] spids: [4787 4801] ) ] spids: [16777215 4809] ) ] spids: [4677 4813] ) ) (C {(Write_Settings_File)}) ] spids: [4644 4658] ) ] spids: [16777215 4825] ) (Sentence child: (C {(rm)} {(DQ ($ VSub_Name '$FP_INCLUDE_GLOBAL'))}) terminator: <Op_Amp '&'> ) (SimpleCommand redirects: [(Redir op_id:Redir_Great fd:16777215 arg_word:{(/dev/null)} spids:[4844])] ) (Sentence child: (C {(rm)} {(DQ ($ VSub_Name '$FP_EXCLUDE_GLOBAL'))}) terminator: <Op_Amp '&'> ) (SimpleCommand redirects: [(Redir op_id:Redir_Great fd:16777215 arg_word:{(/dev/null)} spids:[4856])] ) (ControlFlow token:<ControlFlow_Exit exit> arg_word:{(0)}) ] spids: [3] ) ] )