If file sequence, then do an action

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

Moderator: Mr_Noodle

If file sequence, then do an action Tue Nov 15, 2011 9:54 am • by franck
Hello!

I do a lot of 3D renderering and get one folder filled up with different 3D passes.
F.eks
One pass looks like this: 3D hazel test0000- 3D hazel test0999
Another pass looks like this: 3D hazel test_object_1_0000 - 3D hazel test_object_1_0999
Another like this: 3D hazel test_rgba0000 - 3D hazel test_rgba0999

What I would really like is that finder only shows me the file sequence as a group.
This isn't possible as far as I know, so my next best thing, would be to move each file sequence into separate subfolders.
The real challenge here is that each sequence will be named differently from project to project, so my question is this:

Can hazel recognize an image sequence and then move each sequence to a subfolder?
If yes, can it also name that folder with all the characters before the file numbering? Ex:
3D hazel test
3D hazel test_object_1
3D hazel test_rgba
franck
 
Posts: 5
Joined: Tue Nov 15, 2011 9:38 am

Re: If file sequence, then do an action Tue Nov 15, 2011 11:48 am • by Mr_Noodle
Yes, you can have Hazel grab the beginning part as long as it's somewhat well defined. Look up "pattern matching" in the help.
Mr_Noodle
Site Admin
 
Posts: 11865
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: If file sequence, then do an action Wed Nov 16, 2011 9:23 am • by franck
That's great!
Now I got an action working just fine this way :)

But is it possible to let hazel understand that each image sequence should go into separate folders?
I haven't understood how I can use pattern matching for this...
Let say I have these two file sequences in the same folder:
3D render_0000 -> 3D render_0099
TestHazel0000 -> TestHazel0099

How do I make one rule that makes Hazel understand that the first is one sequence and the other a different one? This rule must apply so that next time sequences are called something else it must work as well?

F.eks:
RenderTest09_0000 -> RenderTest09_0099
TestingHazelsSeq 0000 -> TestingHazelsSeq 0099
franck
 
Posts: 5
Joined: Tue Nov 15, 2011 9:38 am

Re: If file sequence, then do an action Wed Nov 16, 2011 11:51 am • by Mr_Noodle
Do you want the 3D render XXXX files to go to a folder called "3d render"? If so, just have a custom token match the first part of the name and use that custom token in the sort into subfolder pattern. If I'm misunderstanding what you are trying to do then you need to provide more details on what the workflow is.
Mr_Noodle
Site Admin
 
Posts: 11865
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: If file sequence, then do an action Wed Nov 16, 2011 12:13 pm • by franck
I might just be explaining myself badly here.
Simply put, this is what I want to happen:

1 - I have a folder filled with different sequences (I have no control over the naming except the digit count at the end of the file)
2 - Hazel should be able to recognize that each of these sequences are indeed sequences (no matter how many different sequences there are. Meaning I cannot search for "3D render" as I don't have control over the naming)
3 - Hazel moves each sequence separately into a folder like you suggested: "3D render XXXX" into folder called "3d render"

Was this clear?
franck
 
Posts: 5
Joined: Tue Nov 15, 2011 9:38 am

Re: If file sequence, then do an action Wed Nov 16, 2011 5:23 pm • by Mr_Noodle
Yes, so again, pattern match. Don't look for "3d render". Match something like:

(• sequence name) (number)

where sequence name matches "anything". So, any text up to a space and then a number at the end will be stuck in the custom token "sequence name" which you can then use to name the folder.
Mr_Noodle
Site Admin
 
Posts: 11865
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City

Re: If file sequence, then do an action Wed Nov 16, 2011 5:55 pm • by franck
Damn...This works :)
It was that simple!
I am not sure exactly what I did at first, but I only managed to move each file into it's separate subfolders.
But now it works like I want it to every time.
Thanks a million :)
franck
 
Posts: 5
Joined: Tue Nov 15, 2011 9:38 am

Re: If file sequence, then do an action Fri Nov 18, 2011 10:09 am • by franck
Ok... A New question:

Is it possible to let Hazel start doing an action sequence by either automater/applescript/etc.?

The reason I am asking, is that I wish to let Hazel do it's sequence organization magic on a specific folder. But that folder might change from job to job.
The workflow is this:
1 - 3D rendering
2 - When finished, Hazel is triggered with a script that tells it what folder (and actions) it should work on.
3 - Hazel organizes all the sequences
4 - Hazel stops
5 - I am happy :)

The 2nd point in the workflow is what I am wondering about.
How do you do that?
franck
 
Posts: 5
Joined: Tue Nov 15, 2011 9:38 am

Re: If file sequence, then do an action Fri Nov 18, 2011 1:30 pm • by Mr_Noodle
Is there some condition on the file that changes that Hazel can pick up? Like is a new file created or is the modified date updated? If not, if you can have the workflow set the color label on the file, then you could have Hazel pick up on that.
Mr_Noodle
Site Admin
 
Posts: 11865
Joined: Sun Sep 03, 2006 1:30 am
Location: New York City


Return to Support