aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMathias Bynens <mathias@qiwi.be>2013-10-27 08:55:58 +0100
committerMathias Bynens <mathias@qiwi.be>2013-10-27 08:55:58 +0100
commitfac04d144178c43ba27f9b5f6647fd98aa73b9b0 (patch)
treedb438b833ec0963e378c662263ad4fb3dc54943d
parentb9a741e4927a888b2dfa4486e07fffeb313e5eff (diff)
downloaddotfiles-fac04d144178c43ba27f9b5f6647fd98aa73b9b0.tar.gz
dotfiles-fac04d144178c43ba27f9b5f6647fd98aa73b9b0.tar.bz2
dotfiles-fac04d144178c43ba27f9b5f6647fd98aa73b9b0.zip
.osx: Suppress error messages when running `~/.osx` twice
Closes #266.
-rwxr-xr-x.osx12
1 files changed, 6 insertions, 6 deletions
diff --git a/.osx b/.osx
index 804a74e..bf28dd9 100755
--- a/.osx
+++ b/.osx
@@ -104,7 +104,7 @@ systemsetup -setcomputersleep Off > /dev/null
defaults write com.apple.SoftwareUpdate ScheduleFrequency -int 1
# Disable Notification Center and remove the menu bar icon
-launchctl unload -w /System/Library/LaunchAgents/com.apple.notificationcenterui.plist
+launchctl unload -w /System/Library/LaunchAgents/com.apple.notificationcenterui.plist 2> /dev/null
###############################################################################
# Trackpad, mouse, keyboard, Bluetooth accessories, and input #
@@ -168,7 +168,7 @@ systemsetup -settimezone "Europe/Brussels" > /dev/null
defaults write NSGlobalDomain NSAutomaticSpellingCorrectionEnabled -bool false
# Stop iTunes from responding to the keyboard media keys
-#launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist
+#launchctl unload -w /System/Library/LaunchAgents/com.apple.rcd.plist 2> /dev/null
###############################################################################
# Screen #
@@ -356,7 +356,7 @@ defaults write com.apple.dock showhidden -bool true
find ~/Library/Application\ Support/Dock -name "*.db" -maxdepth 1 -delete
# Add iOS Simulator to Launchpad
-ln -s /Applications/Xcode.app/Contents/Applications/iPhone\ Simulator.app /Applications/iOS\ Simulator.app
+sudo ln -sf /Applications/Xcode.app/Contents/Applications/iPhone\ Simulator.app /Applications/iOS\ Simulator.app
# Add a spacer to the left side of the Dock (where the applications are)
#defaults write com.apple.dock persistent-apps -array-add '{tile-data={}; tile-type="spacer-tile";}'
@@ -475,11 +475,11 @@ defaults write com.apple.spotlight orderedItems -array \
'{"enabled" = 0;"name" = "SPREADSHEETS";}' \
'{"enabled" = 0;"name" = "SOURCE";}'
# Load new settings before rebuilding the index
-killall mds
+killall mds > /dev/null 2>&1
# Make sure indexing is enabled for the main volume
-sudo mdutil -i on /
+sudo mdutil -i on / > /dev/null
# Rebuild the index from scratch
-sudo mdutil -E /
+sudo mdutil -E / > /dev/null
###############################################################################
# Terminal #