Folder Actions…
by Dbot on Mar.29, 2009, under Macintosh, Screencasts

Leave the manual work to your folders...
Folder Actions is a great feature that OS X has to help you automate actions to be taken on files. It works by letting you associate a script to a folder that will kick off any time an item is dropped in that folder. It can do something as simple as resizing an image you drop in the folder or go as far as doing a long list of complex workflows. Check out the following screencast and some of the code I used to make a simple drop folder for uploading files to my site.
Cyberduck is the FTP client I use on OS X and it just so happens to come with some sample scripts that work well for folder actions. One of them is called “Upload Sample”. The problem with Upload Sample for me is that it is designed to connect to a specified host but as far as I could tell it needed to be anonymous access. So, I opened up the scripting dictionary for Cyberduck and found that I could add a password variable easily enough. While looking through the dictionary I saw that I could also just have it connect to a bookmark I had already set up in Cyberduck…much better! By using the bookmark I wouldn’t have to put my password in the script and it would cut down on yet another place I’d have to manage passwords when they change. The changes I made were minimal, but in the end I had a folder on my desktop that I could easily drop files into and let Folder Actions take over from there. I haven’t seen a lot of people taking advantage of Folder Actions, but after messing with them for a while I’m pretty excited about finding ways to put them to good use. I’m already thinking of adding a folder action to my torrent download folder that will automatically move downloaded files to where they belong when they’re done (move videos to the streaming share on my network, import music (freely distributed, of course) into iTunes, move eBooks to my eBook folder etc.) Seems like some powerful stuff can be done here. What are you thoughts? Anybody out there putting Folder Actions to good use?
-D

March 29th, 2009 on 4:19 pm
Nice screencast DBot!. What do you use to create your screencasts.
I have always like the functionality of Folder Actions but I don’t use any. I don’t see to have anything that I do that is that repeatable. Maybe this will inspire me to find something.
March 29th, 2009 on 5:21 pm
Thanks, homie. I use ScreenFlow, it has some pretty nice options. Kinda hard to tell after Youtube gets done compressing it, but the quality of the output ScreenFlow creates is really nice.
I’m kind of in the same boat as you as far as folder options goes. It’s such a cool function to have that I’m wanting to work it in anywhere I can, but I don’t currently use it a lot. I think the torrent sorting deal will be the next thing I do.
-D
March 30th, 2009 on 8:22 pm
You’re like T-Mobile’s Five, except with porn.
Did you blackout those growl notifications or was that a limitation of the software?
March 30th, 2009 on 9:45 pm
Coolio! I think I can definitely find a use for Folder Actions. Is that Cyberduck a free app?
March 30th, 2009 on 10:23 pm
@mconwell, lol. I blacked out the notifications and the spots on cyberduck. Unfortunately, the software I used doesn’t have a real blur/blackout solution so I put text boxes in with 100% opacity to get it done.
@TeLeKiNeSis, Yeah man. Cyberduck is free. It’s a pretty decent FTP client. It’s not the premiere FTP client for OS X like Transmit, but it’s free and functional.
-D
March 30th, 2009 on 10:33 pm
That’s cool. I will d/l that puppy then. I was wondering about the blackout spots, but I figured you added them to cover up some personal data. I’m going to have to d/l Growl as well. So much Mac goodness to get acquainted with!
April 3rd, 2009 on 10:47 pm
Great job, keep them coming.