From af308ee0510eb896f548ffb9f6a16d8794849fbf Mon Sep 17 00:00:00 2001 From: Marc Vertes Date: Fri, 25 Sep 2020 15:57:37 +0200 Subject: update --- bin/byo | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'bin/byo') diff --git a/bin/byo b/bin/byo index ecaba23..389e112 100755 --- a/bin/byo +++ b/bin/byo @@ -11,9 +11,9 @@ Options: -k do not umount and close yoda ' -while getopts :cdk opt; do +while getopts :Ccdk opt; do case $opt in - (c|d|k) eval "opt$opt=$opt" ;; + (C|c|d|k) eval "opt$opt=$opt" ;; (*) printf %s "$usage"; exit 1 ;; esac done @@ -25,9 +25,10 @@ dest=/mnt/backup/$(hostname) [ -b /dev/mapper/yoda ] && noclose=1 || cryptsetup open "$(blkid --uuid "$yoda_uuid")" yoda findmnt /dev/mapper/yoda /mnt >/dev/null && noumount=1 || mount /dev/mapper/yoda /mnt time backup -v -d "$dest" -backup -v -d "$dest" clean +[ ! "$optC" ] || backup -v -d "$dest" clean [ ! "$optd" ] || time duperemove -drh --hashfile="$dest/.hashfile" "$dest" df -h / "$dest" +ls -v "$dest" [ ! "$optk" ] || noumount=1 noclose=1 [ ! "$optc" ] || noumount='' noclose='' [ "$noumount" ] || umount /mnt -- cgit v1.2.3