How to Create a Recent Items Stack in the Dock
Posted 01/12/2011 at 11:17am
| by J.R. Bookwalter, Cory Bohon, Scott Rose, Ray Aguilera, Adam Berenstain and Paul Curthoys

Stacks let you quickly access data from your Dock, but Apple doesn’t let you add a stack containing your most recently accessed files or apps unless you use the following Terminal command:
defaults write com.apple.dock persistent-others -array-add '{ "tile-data" = { "list-type" = 1; }; "tile-type" = "recents-tile"; }'
Then restart the Dock:
killall Dock
When the Dock reappears, you’ll find a stack of recent items beside the Trash. To change which items appear in the stack, right-click it to choose Recent Applications, Recent Documents, Recent Servers, Favorite Volumes, or Favorite Items.