I use SyncTogether to keep my iMac and MacBook (both Leopard) in sync. I usually sync iCal, Address Book, bookmarks, notes and Dock items. Several days ago, however, I started to notice a very annoying issue with my iMac's Dock: some items started to move around on the Dock, or completely disappeared from it. Even if I placed the vanished items back on the Dock and selected Keep in Dock, they vanished after a while.
I can't remember what was I doing when it started, but yesterday, the problem replicated itself to the MacBook. Other accounts were working normally, but not mine. I deleted the com.apple.dock.* files, but nothing changed. After using fsevent for a while, I noted some recent activities in ~/Library » Application Support » SyncServices » Local.
I decided to make a backup of that whole directory, and in a brute force way, I then deleted the content of the clientdata and DataReferences folders within that directory. After setting up my Docks again on both machines, everything has remained in place -- so far, the Dock is working perfectly on both Macs.
I'm not positive if this is related to SyncTogether, but I mention it because the solution was related to syncing. I think I synced Preferences, too, one time not so long ago, so maybe that was the origin of all these problems. In any event, I hope this helps someone who may be having the same issues.
I use a small utility called Witch to switch between open windows in applications via Option-Tab, instead of using the built-in Command-Tab, which just switches between applications. I recently realized that, when Dashboard is active (F12), you can use Witch (Option-Tab) to select a window, and then you can do some things in this window while still having Dashboard active and frontmost.
For example, you can select a TextEdit window and write in it, jotting down some notes relative to something in a Dashboard widget. This will work as long as you don't click the mouse button. I've found this quite useful at times.
[robg adds: This could also be useful for selecting text in a background window and copying it (hold down Shift and use the arrow keys to select text, then press Command-C), for pasting into a Dashboard widget, if you forgot to copy it before you invoked Dashboard.]
It is possible to use Disk Utility to erase the free space on a disk. However, I had difficulty finding a command, such as hdiutil, to do it from the command line. One advantage of doing it from the command line is that it is easier to use cron or launchd to automate the process.
It turns out the solution is relatively straightforward:
The first part of the command will keep enlarging a file with zeros until disk space runs out. After an error, the second part will delete the empty file. Lather, rinse, repeat for extra security (7-pass, 35-pass Guttman).
[robg adds: I haven't tested this one...however, I'd be somewhat cautious about using it on your boot drive. Running out of space on the boot drive -- even briefly -- may cause issues. If you know more about that possibility than I do, please comment!]
This works fine, but you may find entries like this in you logs, repeated every 10 seconds:
01.04.08 10:54:17 com.apple.launchd (com.domain.whatever) Throttling respawn: Will start in 9 seconds
01.04.08 10:54:28 com.apple.launchd (com.domain.whatever) Throttling respawn: Will start in 8 seconds
01.04.08 10:54:38 com.apple.launchd (com.domain.whatever) Throttling respawn: Will start in 9 seconds
In my case, I took the new files to OCR, saved them as PDFs, and removed the files after processing. But still, launchd started and stopped every 10 seconds. But why? The answer is quite easy: the Finder placed an invisible .DS_Store in that folder. My AppleScript did not remove it, but launchd was aware of that "new" file, and restarted endlessly. Fix: remove the .DS_Store as last action of your AppleScript:
set DeleteMe to alias "hd:any:path:to:a:folder:.DS_Store"
set rmMe to POSIX path of DeleteMe
do shell script "rm " & quoted form of (rmMe)
With this fix, launchd will stop restarting. There might be other ways to get rid off these .DS_Store's, but this was the easiest fix for me.
I use a 2.33Ghz MacBook Pro as the main workhorse for my production business, and I have Windows XP SP2 installed via Boot Camp to run some Windows-only software that I need to run natively (ie not in Fusion or Parallels). However, I soon tired of switching the boot disk from 10.5.2 to XP and back. So I came up with this little timesaver by putting shortcuts to the System Preferences Startup Disk panel (in OS X) and the Boot Camp Control Panel (in Windows XP) on their respective desktops and dock. It saves me a couple of steps and makes the rebooting process acceptable.
In Mac OS 10.5.2, navigate to /System/Library/PreferencePanes, and find StartupDisc.prefPane. Create an alias of the StartupDisc.prefPane, and drag the alias to the Desktop or the Dock. I changed the icon to a Windows icon, and the text to Shortcut to Win XP.
While in Windows XP, open the Control Panel, then right-click on the on the Boot Camp Control Panel item. Select Send to Desktop from the pop-up menu to create a shortcut on the Windows Desktop, and rename as desired.
[robg adds: You can, of course, use the Option key during boot to select the startup disk. This method, however, might be easier for novices to use, or helpful if you want to restart the machine and walk away during the boot process.]
While trying to debug a problem with Help Viewer (it's hanging with the spinning gear icon whenever I use the search field), I stumbled across this page, which includes a ton of information on debugging Help Viewer. Buried in the details is this tidbit on enabling Help Viewer's debug mode. Quit Help Viewer, then open Terminal and type:
Now when you launch Help Viewer, it will write a ton of output that you can view with Console (in /Applications » Utilities). With any luck, the information you see there may help you sort out the problem (either directly, or by running more accurate web searches). When you're done, turn off the debugging tool, unless you want your console logs filled with output. To disable logging, quit Help Viewer, then repeat the above command but change YES to NO.
Unfortunately, in my case, it didn't point me to a solution to the problem, though I now know it has something to do with an assertion failure in NSSearchFieldCell and an "invalid parameter not satisfying: aString != nil." Back to the troubleshooting...
I've seen a few tips on different sites explaining how to run two copies of certain applications. Most of these involve creating a second copy of the Application bundle, which can be impractical if it contains too many resources, and is a hassle in any case.
Here's an easier way that I don't think anyone has posted here: Just run the application that you'd like to launch a second time from Terminal, using the open command with the --new (-n) flag. This will force an additional instance to be opened regardless of how many are already running. For example, if I wanted to run another copy of Mail, I'd do it this way:
open -n /Applications/Mail.app
Remember that you can drag an icon to the Terminal window and it will insert its path, making this even simpler!
[robg adds: We've run a couple of hints on running multiple copies of the same application. This one used an AppleScript for Remote Desktop Connection 2.0, but could be extended for other applications. This much older hint used a Terminal command to find the actual application executable. Note that running multiple copies of one app as the same user may not work perfectly, especially if the app requires exclusive access to a file, or if you change preferences while two copies are running.]
I used to have my home theater receiver hooked up to my Mac Pro via the optical connection, and for a long time, enjoyed listening to my music in an emulated surround mode through Dolby Pro Logic on the receiver. Since moving into a new apartment, however, I had been using normal stereo mode.
When I finally switched back to my 5.1 setup, I found I could no longer have my music mixed to five channels! For whatever reason, Leopard was outputting my audio at 96 KHz, which was above what my receiver could process. In order to fix this, use the Audio MIDI Setup application found in the Applications » Utilities folder. Use the Properties For drop-down to choose Optical Out, and then down in the Audio Output section, choose 48000Hz for a format. Restart any running applications using audio and play with your receiver; you should be able to use Pro Logic now.
With kudos here and there, I now present my working version of an easy Fast User Switching AppleScript that switches passwords with a double-click, and even types the password for you.
Enable support for Assistive Devices in the Universal Access System Preferences panel.
Change the password string to the password of the user account you want to switch to.
Name the script like the short username of the user you wish to switch to.
Save the script as an executable, to allow easy double-click operation.
I use two users (with the same password) on my computer for different usage types (one for general stuff, the other for music production). I keep two versions of the script in the Applications folder, each assigned to one user. In this way, I just have to type the user name I want to switch to in Spotlight, press Return, and voila.
For your convenience, I've also created an AppleScript application bundle version (32KB download), complete with icon. Just open like a normal Script in Script Editor (in 10.5 at least), put in your password, rename to the short user name, and enjoy the icon.
[robg adds: I haven't tested this one, and note that storing account passwords in a plain text file on your drive is at least something of a security risk. You could mitigate that issue somewhat by keeping your scripts on an encrypted disk image, though this will make using the scripts a bit less convenient.]
Using a laptop with permanent external drives can be a bit annoying when you leave the desk -- you have to manually eject all your devices, otherwise you get that dreaded 'Device Removal' dialog. With a little bit of Terminal magic, though, you can automatically eject disks when you sleep the laptop, meaning you can just put the lid down and go. Disks are also reconnected automatically on wake, for when you're just sleeping the computer without going places.
It's all thanks to a little utility by Bernhard Baehr called SleepWatcher, which runs in the background and is triggered by sleep and wake events, calling scripts to perform required actions. Download and install SleepWatcher and its StartupItem. Next, you're going to create ~/.sleep and ~/.wakeup files which SleepWatcher will call upon.