Created
March 28, 2013 21:14
-
-
Save falnatsheh/5266857 to your computer and use it in GitHub Desktop.
Simple script to hide or show the desktop icons in Mac OSX.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# Show or Hide desktop icons. | |
# Usage: desktop-icons [show | hide] | |
set -e | |
if [ -z $1 ]; then | |
echo Error: Please enter show or hide. | |
exit | |
fi | |
if [ $1 = "show" ]; then | |
defaults write com.apple.finder CreateDesktop -bool true | |
fi | |
if [ $1 = "hide" ]; then | |
defaults write com.apple.finder CreateDesktop -bool false | |
fi | |
killall Finder |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment