Mr_Noodle wrote:Can you be more specific about how you would differentiate the files?
As for the difference between the two, a duplicate file is a file that has the same content. If a file exists, it just shares the same name.
I didn't quite understand your reply, but I'll try to clarify. My assumption is that Hazel determines if it's a duplicate based on just filename, but you've said it's based on content which changes things, I guess. My use case is a weekly payslip which arrives with a filename of "Payslip.pdf". I use Hazel to determine the date of the payslip based on content and name accordingly - "Payslip - YYYYMMDD". I then move to a folder and sort into a subfolder. All this works nicely.
Occasionally, a 2nd payslip will arrive...it's for a different $ amount, but the same pay date. Hazel renames this exactly as it would the first file that it processed because date is the only variable in the name...but I want to keep both. I just want to rename the 2nd file as "
Payslip - YYYYMMDD (Extra)" once it gets moved and sorted to the final folder and what I'd like to be able to do is base that "
(Extra)" suffix on the fact that there's already a file named "
Payslip - YYYYMMDD" there. In other words...the second file to arrive with the same
name is considered a "duplicate" (just based on the equivalent name) and that triggers an option of how to handle the "duplicate" - in this case, rename as "
[current_filename] (Extra).[extension]". This is what sparked the question about More options for handling duplicates. In this case, it could be to run another rule local to that folder (if file is a duplicate).
I may have this all wrong...let's say that Hazel's determination of a file as "duplicate" is based on content as well as filename (as you've said) - I still think these extra options to hand file duplication would be quite powerful. More options than to just "rename" with increment. There may be clever ways to do this already. I just can't think what they are.
I can see other use cases for this...if, for example, you had apparent duplicates (based on filename) in photos, you might want to file the duplicates to a subfolder called "Dupes" so they don't clutter the main folder, but you don't throw them away. Or, you might want to keep them as "[The_filename]-n" (using default rename behaviour), but then add a Tag called "Check".
And sorry, I still don't understand the difference between "If file exists (throw away)" and "Throw away if duplicate". Does the former just compare filename, but the latter compares content?
And just so I'm really clear, are you saying that if I set my rule to "(if file exists)
rename the file" AND "
throw away if duplicate", that it would still
keep a file with the same name but with different content (and rename as "[name]-n") and only throw away if all
content was exactly the same? I still think the extra options on how to treat duplicates would be useful.
Absolutely loving Hazel though...it's changed my life, man!
