Skip to content

Instantly share code, notes, and snippets.

@natcl
natcl / ImportPhoto.scpt
Last active November 11, 2020 18:56
OSX Folder Action to automatically import files added to a folder in Photos.app
property imageFiles : {"jpg", "pef", "dng", "jpeg"}
on adding folder items to theWatchedFolder after receiving theDetectedItems
repeat with theItem in theDetectedItems
set theItemPath to POSIX path of theItem
set ImageFile to POSIX file theItemPath
tell application "System Events"
if name extension of theItem is in imageFiles then
tell application "Photos"
set DestinationAlbumName to "Inbox"