Section 2.14. Finding Files 2: The Find Command

2.14. Finding Files 2: The Find Command

Mac OS X's File Find command ( -F) opens the Search window shown in Figure 2-27. It's a lot more powerful (and complex) than the basic Spotlight menu, because it can hunt down icons using extremely specific criteria. If you spent enough time setting up the search, you could use this feature to find a document whose name begins with the letters Cro , is over one megabyte in size , was created after August 24 but before the end of the year, was changed within the last week, has the file name suffix .doc , and contains the phrase "attitude adjustment." (Of course, if you knew that much about a file, you'd probably know where it is, too, without having to use the Search window. But you get the picture.)

Figure 2-27. The first time you use it, the new Search dialog box opens up ready to search your entire hard drive (except other people's Home folders), regardless of file type. But don't settleSpotlight has many more tricks up its software sleeve.


UP TO SPEED
The Search Bar

See the ovalish text box at the top of every Finder window? This, too, is a piece of the Spotlight empire. The beauty of this bar, though, is that it can search only the open window (including any folders in it, and folders within folders, and so on).

To use it, just type a few letters of whatever you're looking for. The window instantly changes into the Search dialog box described on the previous pages, with one key difference: Among the search places listed along the top (Home, Computer, and so on), you'll see the name of the window you're searching. It will say, for example, "Folder 'Music.'"

What's so convenient about this feature is that you can narrow the scope of your search to just the current window by clicking that button. Spotlight doesn't even make you retype the search request.

Even better, once you've clicked the current-folder button in one Search window, Mac OS X will remember to narrow your results for each subsequent search you do. In other words, you've just told Mac OS X that you always want it to search only inside the current windowat least until you click a different button at the top of the window.

In any case, once you've rounded up a list of matches, you can work with them just as described on Section 2.14.3.


2.14.1. Where to Look

The words at the top of the windowServers, Computer, Home, and Othersare buttons . You click one to specify where you want Spotlight to do its searching. Here's what they mean:

  • Servers refers to other computers on your network, assuming you've brought their icons to your screen as described on Section 5.2.3.

  • Computer means your entire hard drive, except what's in other people's Home folders.

  • Home is your own Home folder (and not, say, the Applications folder, the Shared folder, or any other folders on your hard drive).

  • Others lets you limit your search to certain disks or folders (see Figure 2-28). You could do that to make the search even faster, or just to avoid having to wade through a lot of irrelevant results.

    Once you've added a new search location to the list, it sprouts its own button at the top of the window, so that it's available the next time you want to search. (If you dragged in a group of folders, the button says, for example, "3 folders.")

Figure 2-28. To limit a search by restricting it to a certain disk or folder, click Others. This list box appears. Now you can drag a disk, a folder, or a set of folders directly off the desktop and into the list. Or click + and then navigate to the item you want to add. (To ditch something, click it and then click the button.)


2.14.2. What to Look For

If all you want to do is search your entire computer for files containing certain text, you may as well use the Spotlight menu described at the beginning of this chapter.

The power of the Search window , though, is that it lets you design much more specific searches, using over 125 different search criteria: date modified, file size, the "last opened" date, color label, copyright holder's name, shutter speed (of a digital photo), tempo (of a music file), and so on. Figure 2-29 illustrates how detailed this kind of search can be.

Figure 2-29. By repeatedly clicking the + button at the right end of the search-criteria rows, you can limit your search to files that were created before or after a certain date, that are larger or smaller than a certain size, and so forth.


To add a criterion to the list, click one of the + buttons at the right end of the dialog box. A new row appears in the window, whose pop-up menus you can use to specify what date, what file size, and so on. Figure 2-29 shows how you might build, for example, a search for all photo files that you've opened within the last week that contain a Photoshop layer named Freckle Removal .

To delete a row from the Find window, click the button at its right end.

Here's a rundown of the ways you can restrict your search, according to the options you'll find in the first pop-up menu of a row. Note that after you choose from that first pop-up menu (Last Opened, for example), you're supposed to use the second pop-up menu to narrow the choice (Within the Last 2 weeks), as you'll read below.

  • Kind . When the first pop-up menu says Kind, you can use the second pop-up menu to indicate what kind of file you're looking for: Images, Text files, PDF files, Movies, Music, Documents, Presentations, Folders, or Applications. For example, when you're trying to free up some space on your drive, you could round up all your gigantic movie files.

    And what if the item you're looking for isn't among the nine canned choices in the second pop-up menu? That's what the Others option is all about. It's the rabbit hole into a staggering array of hundreds of file typesranging alphabetically from ".D document" to "ZIP archive"that Spotlight knows about. To specify which of these oddball file types you want to round up, you can either choose from the Others pop-up menu shown in Figure 2-30, or you can type part of a file type's name into the text box; Mac OS X fills in the closest match automatically.

    Figure 2-30. To search for a file type other than one of the nine listed in the second pop-up menu, choose Others (A). Now you can use the (C) pop-up menu to choose among hundreds of file types, or "type select" one by typing into the text box (B).


  • Last Opened/Last Modified/Created . When you choose one of these options from the first pop-up menu, the second pop-up menu lets you isolate files, programs, and folders according to the last time you opened them, the last time you changed them, or when they were created.

    The commands at the top of the pop-up menu (Today, Since Yesterday, This Month) offer canned time-limiting options. The commands at the bottom (Exactly, Before, After, Within Last) let you be more precise with your time-limiting.

    In any case, these are awesomely useful controls, because they let you specify a chronological window for whatever you're looking for. In fact, you're allowed to add two Date rows, which lets you round up files created before one date and after another.

  • Keywords . You're most likely to encounter keywords in saved Web pagesthey describe what the Web pages are about , rather than what specific words the pages contain.

  • Color Label . Mac OS X lets you not only tag certain icons with color labels (Section 2.10.1), butperhaps even more importantlylets you round them up later, for backing up, deleting, or burning to a CD en masse, for example. The criterion row sprouts seven colored dotsrepresenting the seven available color labelsplus an X, which means "find all icons with no label applied."

  • Name . The beauty of Spotlight is that it finds text anywhere in your files, no matter what their names are. That's why Apple demoted this optionthe icon's nameto such a low position in the pop-up menu.

    Still, one nice thing about this criterion is that you can add it more than once , to create super-specific name searches. If you want to find file names that start with "Chewbacca" and also contain "nude," now you know how.

  • Contents . You can think of this option as the opposite of Name. It finds only the text that's inside your files, and ignores their icon names. That's handy when you can't remember what you called a file, for example, or when a marauding toddler renames your doctoral thesis "xggrjpO#$5%////."

  • Size . Using this control, and its "Greater than"/ "Less than" pop-up menu, you can restrict your search to files of a certain size. Use the second pop-up menu to choose KB (kilobytes), MB (megabytes), or GB (gigabytes).

  • Other . Choosing Other from the first pop-up menu opens a special dialog box containing more than 100 other criteria. Not just the big kahunas like Name, Size, and Kind, but far more targeted (and obscure) criteria like "Bits per sample" (so you can round up MP3 music files of a certain quality), "Device make" (so you can round up all digital photos taken with, say, a Canon camera), "Key signature" (so you can find all the GarageBand songs you wrote in the key of F sharp), "Pages" (so you can find all Word documents that are really long), and so on. As you can see in Figure 2-31, each one comes with a short description.

You never know. Someday, you may remember nothing about a photo you're looking for except that you used the flash and an F-stop of 1.8.

Figure 2-31. Each option comes with an appropriate set of "find what?" controls. For example, if you choose a criterion that requires a number, like "Pixel height" (how tall a photo is), you'll get a "Greater than"/ "Less than" pop-up menu and a box where you can type in a number. Type in the parameter you want, and let Spotlight do the rest.


2.14.3. What to Do with Search Results

You can manipulate the list of search results much the way you'd approach a list of files in a standard Finder list view window. You can move up or down the list by pressing the arrow keys, scroll a "page" at a time with the Page Up and Page Down keys, and so on. You can also highlight multiple icons simultaneously , the same way you would in a Finder list view: Highlight all of them by choosing Edit Select All, highlight individual items by -clicking them, drag diagonally to enclose a cluster of found items, and so on.

Or you can proceed in any one of these ways:

  • Find out where something is . If you click once on any item in the results list, the bottom edge of the window becomes a folder map that shows you where that item is. To get your hands on the actual icon, just choose File Open Enclosing Folder ( -R).

  • Open the file (or open one of the folders it's in) . If one of the found files is the one you were looking for, double-click it to open it (or highlight it and press either -O or -down arrow). In many cases, you'll never even know or care where the file wasyou just want to get into it.

    You can also double-click to open any of the folders that appear in the folder map in the bottom half of the window.

  • Move or delete the file . You can drag an item directly out of the found-files list and into a different folder, window, or diskor straight to the Dock or Trash.

  • File-menu commands . After highlighting an icon (or icons) in the list of found files, you can use the commands in the File menu, including Get Info , Add to Sidebar, and Move to Trash.

  • Collapse the list . By clicking the flippy triangles , you can collapse or expand the category headings, just as in the regular Spotlight window. Once again, you can also Option-click a flippy triangle to expand or collapse all of them at once.


    Note: This results window offers several other controls that should look familiar if you've experienced the thrill of the Spotlight window. For example, the blue heading for Images offers a slideshow button, a list-view button, and a thumbnails-view button. And every item offers an button at the far right of its row, for quick detailed information.
  • Copy a file . To copy a file, Option-drag it out of the Search Results window and onto the desktop, into a different window, or onto a disk or folder icon. Alternatively, highlight the file and then choose Edit Copy "Bunion Treatments.doc(or whatever the file's name is). Then click inside a different folder window, or click a folder itself, before choosing Edit Paste.

  • Make an alias . You can make an alias for one of the found items exactly the way you would in a Finder window: Drag it out of the window while pressing -Option. The alias appears wherever you release the mouse (on the desktop, for example).

  • Start over . If you'd like to repeat the search using a different search phrase, just edit the text in the Search bar (you can press Option- -F to select the text). The results pane updates itself as you type.

  • Give up . If none of these avenues suits your fancy, you can simply close the Search window as you would any other ( -W).



Switching to the Mac[c] The Missing Manual
Switching to the Mac[c] The Missing Manual
ISBN: 1449398537
EAN: N/A
Year: 2006
Pages: 371

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net