Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

GroundLoop

macrumors 68000
Original poster
Mar 21, 2003
1,586
62
I could really use some help here...

My wife is trying to migrate from the Apple Photos app to Adobe Lightroom. Here are the issues:

  1. She wants to be able to maintain her existing albums in Photos
  2. She wants keep the unmodified originals for the photos that have not been edited and the edited JPG for the photos that she has edited.
I found this AppleScript online that will do most of what she needs, but it doesn't check to see if the photo is edited to determine if it should keep the original or export the edited photo (needs to be edited at line 7).

Code:
set dest to "/Users/me/Desktop/photos-Albums/" as POSIX file as text -- the destination folder (use a valid path)

tell application "Photos"
    repeat with i in albums
        set tFolder to dest & (get name of i)
        my makeFolder(tFolder) -- create a folder named (the name of this album) in dest
        export (get media items of i) to (tFolder as alias) without using originals
    end repeat
end tell

on makeFolder(tPath)
    do shell script "mkdir -p " & quoted form of POSIX path of tPath
end makeFolder

I am not an AppleScript guy, can someone here help me out? I really don't want to do this manually for over 4000+ albums and 50,000+ photos.

Many thanks in advance.
 
Last edited:
I could really use some help here...

My wife is trying to migrate from the Apple Photos app to Adobe Lightroom. Here are the issues:

  1. She wants to be able to maintain her existing albums in Photos
  2. She wants keep the unmodified originals for the photos that have not been edited and the edited JPG for the photos that she has edited.
I found this AppleScript online that will do most of what she needs, but it doesn't check to see if the photo is edited to determine if it should keep the original or export the edited photo (needs to be edited at line 7).

Code:
set dest to "/Users/me/Desktop/photos-Albums/" as POSIX file as text -- the destination folder (use a valid path)

tell application "Photos"
    repeat with i in albums
        set tFolder to dest & (get name of i)
        my makeFolder(tFolder) -- create a folder named (the name of this album) in dest
        export (get media items of i) to (tFolder as alias) without using originals
    end repeat
end tell

on makeFolder(tPath)
    do shell script "mkdir -p " & quoted form of POSIX path of tPath
end makeFolder

I am not an AppleScript guy, can someone here help me out? I really don't want to do this manually for over 4000+ albums and 50,000+ photos.

Many thanks in advance.
Afraid I can't help directly but if no one here gets back to you try over on the dpreview.com forums. There might be the right expertise there.
 
  • Like
Reactions: phrehdd
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.