Copying photos from iCloud library

Get help. Get answers. Let others lend you a hand.

Moderator: Mr_Noodle

Copying photos from iCloud library Thu Sep 21, 2017 12:58 am • by noodlema
I recently switched to a Mac and I’m looking for a way to copy photos from the iCloud library to another folder automatically whenever photos are added. Another program (Lightroom), will periodically move these copied photos elsewhere. Will Hazel be able to do:
0. Assuming I create a soft link to masters folder in icloud photos package
1. Search all sub folders within Masters folder
2. Copy (new) photos found (since last run) to another folder

As new photos get added to iCloud Photo Library, I want only the newly added photos to be copied. Will this be possible with Hazel? I understand that one shouldn’t mess with the iCloud package at all, but I think just doing a copy is fine. Are there any other caveats to be aware of?
noodlema
 
Posts: 9
Joined: Thu Sep 21, 2017 12:37 am

Re: Copying photos from iCloud library Thu Sep 21, 2017 10:46 am • by Mr_Noodle
If you want to sync a folder and everything underneath it, you can use the Sync action as described here: http://www.noodlesoft.com/forums/viewto ... 1593#p6500

Otherwise, if you just want to copy specific files, you'll need to (a) write a rule to copy the files, specifying in the options that you want to copy over the folder structure as well and (b) write another rule to tell Hazel to go into subfolders. Search the help for more details on how to do (b).
Mr_Noodle
Site Admin
 
Posts: 11240
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Copying photos from iCloud library Thu Sep 21, 2017 11:32 am • by noodlema
Mr_Noodle wrote:If you want to sync a folder and everything underneath it, you can use the Sync action as described here: http://www.noodlesoft.com/forums/viewto ... 1593#p6500


Thanks. As a followup, if the target files are moved, will the source [iCloud library] copy them to the target again? I only want it copied over once, regardless if they are moved/deleted from target.
noodlema
 
Posts: 9
Joined: Thu Sep 21, 2017 12:37 am

Re: Copying photos from iCloud library Thu Sep 21, 2017 4:59 pm • by noodlema
Ok, I see how using go into sub folders rule with a copy rule option set to do not copy if duplicate works fine. If file from target is deleted it is not recopied over. I can’t believe how easy this was. Great program!
noodlema
 
Posts: 9
Joined: Thu Sep 21, 2017 12:37 am

Re: Copying photos from iCloud library Mon Sep 25, 2017 12:20 am • by noodlema
I found an issue where photos exist in the destination folder but if the rule is run manually it will sometimes copy the identical photo into the destination, appending -n to the filename where 'n' is 1, 2, 3... even though 'do not copy if duplicate' is checked in the rule options. Most of the time it matches the duplicate and doesn't copy the file over.

Note that the watched folder is the icloud library with lots of sub folders but the destination folder does not contain any subfolders. Files from the watched sub folders get copied to the destination folder (not in any subfolder).
noodlema
 
Posts: 9
Joined: Thu Sep 21, 2017 12:37 am

Re: Copying photos from iCloud library Mon Sep 25, 2017 11:16 am • by Mr_Noodle
It might not be a duplicate. In that case, if you want to overwrite the file, you need to specify that it replaces it.
Mr_Noodle
Site Admin
 
Posts: 11240
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Copying photos from iCloud library Mon Sep 25, 2017 11:49 am • by noodlema
By adding an additional 'date last modified' is after 'date last matched' condition I believe it's working as intended now, thanks.

Rules:
Go into subfolders

Copy Photos
Conditions:
Kind is image
'date last modified' is after 'date last matched'
-
Copy to folder: dest_photos_tmp Options: 'do not copy if duplicate'
noodlema
 
Posts: 9
Joined: Thu Sep 21, 2017 12:37 am

Re: Copying photos from iCloud library Sun Dec 23, 2018 3:44 pm • by lnjustin
I'm doing the same thing, except Hazel isn't copying from the Masters folder for some reason? It works on any other folder. Permissions issue? Ideas?
lnjustin
 
Posts: 13
Joined: Sun Dec 23, 2018 3:43 pm

Re: Copying photos from iCloud library Sun Dec 23, 2018 4:18 pm • by lnjustin
here's debug info:
2018-12-23 15:03:04.359 HazelHelper[45567] DEBUG: Thread 0x600000515700: Received events (
{
date = "2018-12-23 20:03:04 +0000";
path = "/Users/xxxxx/Pictures/Photos Library.photoslibrary/Masters/IMG_4489.JPG";
shouldDoFullScan = 0;
}
) for stream at path: /Users/xxxxx/Pictures/Photos Library.photoslibrary/Masters
2018-12-23 15:03:04.359 HazelHelper[45567] DEBUG: Thread 0x600000515700: Run worker for folder: /Users/xxxxx/Pictures/Photos Library.photoslibrary/Masters
2018-12-23 15:03:04.426 hazelworker[45724] Running worker (v4.3.3) for folder with identifier: 16777220-12885895098.
2018-12-23 15:03:04.472 HazelHelper[45567] DEBUG: Thread 0x600000515700: Task removed: [45724]
lnjustin
 
Posts: 13
Joined: Sun Dec 23, 2018 3:43 pm

Re: Copying photos from iCloud library Sun Dec 23, 2018 5:35 pm • by lnjustin
Ok, turns out it was working, just not in the way i expected. I was adding files to the root directory to test it out before adding a rule to apply to subdirectories. Apparently, though, it was working on subdirectories already even though i hadn't added the rule (is that a new feature?) and was copying subdirectories before copying the root.
lnjustin
 
Posts: 13
Joined: Sun Dec 23, 2018 3:43 pm

Re: Copying photos from iCloud library Mon Dec 24, 2018 1:32 pm • by Mr_Noodle
No change in behavior. Can't say what was happening before except that maybe you were copying the folders and not the individual files.
Mr_Noodle
Site Admin
 
Posts: 11240
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: Copying photos from iCloud library Tue Feb 19, 2019 10:39 pm • by spanishian
Mr_Noodle wrote:If you want to sync a folder and everything underneath it, you can use the Sync action as described here: https://thebigsleuth.co.uk/performance- ... er-review/

Otherwise, if you just want to copy specific files, you'll need to (a) write a rule to copy the files, specifying in the options that you want to copy over the folder structure as well and (b) write another rule to tell Hazel to go into subfolders. Search the help for more details on how to do (b).


Was also looking for a solution to this, syncing the folder worked for me. Thanks Mr_Noodle!
spanishian
 
Posts: 1
Joined: Tue Feb 19, 2019 10:24 pm


Return to Support