dots/.scripts/cam/importcam

19 lines
332 B
Bash
Executable File

#!/usr/bin/env zsh
# TODO: offer to clear camera storage
src=$CAM_SRC
pic=$CAM_PIC
if [ "$#" -eq 2 ]; then
srcdir=$1
bkpdir=$2
fi
[ ! -d $srcdir ] && echo "$srcdir not found" && exit 1
[ ! -d $bkpdir ] && echo "$bkpdir not found" && exit 1
rsync --update --recursive --human-readable --progress $srcdir $bkpdir
exit 0