minor fixes

This commit is contained in:
snaki 2022-07-07 14:59:59 +02:00
parent 7fb56fab68
commit a1a99930a8

12
btrbk
View file

@ -10,7 +10,7 @@ function bkRun {
for i in ${!SUBVOLS[@]}; do
snapName=${VOLNAME[$i]}.$date
getSnap "$i"
if [[ -d "$SNAPDIR$snapName" ]] && ! $force; then
if [[ -d "$SNAPDIR$snapName" && "$force" != true ]]; then
echo "backup already run today"
continue
else
@ -115,9 +115,9 @@ function testConf {
fi
if rclone ls $RCLONEDIR > /dev/null 2>&1; then
if gpg --list-key $PUBKEY > /dev/null 2>&1; then
if $restore; then
if [ "$restore" = true ]; then
runRestore
elif $backup; then
elif [ "$backup" = true ]; then
testDate
fi
else
@ -172,8 +172,10 @@ while true; do
esac
shift
done
if $fullRestore; then
if [ "$fullBackup" = true ]; then
runFullRestore
elif $backup
elif [ "$backup" = true ]; then
testConf
else
echoHelp
fi