sync comics

This commit is contained in:
Nemo 2018-02-28 09:57:41 +05:30
parent 5179367c41
commit 8501ab5067
1 changed files with 9 additions and 1 deletions

View File

@ -1,4 +1,5 @@
#!/bin/bash
# Usage: Zips given directories into .cbz (Comic Book ZIP) archives of the smame name (eg "folder name.cbz").
COMIC_ROOT="/home/nemo/Downloads/Books/Comics"
@ -12,4 +13,11 @@ while read comic_dir; do
echo "[DL] $comic_dir"
cbz.sh -k "$comic_dir" > /dev/null
fi
done < <(find . -mindepth 2 -maxdepth 2 -type d)
done < <(find . -mindepth 3 -maxdepth 3 -type d)
# Sync it as well
for dir in *; do
cd $dir
rsync --archive --include '*.cbz' --recursive * nemo@192.168.1.111:/mnt/xwing/media/EBooks/Comics/ --verbose --exclude '*.jpg' --exclude '*.png' --exclude '.sync' --prune-empty-dirs
cd ..
done