dots/.scripts/cam/importcam

19 lines
332 B
Plaintext
Raw Normal View History

2021-08-15 17:28:10 +02:00
#!/usr/bin/env zsh
# TODO: offer to clear camera storage
2022-06-01 20:09:19 +02:00
src=$CAM_SRC
pic=$CAM_PIC
2021-08-15 17:28:10 +02:00
if [ "$#" -eq 2 ]; then
srcdir=$1
bkpdir=$2
fi
2021-08-15 17:28:10 +02:00
[ ! -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