Mac OS X Hints

Pry open files in the Trash

Have you ever moved a ton of files to the Trash, and then wanted to check a few of them one last time before they were gone for good? You would double-click on a file—but, alas, OS X would only tell you that you couldn’t open the document because (duh!) it’s in the Trash. Here are two workarounds.

First, you can open these files from other applications if you use the hidden Go To The Folder command. If you’d like to check some image files, for instance, use Preview. Within Preview, select File: Open.When the dialog box appears, press Command-shift-G (or press the forward slash [/]) to make the Go To The Folder entry box appear. Type

as the path, and click on Go. You’ll see a list of all the files in the Trash. Select one or more, click on Open, and voilà—Preview opens the images.

Alternatively, just use the Dock. Double-click on the Trash to open a Finder window that shows its contents. Then drag one or more files from the window, and drop them on an application in the Dock that can open that type of file.

Set multiple folder views via Automator

Do you prefer to use one type of Finder window and only one type? If so, you probably find OS X’s ability to pick different views, seemingly at random, pretty frustrating. If you’ve upgraded to Tiger, Automator has a simple solution. This two-step workflow makes all the subfolders (within whatever folder you choose) assume identical views. For example, you can make them all appear in icon view with a purple background.

Launch Automator (/Applications). Then click on the library item specified at the beginning of each step and drag the action that follows (both appear in bold below) from the Action list into the Workflow pane below any previous actions. (To learn more about Automator, see “Make Automator Work for You,” December 2005.)

Step 1 - Finder: Get Specified Finder Items Click on the plus sign (+) at the lower left corner of the Get Specified Finder Items action window. In the dialog box that appears, navigate to your user folder (or whatever folder you want to change). Click on Open.

Step 2 - Finder: Set Folder Views This action changes the settings for all folders in your user folder. Here you can set the icon size, text size, label position, item information, preview, and so on; you can even specify a background color. Select the Apply Window Properties option to show the toolbar or status bar or even set the width of the sidebar.

Folders My Way Using Automator, you can create a workflow that will give all of your folders an identical look and feel—and you’re in charge of exactly what that look will be. I’ve chosen to apply the changes to all folders, including subfolders.
(Click image to open full screenshot)

The key to the workflow is an option at the bottom of this action window. Select the Apply Changes To Sub-Folders option (see “Folders My Way” A) to change the views on all the folders in your user folder.

That’s it. Click on the Run button. When the workflow is done, every folder in your user folder will use the display settings you chose. Save your Automator workflow somewhere handy for future use. ( Click here for a more detailed version of this hint that shows how to set preferred views for newly created folders.)

Secrets of Safari’s downloads window

You can do more with Safari’s Downloads window (Window: Downloads) than just monitor your downloads. For instance, consider this relatively common situation:You download an app, try it out, and decide you don’t like it. You send it to the Trash along with the downloaded disk image—but a bit later on, you want to give it another look.

You might think you have to start over again at the developer’s Web site. As long as you haven’t cleared Safari’s Downloads window (by clicking on the Clear button), that’s not the case. Instead, you can find the entry for the program, press Command-C to copy it, then press Command-V to paste it right back into the Downloads window. Presto—the file starts downloading again.

Ah, but what if you have accidentally cleared the Downloads window? It’s an easy mistake to make: you highlight one entry and then click on the Clear button to erase it. Unfortunately, that’s not what the Clear button does; it erases all entries in the Downloads window. Thankfully, there’s a way to recover from this scenario, and it’s amazingly easy. Just press Command-Z (Edit: Undo) while the Downloads window is active, and your list will magically reappear. You can even do this after you’ve switched to the standard browsing window and done some surfing. The only things that will destroy your chances of recovery are quitting Safari or downloading another file. Once you’ve done either, your entries are gone for good.

Reclaim RAM by disabling Dashboard

Whenever you press F12, Tiger’s Dashboard offers a wealth of information on everything from airline flights to currency conversions to stock prices. But this power comes at a price: open widgets eat up RAM, even if the Dashboard layer is inactive.

RAM Dashed Using Dashboard’s widgets is fun, productive, and a potential RAM-waster. As seen here, each widget can take up a fair amount of RAM. If you have a severely memory-limited machine, consider disabling Dashboard.

To see how much RAM your widgets use, open them and then launch Activity Monitor (/Applications/Utilities). In the search box, type

. Look at the Real Memory column to see how much RAM each widget uses. A typical one consumes about 10MB (see “RAM Dashed”). Open ten at once, and there goes 100MB of memory.

Consider disabling Dashboard if you’re short on RAM or if you run a regulated environment, such as a school lab. To do so, take a trip to Terminal (/Applications/Utilities) and type this command:

defaults write mcx-disabled -boolean YES

Press the return key. To make your changes take effect, you must restart the Dock. Since Terminal is already open, the easiest way to do that is to type this command and then press return:

killall Dock

After the Dock restarts, press F12 and you’ll see—nothing. To make Dashboard return, open Terminal again, type this command, and press return:

defaults write mcx-disabled -boolean NO

Once again, you’ll have to use the

killall Dock
command to make the changes take effect. When you do, Dashboard will return and any widgets you had open will be active.

Disable iChat’s smiley graphics

Because expressing subtle emotion in e-mail and chat messages is so difficult, the smiley, also known as the emoticon, was born. These combinations of punctuation and letters let you smile, laugh, and otherwise emphasize a point. Apple’s iChat swaps in a graphic when you type text smileys. If you find smileys annoying, here’s how to banish them from your chats. (Other people will still see the graphics on their Macs when they chat with you, unless they also follow these instructions.)

If you’ve upgraded to OS X 10.4.3, you’re in luck. All you need to do is go to the View: Hide Smileys menu to disable them all. (Go to the Software Update preference pane to make sure you have the latest version of the OS.) If you’re using Panther (OS X 10.3), follow these instructions:

First, quit iChat. Control-click on the iChat application and select Show Package Contents from the pop-up menu. Navigate to /System/Library/PrivateFrameworks/InstantMessage.framework/Versions/A/Resources/English.lproj.

You’ll find a file there named SmileyTable.plist. Hold down the Command key, and then drag the file to the desktop. Your Mac will prompt you for your password. Enter it and then restart iChat, and you’ll find that all smiley graphics have vanished.

If you want to get your smileys back, Command-drag the file back to its original location, and then restart iChat.

Whether you’re using the newest version of Tiger or Panther, you might find that only some smileys are intrusive. For instance, Excel users will find it impossible to receive the formula =(A3+B3) via a chat, because =( is a hidden shortcut for a frown face. Click here to learn how to disable particular smileys.

Track down installation details

Ever wonder exactly what gets installed when you run one of Apple’s Software Updates? By using Terminal, you can usually find out exactly what an installer added to your system. This can be useful if you have trouble with an update, or if you’d like to remove a program that doesn’t include an uninstaller.

OS X keeps track of installation details in the /Library/Receipts folder. Open Terminal (/Applications/Utilities) and type the command

ls -al /Library/Receipts
to see this folder’s contents. A long list of receipt files (one for every program you’ve installed on your Mac) will greet you. These files are actually folders; within each one is a document that lists every file changed by that program’s installer.

Take, for example, the listing Safari.pkg. To see what files Safari’s installer changes, type these commands into Terminal (ignoring the

, which stands for the Terminal prompt):

	$ cd /Library/Receipts
	$ cd Safari.pkg/Contents
	$ ls -al

These commands switch into the Receipts directory, navigate into the Contents folder within the Safari package, and then list the files within that folder.

It’s the Bom! To see a list of every file that changed when you installed a program, use the lsbom command.

You’re interested in the file ( bom stands for “bill of materials”). It contains an inventory of every file the installer touched. Using the Unix command

(which lists the contents of a .bom file), you can get a list of the changed files by typing
lsbom -pf | more


bit tells
to show only file names; otherwise, you get a lot of excess information. Type this command and press return to see output fill your Terminal window (see “It’s the Bom!”). The list of files is huge—more than 2,900 entries. To stop the output, just press Q while it’s paused at the bottom of a screen. You may find the
command most useful when you’re investigating the impact of small programs that use Apple’s installer.

As with Safari, you’ll find most .bom files in the Contents folder within the application’s package. Most will also be named But there are exceptions: for instance, DVD Player Update’s .bom file is called and lives in the update’s /Contents/Resources folder. If you can’t find the .bom file you’re looking for, change directories (using the

command) into the application’s package, and then type this command:

find . -name "*.bom"

This will locate any .bom files at or below the currently active directory and display the path and file name for any matches it finds.

OS Xs secret Services

You’ll find Mac OS X’s Services menu in every single Mac application, under application name: Services. But if you’re like most users, you probably haven’t given it a second glance. That’s a shame, because services let you access the powers of other applications while staying right where you are—in other words, they’re big time-savers.

From this menu you can, for example, quickly create a Font Book collection of the fonts that appear in a selection of text in a TextEdit document. But that’s not all—with one menu selection, you can also send the text via Mail, make a Stickies note containing the text, or run a Spotlight search on the text (see screenshot). Some services have keyboard shortcuts—Command-shift-L, for instance, will search Google using the selected text as the search term.

Select a Service OS X’s Services menu offers many useful goodies.

Savvy Application Required Even though you’ll find the Services menu in every program, its items aren’t active in all of them. Services work automatically in some, but not all, applications. For instance, they’ll work in all major Apple apps, since they’re developed using something called the Cocoa programming environment. Third-party developers, however, may not use Cocoa, and must explicitly add support for services. So you’ll find that services work in BBEdit but not in Microsoft Word or Excel. The only way to know for certain is to try them.

What if you know the program you’re in supports services, but all the menu items still appear grayed out? Remember that you must first select something—a file, a folder, or a chunk of text—to use a service.

An Ever Expanding Menu Your brand-new OS X machine may have only 15 or so services on offer, but expect this number to increase over time as applications add services. My Mac lists 73 top-level entries.

Many programs add useful systemwide services. Stairways Software’s Interarchy, for instance, adds an Upload File option that makes quick work of sending files to a Web server. But the Services menu can become so large that it’s difficult to use. Apple doesn’t provide an easy way to remove unneeded Services items, but you can do it yourself.

Subscribe to the Best of Macworld Newsletter