macdevcenter.com
oreilly.comSafari Books Online.Conferences.

advertisement

AddThis Social Bookmark Button

Mac OS X Power Hound Helpful Hints, Part 1
Pages: 1, 2

Tip 5-18. Storing Apple Software Updates

Software Update has another annoyance. If you ever reinstall Mac OS X from its original CD or DVD (when you put in a new hard drive or move to a new computer, for example), you'll have to download and install all relevant updates again. With this hint, you can't skip the reinstallation process completely, but you can skip the download step. Preserving updates on your hard drive is easy enough. Each time Software Update finds updates to install, turn on the ones you wish to install and then choose Update -> Install and Keep Package, as shown in the figure below. If you prefer, you can also use Update -> Download Only, and install the update later at your convenience.

Preserving updates on your hard drive is easy enough.
Preserving updates on your hard drive is easy enough

The downside to this method: when there are multiple updates that require restarting your Mac, you must restart after each one you install. On its own, Software Update would save up its one restart until all of the updates were installed.

This method is also a good one to use if you work in a lab, or other environment with a bunch of Macs--it's much easier to download once and install many times, rather than downloading multiple copies of the same 50MB system update.

Tip 6-4. Use .Mac Slideshow Images as Desktop Backgrounds

One of the cooler features of the .Mac service is the ability to create a public slideshow directly from iPhoto--just select an album and click the .Mac Slides button. After iPhoto finishes uploading your images, you can tell anyone who has Mac OS X 10.2 or newer your .Mac name. Subsequently, they can use your slideshow as a screen saver by selecting .Mac in System Preferences (in the Desktop & Screen Savers pane in 10.3, or the Screen Effects pane in 10.2), as seen in the figure below.

Anyone can use your slideshow as their screen saver by selecting .Mac in System Preferences
Anyone can use your slideshow as their screen saver by selecting .Mac in System Preferences

One of the challenges of this feature, though, is trying to find public slideshows to use with it; unless all of your friends and relatives are fellow .Mac types, you may find the selection to be quite limited. This is where dotmac.info comes in, since it has a section devoted to nothing but public .Mac slideshows (click Browse Slide Shows). Look through the collections, then enter the associated .Mac user name into System Preferences for those you'd like to use.

Viewing .Mac screen savers can be quite relaxing, but your machine must be idle for you to enjoy their benefits. Wouldn't it be nice if you could use some of the images for your desktop background, too? Well, it turns out that you can do just that. Switch to System Preferences -> Desktop & Screen Saver -> Desktop tab and click Choose Folder from the list of screen savers. In the resulting dialog box, navigate to your Home -> Library -> Caches -> com.apple.iToolsSlideSubscriptions folder.

This folder holds all of the public slideshows that you're currently subscribed to, organized by .Mac user name. Select the name of the user whose slideshow you'd like to see on your desktop, click the Public Slide Show folder, then click Choose. Finally, turn on the Change Picture checkbox. You can now enjoy the public slideshow as an ever-changing desktop image that you can see, even while you work.

Note that you can also copy the images out of the Caches folder to keep them for future use--but be aware of copyright issues. The copyright on the images is owned by the .Mac user who published them, so you can't simply copy their work and use it as you wish! If you want to do anything beyond using an image on your own machine, you'll need permission from the original .Mac publisher first!

Tip 7-12. Force Messages into Plain Text Mode

When email was still a fresh, new thing (you know, about 15 years ago), all messages were sent in "plain text" mode. A plain text message contains no graphics, sounds, different font faces, colored backgrounds, or any other distractions--just the message, typically displayed in a typewriter-looking monospaced font such as Monaco. Only as email matured would it gain the aforementioned distractions (marketers call them "enhancements").

If you prefer your email the way the Net intended, you've probably searched Mail's preferences high and low for a plain-text-only setting but come up empty-handed. The closest you can come is to turn off the "Display images and embedded objects in HTML messages" setting in the Viewing section of Mail's preferences. (This setting is also an effective way to make sure that spammers can't use embedded images to collect information about your Mail viewing habits. Embedded images can be used to verify that you have opened their messages, thereby insuring a continued flow of spam into your inbox.)

It turns out, though, that you can force nearly all of your inbound messages into plain text mode. Make sure Mail isn't running, then launch the Terminal (in Applications -> Utilities) and type this (hit Return at the end):

defaults write com.apple.mail PreferPlainText -bool true

When you launch Mail again, you'll find that most of your messages are now displayed in glorious plain text. The only exceptions will be messages that are sent with only HTML content. When you think about it, since there's no plain text alternative, there's no way Mail can force a plain text display. If you ever feel like rejoining the modern era, quit Mail, launch the Terminal, and repeat the above command, but replace true with false.

Tip 8-16. Save Videos and Trailers After Viewing

The iTMS movie trailers and music videos are often high-quality, large videos that can be fun to watch repeatedly. However, the way the store works, once you've downloaded and watched a video, it's basically gone. If you want to watch it again, you'll have to download it again, and there's no apparent way to save it. Downloaded videos and trailers, however, are actually stored for a while on your hard drive. They're in a hidden folder that gets erased each time you reboot your machine. With the help of AppleScript, you can copy these videos from the hidden folder to your desktop, making it easy to keep them for future viewing.

Open Script Editor (in Applications -> AppleScript), and enter the following text (alternatively, just click this link and the script should magically appear in a new Script Editor document):

set originalFile to do shell script "lsof -wa -Fn -c iTunes 
  +D /tmp | grep -i QTP | head -1 | cut -c 2-"
if length of originalFile is greater than 0 then
  set newFile to POSIX 
  path of (choose file name default name "iTunes Video.mov")
  if length of newFile is greater than 0 then
    if newFile does not end with ".mov" then set newFile to 
      newFile & ".mov"
    do shell script "/bin/cp -v '" & originalFile & "' '" & 
      newFile & "'"
    do shell script "/Developer/Tools/SetFile -t 'MooV' -c 
      'TVOD' '" & newFile & "' || true"
  end if
else
  display dialog "No movie found. Please make sure that 
  the movie is currently visible in iTunes." buttons 
  {"OK"} default button "OK"
end if

Note: The "" characters are used in AppleScript to indicate the continuation of a line. Do not enter them when you see them here. Instead, type the next line as a continuation of the line containing the "" symbol. Click the Compile button to insure you didn't make any typos, and then use File -> Save to save your script. In the Save dialog box, set the File Format to Application, and check the Run Only box. Name the script whatever you want, then save it into your Documents folder (or some other easy-to-find location). Quit Script Editor.

Now visit the iTMS, find a video or trailer you'd like to keep, and let it completely download. While the iTMS window is still open, switch to the Finder and double-click your new script. After a brief delay, you should see a Save dialog box; enter a name and pick a folder to store it in, then click OK. The script will find the movie, rename it, and copy it to your destination. Furthermore, it'll make sure the type and creator values are set properly for QuickTime to play the video.

Note: This script requires that you have the XCode Developer Tools installed. If you don't have the tools, you can still use the script--just remove the line that begins with do shell script "/Developer/Tools/SetFile -t. You may then have to open the movie directly from QuickTime or use another tool to set the type and creator codes.

Rob Griffiths is the creator of the Mac OS X Hints site, a database of over 3,500 tips on using OS X.


Return to MacDevCenter.com.