Skip to content

Commit

Permalink
v6.7
Browse files Browse the repository at this point in the history
+ G_DEV_1 keep it simple.
  • Loading branch information
Fourdee committed Apr 15, 2018
1 parent 29d1594 commit 0e44135
Showing 1 changed file with 6 additions and 19 deletions.
25 changes: 6 additions & 19 deletions dietpi/func/dietpi-globals
Original file line number Diff line number Diff line change
Expand Up @@ -1591,26 +1591,13 @@ $print_logfile_info
# - Update backup
G_DEV_1(){

if [ -f /DietPi/dietpi/.dietpi-backup_settings ]; then
export G_USER_INPUTS=0
/DietPi/dietpi/dietpi-backup -1
sed -i "/DEV_GITBRANCH=/c\DEV_GITBRANCH=testing" /DietPi/dietpi.txt
/DietPi/dietpi/dietpi-update -1
/DietPi/dietpi/dietpi-backup 1

local fp_backup=$(grep -m1 '^FP_TARGET_BACKUP=' /DietPi/dietpi/.dietpi-backup_settings | sed 's/.*=//')
if [ ! -d "$fp_backup"/dietpi-backup_system ]; then

G_DIETPI-NOTIFY 1 'You did not create a backup before testing. Fresh image write for you!'

else

export G_USER_INPUTS=0
/DietPi/dietpi/dietpi-backup -1
sed -i "/DEV_GITBRANCH=/c\DEV_GITBRANCH=testing" /DietPi/dietpi.txt
/DietPi/dietpi/dietpi-update -1
/DietPi/dietpi/dietpi-backup 1

unset G_USER_INPUTS

fi

fi
unset G_USER_INPUTS

}

Expand Down

0 comments on commit 0e44135

Please sign in to comment.