9 excellent Mac OS X Terminal commands
Ever wondered what that little window do every time you double click the “Terminal” application in your Mac? Well, in other words, that little window unleashes the power of UNIX. If you are wondering what on earth UNIX is, you are kindly requested to spend some time reading this -quite long- article here. Anyhow, you will be amazed by what you can achieve by using some powerful commands through the Terminal. So, here are 9 excellent Mac OS X Terminal commands that I have gathered through time.
- defaults write com.apple.dock no-glass -boolean YES; killall Dock
This command will make your Dock at the bottom of your screen look like the Dock when placed at the left/right of your screen, that is 2D. - defaults write com.apple.Dock showhidden -bool YES
This is one is one of my favorites. It makes the Dock icons look transparent every time you Hide an application. - defaults write /Library/Preferences/com.apple.loginwindow LoginwindowText “/dev/null”
As you may have noticed, this one changes the login window text. More precisely it adds the text “/dev/null” at your login window somewhere between your credentials and the Apple logo. (You can change the text “/dev/null” to any text you like) - SetFile -a V Folder
Have you ever wanted to remove this folder created, by a third-party application installation proccess, in your tightly organized Documents folder inside you Home folder? This command will make this folder any folder invisible, which means you wont be able to see it using the Finder. However the folder will still be there fully functional. (In case you want to undo this action try SetFile -a v Folder to make that folder visible again) - pmset -a hibernatemode 0
By default, most Macs’ hibernation mode is set such that when your Mac goes to sleep, contents of the RAM remain stored in the powered-on RAM in addition to written to the hard disk. Although this is considered as a “safe sleep mode” it takes quite some time for the contents of the RAM to be written to disk and the laptop to begin sleeping. By setting the hibernation mode to “0″ (currently in sleep mode 3) you will decrease by far the waiting time! (Note that there is a risk of data loss in case of a power failure or in case your battery strangely falls out) - defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1
Time Machine is great. It fact, it seems greater now that you can also use it with network volumes (i.e. SMB and NFS shares) besides the old fashioned usb hard drives. - gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=merged.pdf source1.pdf source2.pdf… final.pdf
In short, the above command merges many pdf files into one single file. In order to use the above command you will need to install GhostScript, either from macports or from elsewhere. After that, all you need to do is to Just replace “source1.pdf”, “source2.pdf”, etc. with the names of your pdf files and set the name of your final pdf file (final.pdf) - softwareupdate -dal
Ever wondered if there is an alternative, simpler way to do the “Software Update…” for your Mac? - diskutil repairPermissions /Volumes/YourVolumeName
Obviously, this one repairs the permissions of your specified volume