-
-
Save johnpeele/7265619 to your computer and use it in GitHub Desktop.
My Dotfiles
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
# Ask for the administrator password upfront | |
sudo -v | |
# Keep-alive: update existing `sudo` time stamp until `.osx` has finished | |
while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null & | |
# Set computer name | |
sudo scutil --set ComputerName "cannonball" | |
sudo scutil --set HostName "cannonball" | |
sudo scutil --set LocalHostName "cannonball" | |
# Disable the “Are you sure you want to open this application?” dialog | |
defaults write com.apple.LaunchServices LSQuarantine -bool false | |
# Menu bar: disable transparency | |
defaults write NSGlobalDomain AppleEnableMenuBarTransparency -bool false | |
# Menu bar: hide the useless Time Machine and Volume icons | |
defaults write com.apple.systemuiserver menuExtras -array "/System/Library/CoreServices/Menu Extras/Bluetooth.menu" "/System/Library/CoreServices/Menu Extras/AirPort.menu" "/System/Library/CoreServices/Menu Extras/Battery.menu" "/System/Library/CoreServices/Menu Extras/Clock.menu" | |
# Menu bar: show remaining battery percentage; hide time | |
defaults write com.apple.menuextra.battery ShowPercent -string "YES" | |
defaults write com.apple.menuextra.battery ShowTime -string "NO" | |
# Disable opening and closing window animations | |
defaults write NSGlobalDomain NSAutomaticWindowAnimationsEnabled -bool false | |
# Increase window resize speed for Cocoa applications | |
defaults write NSGlobalDomain NSWindowResizeTime -float 0.001 | |
# Expand save panel by default | |
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true | |
# Expand print panel by default | |
defaults write NSGlobalDomain PMPrintingExpandedStateForPrint -bool true | |
# Reveal IP address, hostname, OS version, etc. when clicking the clock | |
# in the login window | |
sudo defaults write /Library/Preferences/com.apple.loginwindow AdminHostInfo HostName | |
# Disable the “Are you sure you want to open this application?” dialog | |
defaults write com.apple.LaunchServices LSQuarantine -bool false | |
# Trackpad: swipe between pages with three fingers | |
defaults write NSGlobalDomain AppleEnableSwipeNavigateWithScrolls -bool true | |
defaults -currentHost write NSGlobalDomain com.apple.trackpad.threeFingerHorizSwipeGesture -int 1 | |
defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad TrackpadThreeFingerHorizSwipeGesture -int 1 | |
# Set a blazingly fast keyboard repeat rate | |
defaults write NSGlobalDomain KeyRepeat -int 0 | |
# Require password immediately after sleep or screen saver begins | |
defaults write com.apple.screensaver askForPassword -int 1 | |
defaults write com.apple.screensaver askForPasswordDelay -int 0 | |
# Save screenshots in PNG format (other options: BMP, GIF, JPG, PDF, TIFF ) | |
defaults write com.apple.screencapture type -string "png" | |
# Finder: disable window animations and Get Info animations | |
defaults write com.apple.finder DisableAllAnimations -bool true | |
# Finder: show all filename extensions | |
defaults write NSGlobalDomain AppleShowAllExtensions -bool true | |
# Finder: show status bar | |
defaults write com.apple.finder ShowStatusBar -bool true | |
# Finder: allow text selection in Quick Look | |
defaults write com.apple.finder QLEnableTextSelection -bool true | |
# Disable the warning when changing a file extension | |
defaults write com.apple.finder FXEnableExtensionChangeWarning -bool false | |
# Show icons for hard drives, servers, and removable media on the desktop | |
defaults write com.apple.finder ShowExternalHardDrivesOnDesktop -bool true | |
defaults write com.apple.finder ShowHardDrivesOnDesktop -bool true | |
defaults write com.apple.finder ShowMountedServersOnDesktop -bool true | |
defaults write com.apple.finder ShowRemovableMediaOnDesktop -bool true | |
# Enable snap-to-grid for desktop icons | |
/usr/libexec/PlistBuddy -c "Set :DesktopViewSettings:IconViewSettings:arrangeBy grid" ~/Library/Preferences/com.apple.finder.plist | |
/usr/libexec/PlistBuddy -c "Set :FK_StandardViewSettings:IconViewSettings:arrangeBy grid" ~/Library/Preferences/com.apple.finder.plist | |
/usr/libexec/PlistBuddy -c "Set :StandardViewSettings:IconViewSettings:arrangeBy grid" ~/Library/Preferences/com.apple.finder.plist | |
# Enable AirDrop over Ethernet and on unsupported Macs running Lion | |
defaults write com.apple.NetworkBrowser BrowseAllInterfaces -bool true | |
# Show the ~/Library folder | |
chflags nohidden ~/Library | |
# Remove Dropbox’s green checkmark icons in Finder | |
file=/Applications/Dropbox.app/Contents/Resources/check.icns | |
[ -e "$file" ] && mv -f "$file" "$file.bak" | |
unset file | |
# Speed up Mission Control animations | |
defaults write com.apple.dock expose-animation-duration -float 0.1 | |
# Avoid creating .DS_Store files on network volumes | |
defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool true | |
# Disable Dashboard | |
defaults write com.apple.dashboard mcx-disabled -bool true | |
# Don’t show Dashboard as a Space | |
defaults write com.apple.dock dashboard-in-overlay -bool true | |
# Don’t automatically rearrange Spaces based on most recent use | |
defaults write com.apple.dock mru-spaces -bool false | |
# Make Dock icons of hidden applications translucent | |
defaults write com.apple.dock showhidden -bool true | |
##Dock Hiding Managed Through Boxen::OSX | |
# Hide Safari’s bookmarks bar by default | |
defaults write com.apple.Safari ShowFavoritesBar -bool false | |
# Enable Safari’s debug menu | |
defaults write com.apple.Safari IncludeInternalDebugMenu -bool true | |
#Enable the Developer menu and the Web Inspector in Safari | |
defaults write com.apple.Safari IncludeDevelopMenu -bool true | |
defaults write com.apple.Safari WebKitDeveloperExtrasEnabledPreferenceKey -bool true | |
defaults write com.apple.Safari "com.apple.Safari.ContentPageGroupIdentifier.WebKit2DeveloperExtrasEnabled" -bool true | |
# Add a context menu item for showing the Web Inspector in web views | |
defaults write NSGlobalDomain WebKitDeveloperExtras -bool true | |
# Enable the debug menu in Disk Utility | |
defaults write com.apple.DiskUtility DUDebugMenuEnabled -bool true | |
# Prevent Time Machine from prompting to use new hard drives as backup volume | |
defaults write com.apple.TimeMachine DoNotOfferNewDisksForBackup -bool true | |
# Disable smart quotes as it’s annoying for code tweets | |
defaults write com.twitter.twitter-mac AutomaticQuoteSubstitutionEnabled -bool false | |
# Disable the Searchlight icon (ML-L) | |
sudo chmod 600 /System/Library/CoreServices/Search.bundle/Contents/MacOS/Search |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment