Is it possible to display a Smart Folder as a stack in the Dock?

I'd like to have my recent files at hand from my dock, preferably via a 'stack'.

I have already created a Smart Folder containing all my files that have been opened in the last 3 days and added it to the dock. However, I can not change the display mode: it is only there as a shortcut that opens a new Finder window.

Is there any way to change this behavior?


Solution 1:

Instead of your specific recent documents search, you might also like this alternative:

defaults write com.apple.dock persistent-others -array-add '{ "tile-data" = { "list-type" = 1; }; "tile-type" = "recents-tile"; }'; killall Dock;

This adds a recent items stacks to your Dock that has customizabile viewing options (grid/fan/list/automatic) like one is used to.

The right-click menu gives you the option to choose between recent applications/documents/servers and favorite volumes/items.

Solution 2:

I would love to see a workaround that makes this possible, but by default, the answer appears to be no, you cannot do this.

It appears that a "Smart Folder" isn't actually a folder, and the operating system isn't particularly smart about treating it as if it were one. It's just a text file containing a .plist with search parameters, but when double-clicked, it prompts Finder to open a window displaying the result of that search. The Dock, however, does not have that that layer of interpretation built in, so it treats it as a file (which it is), and when clicked, it opens the file, just like any other file stored in the Dock.