MacOSXFilter: Can I sort my finder folders just like a smart playlist?
November 29, 2005 8:20 AM   Subscribe

MacOSXFilter: Is there any way to set up a folder in the finder that automatically sends stuff to other folders based on date? My downloads folder and my desktop are both a perpetual mess. I'd love it if there was a way to use applescript or what-not so that whenever I opened my downloads folder, I saw my most recently downloaded files, then a few folders containing "1 Week old downloads" "2-4 Weeks old" "+1 Month old", etc. Is this possible?
posted by anonymoose to Computers & Internet (12 answers total)
 
There is a feature called Folder Actions that you can set to trigger an Applescript when you, for example, open the folder or drop an item into it. I'm not familiar with it beyond that, but it certainly seems it would be possible to do what you describe.
posted by chrismear at 8:32 AM on November 29, 2005


Not at a Mac to play with this, but doesn't Spotlight have saved searches? I think I remember that as being one of the uses for it. Maybe do a search with the parameters you want, and then save it to the desktop.
posted by smackfu at 8:41 AM on November 29, 2005


I don't know about the Desktop, but if you have OS X Tiger, you can use the Smart Folders feature to create a virtual set of folders like you described for your downloads -- the physical files won't be moved, but you'll at least be organized.
posted by Robot Johnny at 9:00 AM on November 29, 2005


Folder Actions wouldn't really work for moving the file from the "one week old" to the "two week old" folder at the appropriate time. Smart folders are what you want. Finder->File->New Smart Folder->Last Modified->This Month->Save. But I don't see any way to do something like "2-4 weeks old." Mayber you can do that manually somehow.
posted by scottreynen at 9:11 AM on November 29, 2005


Automator has a Spotlight action. The first action can find all files > one week old, and funnel them to the next action which could move them to an archive directory.

Or something.
posted by schwa at 9:26 AM on November 29, 2005


Smart folder, smart folder, smart folders.

If you can search for it, you can turn it into a smart folder.

All my .DMG files. All my JPGs on my desktop in the last month.

A bit hard to do 2-4 weeks old. I thought perhaps you could use two Modifieds or Two creation date ranges..but I don't think so.

I keep a set of smart folders inside a folder on my desktop, for example:

DMG files
Modified today
>50 megs
movies

It encourages me, of course, to be sloppier.
posted by filmgeek at 9:30 AM on November 29, 2005


Response by poster: Seems like smart folders could potentially contain many of the stuff that I want, but is there any way to get the files OFF of my desktop?
posted by anonymoose at 1:53 PM on November 29, 2005


I'd've thought a shell script and cron would be the answer to this.
posted by pompomtom at 2:06 PM on November 29, 2005


It'd be pretty easy to set this up using an Automator script: there's a built-in action for the Finder that lets you manipulate files/folders based on Date Modified or Date Created (or any number of other criteria).

Also, don't know how familiar you are with AppleScript (I'm not), but I expect it's also possible with that tool. Have you explored the Finder's applescript dictionary to see what kinds of commands, and, more importantly, flow control you have?
posted by arakasi at 2:43 PM on November 29, 2005


Whoops and duh. See what schwa says above.
posted by arakasi at 2:44 PM on November 29, 2005


Response by poster: If I made a spotlight action, how would I get it to run whenever something is added to the desktop?
posted by anonymoose at 2:56 PM on November 29, 2005


You could wrap the Automator workflow in a folder action easily enough, but if what you're trying to sort is downloaded files, you've got two major problems that I can see:

1. In many (most?) cases, "Last Modified" doesn't reflect the date a file was downloaded.

2. Folder actions are triggered when a new file is created -- not, for example, when the file is finished downloading. So the folder action would move the file before it finished, and break the download.
posted by jjg at 3:39 PM on November 29, 2005


« Older Help with Dirty Santa gift?   |   How can I make a supplemental income? Newer »
This thread is closed to new comments.