diff options
author | Karel Kočí <karel.koci@nic.cz> | 2017-04-07 14:56:22 +0200 |
---|---|---|
committer | Karel Kočí <karel.koci@nic.cz> | 2017-04-07 14:56:22 +0200 |
commit | a793b23435567f2d4f49846196ceebcc47cd764c (patch) | |
tree | 5f542d40b11c55ff851724cbab21c27ba7a8ff0d /config/i3blocks/scripts/backup | |
parent | 6384224250a62e8b1ea913934db5dbae536ce153 (diff) | |
download | myconfigs-a793b23435567f2d4f49846196ceebcc47cd764c.tar.gz myconfigs-a793b23435567f2d4f49846196ceebcc47cd764c.tar.bz2 myconfigs-a793b23435567f2d4f49846196ceebcc47cd764c.zip |
Remove stuff not needed on server
Diffstat (limited to 'config/i3blocks/scripts/backup')
-rwxr-xr-x | config/i3blocks/scripts/backup | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/config/i3blocks/scripts/backup b/config/i3blocks/scripts/backup deleted file mode 100755 index bfa3d39..0000000 --- a/config/i3blocks/scripts/backup +++ /dev/null @@ -1,51 +0,0 @@ -#!/bin/bash - -if [[ -n "$BLOCK_BUTTON" ]]; then - nohup urxvt -title "System backup" -hold -e sudo system-backup 2>&1 >/dev/null & -fi - -state=5 -if [[ -e ~/.backup_date ]]; then - now=$(date +"%s") - prev=$(cat ~/.backup_date) - dif=$(expr $now - $prev) - # 15 days - if [[ $dif -ge 648000 ]]; then - state=4 - # 12 days - elif [[ $dif -ge 518400 ]]; then - state=3 - # 5 days - elif [[ $dif -ge 216000 ]]; then - state=2 - # 2 days - elif [[ $dif -ge 86400 ]]; then - state=1 - else - state=0 - fi -fi - -if [[ $state -eq 0 ]]; then - exit 0 -fi - -echo "Do backup" -echo "Backup" -case $state in - 1) - echo - ;; - 2) - echo "#ffff00" - ;; - 3) - echo "#ff8a00" - ;; - 4) - echo "#ff5000" - ;; - 5) - echo "#ff0000" - ;; -esac |