Looking for a way to use Hazel for culling RAW+JPEG pairs

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

Moderator: Mr_Noodle

Hi there,

I'm faced with the scary reality that Apple's Aperture has a great number of issues in macOS Sierra.
This leaves me looking for an alternative but from what I can tell so far, there's no photo library or editing app that deals with RAW+JPEG pairs quite like Aperture. I was wondering if there's a way to use Hazel during the initial culling of photos.

Background

My camera, like most, allows the simultaneous capture of a RAW and a JPEG file. The JPEGs my camera produces are usually all I need. In cases I want to tweak the picture, I turn to the RAW file, editing it in Iridient Developer.

The files have the same name and metadata but different file extensions (.jpeg, .raf). Aperture handles these files as one item during import into the library and allows the user to select which file to use for the preview. I always choose JPEG because the import process is quicker, the file previews are smaller, and going through the imported pictures is less resource-intensive.
This is especially useful when culling photos after importing. Deleting the item removes both the JPEG and the RAW file.

This type of RAW+JPEG handling doesn't exist in any other macOS software to my knowledge. Either the files are treated separately or the JPEG is ignored completely (I'm looking at you, Lightroom :( )

I'm wondering if there's a way to emulate this behaviour with Hazel on a file system level.

Desired solution

1. Import files from camera into a predefined culling folder.
2. Sort by file type and use Quick Look on the JPEG files to quickly go through the photos, deleting the bad ones.
3. Once a JPEG file has been deleted, Hazel scans the folder for a matching RAW file and if found, deletes it, too.

Any idea how I can create a rule for this with Hazel? I have a feeling I'll need a script for this but I have very little experience in this area.

Cheers,

Alex
mangochutney
 
Posts: 2
Joined: Wed Oct 05, 2016 1:57 pm

You can try something like:
Code: Select all
If (all) are met
    If (all) are met for (the enclosing folder)
        If (none) are met for (any of its sub-files)
            Extension is (JPEG)
            Name is (Name)


See this article about nested conditions: https://www.noodlesoft.com/kb/how-to-cr ... onditions/

What that does is match if there aren't any files in the same folder (or below) that have the JPEG extension and the same name. You may need to tweak it but that should get you started.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Hi!

Thanks for your reply.

I set up the rule exactly like you said. It resulted in all files being selected in the preview.
I feel like I lack some kind of comparison for this to work. I'm not good at this kind of stuff, so please bear with me if the following sounds stupid:

Code: Select all
If (all) are met
    If (all) are met for (the enclosing folder)
        If (all) are met for (any of its sub-files)
            Extension is (RAF)
            Name contains (DSCF) <--This is the preamble in any of the files-->
            Name is (Name) <--A particlar filename?-->
         If no corresponding files exist
            Extension is (JPG)
Move files to (Trash)
mangochutney
 
Posts: 2
Joined: Wed Oct 05, 2016 1:57 pm

In my example, the "If (none) are met for (any of its sub-files)" is the "If no corresponding files exist" part for you.
Mr_Noodle
Site Admin
 
Posts: 11872
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support