December 06, 2007 in UNIX, Open Source | 17 Comments
I've written several entries of Terminal commands. I collected all of them inside tags named Terminal; Feel free to look at them. Since I've got brand new Terminal commands inside my collection, I would like to share inside this article.
Desktop : Login Picture
Set Login Picture
defaults write /Library/Preferences/com.apple.loginwindow DesktopPicture "/System/Library/CoreServices/Finder.app/Contents/Resources/vortex.png"
I use vortex.png for this sample command lines.
Exposé : Rounded Button
Show Button
defaults write com.apple.dock wvous-floater -bool YES killall Dock

Hide Button
defaults write com.apple.dock wvous-floater -bool NO killall Dock
Blue rounded button will appear on the top-right corner of the screen.
- Click on the button has the same effect as F10
- Option-Click on the button has the same effect as F9
Exposé : Semicircle Button
Enable
defaults write com.appe.dock wvous-showcorners -bool YES killall Dock
Disable
defaults write com.appe.dock wvous-showcorners -bool NO killall Dock
A semicircle transparent button will appear on the top-left corner of the screen. Clicking this button will turn off currently active Exposé state. It will do nothing if Exposé is not turned on.
Appearance : Recent Document
Set Limit
defaults write -g NSRecentDocumentsLimit -int 0
0 can be changed to any number.

Dock : Minimize Effect
Genie Effect
defaults write com.apple.Dock mineffect genie killall Dock
Scale Effect
defaults write com.apple.Dock mineffect scale killall Dock
Suck Effect
defaults write com.apple.Dock mineffect suck killall Dock

Default Effect
defaults delete com.apple.Dock mineffect killall Dock
Dock : Pin Point
Start Point
defaults write com.apple.dock pinning -string start killall Dock

End Point
defaults write com.apple.dock pinning -string end killall Dock
Middle Point (Default)
defaults delete com.apple.dock pinning killall Dock
The effect of pin point can be seen when you scale up/down your Dock.
Safari : Auto-Open Downloads
Turn Off
defaults write com.apple.Safari AutoOpenSafeDownloads -bool NO
Turn On
defaults write com.apple.Safari AutoOpenSafeDownloads -bool YES
Use Default Setting
defaults delete com.apple.Safari AutoOpenSafeDownloads
Terminal : Opt-Click to Move Cursor
Enable
defaults write com.apple.Terminal OptionClickToMoveCursor -bool YES
Disable
defaults delete com.apple.Terminal OptionClickToMoveCursor
Appearance : Scroll Arrows
Together at Left Side
defaults write -g AppleScrollBarVariant -string DoubleMin killall Finder
Together at Right Side
defaults write -g AppleScrollBarVariant -string DoubleMax killall Finder
Together at Both Sides
defaults write -g AppleScrollBarVariant -string DoubleBoth killall Finder

One for Each Side
defaults write -g AppleScrollBarVariant -string Single killall Finder
Dock : Trash
Show Empty Trash
defaults write com.apple.dock trash-full -bool NO killall Dock
Show Full Trash
defaults write com.apple.dock trash-full -bool YES killall Dock
With these command lines, you will set your trash regardless the trash is currently empty or full.
Address Book : Debug Menu
Show
defaults write com.apple.addressbook ABShowDebugMenu -bool YES
Hide
defaults delete com.apple.addressbook ABShowDebugMenu

Finder : All Animations
Turn On
defaults write com.apple.finder DisableAllAnimations -bool YES killall Finder
Turn Off
defaults delete com.apple.finder DisableAllAnimations killall Finder
Finder : Quit Menu Item
Show
defaults write com.apple.finder QuitMenuItem -bool YES killall Finder

Hide
defaults delete com.apple.finder QuitMenuItem killall Finder
Finder : Snap to Grid Animation
Turn Off
defaults write com.apple.Finder AnimateSnapToGrid -bool NO killall Finder
Turn On
defaults delete com.apple.Finder AnimateSnapToGrid killall Finder
Safari : Tab Bar
Always Show
defaults write com.apple.Safari AlwaysShowTabBar -bool YES

Hide
defaults write com.apple.Safari AlwaysShowTabBar -bool NO
Default
defaults delete com.apple.Safari AlwaysShowTabBar
Relaunch Safari to see the effect.
Safari : Antialiasing-Smooth Font
Set High Threshold
defaults write com.apple.Safari AppleAntiAliasingThreshold -int 8 defaults write com.apple.Safari AppleSmoothFontsSizeThreshold -int 8
Set Low Threshold
defaults write com.apple.Safari AppleAntiAliasingThreshold -int 2 defaults write com.apple.Safari AppleSmoothFontsSizeThreshold -int 2
Set Default Value
defaults delete com.apple.Safari AppleAntiAliasingThreshold defaults delete com.apple.Safari AppleSmoothFontsSizeThreshold
Security : Crash Reporter
Show Report
defaults write com.apple.CrashReporter DialogType crashreport
Turn Off
defaults write com.apple.CrashReporter DialogType none
Use Default
defaults delete com.apple.CrashReporter DialogType
I also find this free tool for OS X, CLIX, that provides handy command line interface for your Mac. CLIX also guides you through the whole process of using command lines.
Keep Up to Date
We will come up with more and more interesting topics over the time, make sure to keep yourself up to date using RSS Feeds or Email Subscription.
Related Entries
Some articles taken from our resource base, tightly related to current article, to empower you with more knowledge on tweaking the most out of your Mac.
17 Comments
Cyril Kotecký
About half of these have simple keyboard shortcuts or are in the system preferences. This is slowly moving to windows - why do it easily, if it can be made in a difficult way?
Reply | Back to Top
gh
how do you enter a line break in terminal ?
Reply | Back to Top
Ken
So I was busy playing around with my expose blue button, when somehow i got it stuck behind the upper menu bar! would there be a way to disable it or perhaps reset the button to the center of the screen? thanks!
Reply | Back to Top
Webmaster <Webmaster>
Hi Ken, you can try using the following command lines :
defaults write com.apple.dock wvous-floater-pos 0
killall Dock
Your Expose blue button will come back to its initial position which is top right corner below your menu bar.
Reply | Back to Top
Nate
I'm just now learning about Terminal. I'm having trouble entering the "suck effect" for the dock. Do I enter, "com.apple.dock mineffect -string suck killall Dock" ? Cuz that command won't work on my iBook G4 running Tiger.
Reply | Back to Top
Thaweesak
@Nate Just type the following to get the 'suck' effect. defaults write com.apple.Dock mineffect scale [press enter] killall Dock [press enter] Done! :) @Webmaster The code you provided for the suck effect doesn't work for me though. I get the following error. defaults write com.apple.dock mineffdefaults write com.apple.dock mineffect -string suck 2008-02-23 09:08:19.537 defaults[5707:10b] Unexpected argument com.apple.dock; leaving defaults unchanged. The command on macosxhints works though. http://www.macosxhints.com/article.php?story=20010324091350279
Reply | Back to Top
Thaweesak
Eh, what happened to my linebreaks?
Reply | Back to Top
Wendy <Webmaster>
You need to use html code for line break to add line break on the comment. ^^
Reply | Back to Top
paintba||er
@Nate: Or rather than pressing enter you could just put a ; between the two commands.
Reply | Back to Top
Roger MP
Hi ! I want to know if exist a terminal code to eliminate the focus window-shadow in leopard ? Thanks !
Reply | Back to Top
Jason
defaults read com.apple.finder defaults read Those will show you a lot of the stuff you can change using the defaults command. Of course you change defaults at your peril!
Reply | Back to Top
Jason
That should be: defaults read com.apple.finder defaults read Those will show you a lot of the stuff you can change using the defaults command. Of course you change defaults at your peril!
Reply | Back to Top
Alec
Also there's widget Developer mode... type
com.apple.dashboard devmode YES; killall Dashboard
Now go to dashboard, begin dragging a widget, and hit F12. This will bring the widget out of the dashboard and into Finder (Like Windows' crappy Sidebar widgets.)
Reply | Back to Top
Nanngg
Apple 4ever
Reply | Back to Top
alberto
When using Finder or other apps and then use the open or save File command menu window the "Recent Places" Show 5 locations Is it possible to have 10 or more items/places/locations?
Reply | Back to Top
Wendy <Webmaster>
Hi Alberto, it's possible to do that. Just go to System Preferences - Appearance, and you can see clearly the settings there.
Reply | Back to Top
alberto
actually Im talking about this window Recent Places http://michieli.org/download/0012%20Mac%20OS%20X%20Recent%20places.png Maybe some unix command? Thanks again
Reply | Back to Top
Post a Comment
You can't be anonymous
C'mon, I'm sure you've got something to say.