I collected some more Tips & Tricks to tweak OS X Leopard (also see my previous article). In my eyes, these modifications are all 100% necessary for a great daily Mac experience. I was a Windows guy and I’m running Debian/Ubuntu Linux for the last 7 years for server purposes. But now, for daily work I really start to get used to my MacBook Pro running OS X Leopard 10.5.6. I still hate Apple for lately focusing on its schicky-micky customers with all their shiny glossy expensive housewife gadgets. But I love OS X. It just needs some tiny little tweaks…
- Change Apple Mail language (not spelling related)
- Disable drop shadows on Leopard screenshots
- Better Terminal font
- force Spotlight reindex of an entire drive
- Office 2008: Move “Microsoft-Benutzerdaten”
- Make Java 6 default
- Turn off hibernate mode (to save disk space)
- Further power management tweaks
- Write-protect Dock, prevent changes
- Open terminal here…
- Create new blank .txt files
- more to come soon…
Change Apple Mail language (not spelling related)
If your system language is non-English, you might want to change the language of several applications back to English. Running Apple Mail in German simply is annoying as there is no way of changing the time stamp of replies, e.g.:
Am 08.01.2009 um 02:15 schrieb MacMacken:
Currently there is no way of changing the mail reply prefix to any other language or any other template as it is hard-coded into Apple Mail. You won’t find any option in Libraries. So, let’s just change the running language of Apple Mail.
Right-click once on the Mail program icon and do File > Get Info > Language. Then uncheck all the boxes except the one you want Mail to use. If you system language is German, you might as well just uncheck German and Apple Mail will choose English as default language on the next program startup:
Now, once your Apple Mail runs in English, you get a decent reply prefix:
On 08.01.2009, at 02:15, MacMacken wrote:
Disable drop shadows on Leopard screenshots
One of the great things about OS X is that there are so many hidden features that really step up your productivity. One of these is the ability to take quick screen captures with just a few key strokes. The easiest way is by hitting Command-Shift-4 (and spacebar for full app captures) and the image is “auto-magically” saved to your desktop as a PNG.
Pretty, but annoying
If you’re like us, you tend to take screenshots and then manipulate them afterwards. One thing that OS X does (annoyingly so in our book), is put a semi-transparent shadow around your capture. This could be useful at times as it gives the screen cap a little more “presentation” than usual. However, it can be tedious if you have to remove the drop shadow each time you edit an image.
Removing the shadow via Terminal
As long as you don’t mind getting your hands a little dirty under Leopard’s hood, the action of disabling the shadow in Terminal is actually quite easy. Just to cover ourselves though, we must say that tinkering with Terminal can kill your computer if it is done the wrong way. Consider this a warning, it’s not our fault if you try this and you break your computer.
If you’re brave enough to go on, open a new Terminal window and type the following to turn OFF shadows in your screen captures:
defaults write com.apple.screencapture disable-shadow -bool true
To see the change, logout, restart or kill the SystemUIServer by typing:
Next time you grab a screen cap using the Command+Shift+4 method you should see your screen captures without the shadow. Sweet! However, if you want to turn the shadow back ON type the following command in to a Terminal window:
defaults delete com.apple.screencapture disable-shadow
Follow the same steps above to see the changes take effect (logout, restart, or kill the SystemUIServer). Voilà, back to normal.
(based on this article)
Better Terminal font
With the release of Leopard came a sufficiently usable Terminal. The only real complaint I had was the font. The default setting is Monaco 10pt, no anti-aliasing.
The following setting provides much better readability: Bitstream Vera Sans Mono 12pt, anti-aliasing (“Text glätten”)
- Download Bitstream Vera Mono 1.10 from Gnome
- Extract the archive
- Double click on VeraMono.ttf
- Click Install Font
- From Terminal click Terminal->Preferences
- To the right of Font click Change…
- Select Bitstream Vera Sans for the Family
- Select 12 for the Size
- Close the Fonts window
- Enable Antialias text under Text
- Restart the Terminal
The result looks like this:
(based on this article)
force Spotlight reindex of an entire drive
If e.g. the search in Apple Mail is not working any more (don’t ask me why this ever happened!), you may need to rebuild your Spotlight index.
In Terminal, run:
sudo mdutil -E / sudo mdutil -i on /
then reboot and check the indexing status of your drive:
sudo mdutil -s / /: Indexing enabled.
After the reboot, Spotlight should start automatically reindexing your drive and search in Apple Mail works again.
(based on this article)
Office 2008: Move “Microsoft-Benutzerdaten”
Did you ever run over this annoying folder in your
Documents? What I hated about Windows were these auto-generated folders that cluttered up
My Documents. Don’t give Office 2008 a chance to do the same!
The workaround for this is simple. You simply need to move
~/Documents/Microsoft-Benutzerdaten to your Library preferences. In Terminal, run:
mv ~/Documents/Microsoft-Benutzerdaten ~/Library/Preferences/
Mac Office 2008 won’t ever create this annoying folder again on a spot where it has nothing to mess around.
(based on this article)
Make Java 6 default
To make Java6 default instead of the current 1.5 VM, follow this tutorial. I won’t dive into details here as Apple currently just distributes the 64bit-Version of Java6 which Eclipse is not compatible with. And who out there that knows Java does not use Eclipse? – You must be a quite exotic guy.
Here’s the quick relinking in Terminal, additionally required next to the settings in
cd /System/Library/Frameworks/JavaVM.framework/Versions sudo rm CurrentJDK sudo ln -sf 1.6 CurrentJDK
# java -version java version "1.5.0_16" Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_16-b06-284) Java HotSpot(TM) Client VM (build 1.5.0_16-133, mixed mode, sharing)
# java -version java version "1.6.0_07" Java(TM) SE Runtime Environment (build 1.6.0_07-b06-153) Java HotSpot(TM) 64-Bit Server VM (build 1.6.0_07-b06-57, mixed mode)
Turn off hibernate mode (to save disk space)
If your MacBook (Pro) runs out of disk space, you might want to disable hibernate mode to save some space. Per default, OS X Leopard reserves a file of the same size as your system memory (RAM) in
/var/vm/sleepimage. Check the man pages of
pmset to tweak the power management settings:
The -a, -b, -c, -u flags determine whether the settings apply to battery ( -b ), charger (wall power) ( -c ), UPS ( -u ) or all ( -a ).
Let’s display the power management settings for all profiles:
pmset -g custom
To make it short, just display the power management settings of the currently active profile:
# pmset -g Active Profiles: Battery Power -1 AC Power -1* Currently in use: sleep 60 sms 1 acwake 0 displaysleep 10 autorestart 0 hibernatefile /var/vm/sleepimage hibernatemode 3 womp 1 halfdim 1 disksleep 10 lidwake 1 ttyskeepawake 1
Turn off hibernate mode for all power profiles and remove the no longer used
sudo pmset -a hibernatemode 0 sudo rm /private/var/vm/sleepimage
You may want to re-enable hibernatemode sleepimage on all profiles and move the image to another partition (where you got more disk space):
sudo pmset -a hibernatemode 3 sudo pmset -a hibernatefile /Volumes/Data/var/vm/sleepimage
Further power management tweaks
That’s my further power management tweaks that make life a lot less painful…
Don’t halfdim screen on AC Power profile:
sudo pmset -c halfdim 0
Only activate hibernate mode on Battery Power profile and store
sleepimage on a different partition:
sudo pmset -a hibernatemode 0 sudo pmset -b hibernatemode 3 sudo pmset -a hibernatefile /Volumes/Data/var/vm/sleepimage
Don’t wake up from standby on lid opening:
sudo pmset -a lidwake 0
Unfortunately there is no option to prevent a MacBook (Pro) from going into standby on lid closing. For this you would need to run the SleepLess utility.
Here’s my favorite power management settings on my MacBook Pro:
# pmset -g custom Battery Power: sleep 15 sms 1 displaysleep 6 hibernatefile /volumes/data/var/vm/sleepimage lessbright 1 halfdim 1 lidwake 0 ttyskeepawake 1 acwake 0 hibernatemode 3 disksleep 10 AC Power: sleep 60 sms 1 displaysleep 10 hibernatefile /volumes/data/var/vm/sleepimage halfdim 0 lidwake 0 ttyskeepawake 1 acwake 0 autorestart 0 hibernatemode 0 womp 1 disksleep 10
Write-protect Dock, prevent changes
Let’s say you lend your MacBook (Pro) to you mother and don’t wish to setup a separate user account. Somehow she always manges to mess up your dock, how she always did in Windows (every couple of weeks she accidentally sets some weird desktop background image and removes items from the start menu). So let’s just write-protect the Dock to prevent her dragging all the icons off it.
Open the info properties of
~/Library/Preferences/com.apple.dock.plist by right-clicking on it > Get Info. Then, mark it as protected:
Changes to the Dock are now possible, nothing prevents your mum of doing so. But after the next restart your Dock looks again the same as at the time when you protected it. Don’t forget to unprotect the
com.apple.dock.plist file after your mum has returned your MacBook.
(based on this article)
Open Terminal here…
To open a Terminal window at the current location in Finder install the Open Terminal Here toolbar AppleScript. We might as well install the lselect & refresh droplet to make life easier.
Here’s my quick and dirty Howto:
cp openterminalhere-droplet.icns OpenTerminalHere.app/Contents/Resources/droplet.icns mkdir -p ~/Library/Scripts/Applications/Finder/ mv lselect.scpt ~/Library/Scripts/Applications/Finder/ mv OpenTerminalHere.app ~/Library/Scripts/Applications/Finder/ mv RefreshFinder.app ~/Library/Scripts/Applications/Finder/
and that’s the result:
- “Open Terminal Here” and lselect (glob select) in Leopard Finder
- Open Terminal Here
- Enhanced Open Terminal Here, for Leopard
- Make Complex Finder Selections (lselect)
- Refresh your finder
Create new blank .txt files
Do you miss the “Create new Text file” option from Windows by a simple right-mouse click? There is no simple hack to do this in Leopard’s Finder. You could create a text file by using the Terminal:
touch test.txt open test.txt
or you could create an Automator script and save it as a plug-in in the Finder’s contextual menu (see here):
do shell script "touch ~/Desktop/file.txt" do shell script "open ~/Desktop/file.txt"
But this is just too much pain, so let’s just install NuFile that does exaclty what we need. NuFile just installs the following two items:
/Library/PreferencePanes/NuFile.prefpane /Library/Contextual Menu Items/NuFile.plugin
NuFile can be configured in System Preferences. If you don’t like it and wish to uninstall NuFile, simply remove the two files above.