fsantini / KoboCloud

A set of scripts to synchronize a kobo reader with popular cloud services
Other
958 stars 94 forks source link

skip dropbox file based on size #179

Closed louisabraham closed 1 month ago

louisabraham commented 1 month ago

if the file exists and has the same size as indicated by the API, we skip it

behavior is unchanged since curl uses the -C option to resume download

if the file exists and has a greater size than indicated (weird bug I couldn't track back), we delete it

This makes the script much faster (needs only one request on already synced folders instead of one per file) and more resilient.

louisabraham commented 1 month ago

do NOT merge yet

louisabraham commented 1 month ago

ok to merge now! I needed to add the skipped files to the filesList.

I alos fixed another annoying bug that made lines like

* not found, deleting
rm: can't remove '*': No such file or directory

appear in the logs

fsantini commented 1 month ago

Thanks!

louisabraham commented 1 month ago

I have never found a project more useful to my daily life than this one, so thank you!