Skip to content

edin-m/google-photos-sync

Repository files navigation

Google Photos Sync

Sync Google Photos on a local disk.

THIS IS A READ-ONLY / DOWNLOAD SYNC

Set up

  1. Get credentials.json from google console and put them into the secrets folder
  2. Set photo path in config.json (along with other params)
  3. Run node app

How it works

It has 3 cron jobs which are:

  • getting and caching google photo metadata (4x a day)
  • probing files for their content length - file change detection (every hour - a limited number of items)
  • actually downloading files (every hour - a limited number of items)

CLI commands

start

It will load and set up jobs and that's it.

$ node app

output verbose logs

$ node app -v

count number of metadata items downloaded and stored

$ node app -c

run a specific job once and exit

$ node app --job <job-name> --params <job-params-space-separated>
$ node app --job probeMediaItemRefresh --params <<renewIfOlderThanDays>> <<numberOfItems>>

$ node app --job downloadMediaItemFile --params <<limitNumberOfItems>>

$ node app --job searchMediaItemsJob --params <<numOfDaysBack>> <<limitNumOfItems>>

$ node app --job appStartupJob

TODO

[ ] resume download -- right now it overwrites if a file is partially downloaded

About

Sync Google Photos on a local disk

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published