2013-10-25 12:57:51 +00:00
|
|
|
|
#!/usr/bin/env zsh
|
2013-11-24 17:52:33 +00:00
|
|
|
|
#
|
|
|
|
|
# Thanks a lot to http://mths.be/osx
|
2016-06-08 15:14:00 +00:00
|
|
|
|
# This is just a minimal fork of stuff I always need
|
2013-11-24 17:52:33 +00:00
|
|
|
|
#
|
|
|
|
|
# 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 (as done via System Preferences → Sharing)
|
2016-08-01 20:21:25 +00:00
|
|
|
|
sudo scutil --set ComputerName "mausohr"
|
|
|
|
|
sudo scutil --set HostName "mausohr"
|
|
|
|
|
sudo scutil --set LocalHostName "mausohr"
|
|
|
|
|
sudo defaults write /Library/Preferences/SystemConfiguration/com.apple.smb.server NetBIOSName -string "mausohr"
|
2013-11-24 17:52:33 +00:00
|
|
|
|
|
|
|
|
|
# Finder: show hidden files by default
|
|
|
|
|
defaults write com.apple.finder AppleShowAllFiles -bool true
|
|
|
|
|
|
2016-03-10 13:52:32 +00:00
|
|
|
|
# UTF-8 all the things
|
2013-11-24 17:52:33 +00:00
|
|
|
|
# Only use UTF-8 in Terminal.app
|
|
|
|
|
defaults write com.apple.terminal StringEncodings -array 4
|
|
|
|
|
# Open and save files as UTF-8 in TextEdit
|
|
|
|
|
defaults write com.apple.TextEdit PlainTextEncoding -int 4
|
|
|
|
|
defaults write com.apple.TextEdit PlainTextEncodingForWrite -int 4
|
|
|
|
|
|
2016-03-10 13:52:32 +00:00
|
|
|
|
# Copy email addresses as `foo@example.com` instead of `Foo Bar <foo@example.com>` in Mail.app
|
|
|
|
|
defaults write com.apple.mail AddressesIncludeNameOnPasteboard -bool false
|
2016-06-08 15:14:00 +00:00
|
|
|
|
|
|
|
|
|
# Disable send and reply animations in Mail.app
|
|
|
|
|
defaults write com.apple.mail DisableReplyAnimations -bool true
|
|
|
|
|
defaults write com.apple.mail DisableSendAnimations -bool true
|
|
|
|
|
|
|
|
|
|
# Disable transparency in the menu bar and elsewhere on Yosemite
|
|
|
|
|
defaults write com.apple.universalaccess reduceTransparency -bool true
|
|
|
|
|
|
|
|
|
|
# Expand save panel by default
|
|
|
|
|
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true
|
|
|
|
|
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode2 -bool true
|
|
|
|
|
|
|
|
|
|
# Expand print panel by default
|
|
|
|
|
defaults write NSGlobalDomain PMPrintingExpandedStateForPrint -bool true
|
|
|
|
|
defaults write NSGlobalDomain PMPrintingExpandedStateForPrint2 -bool true
|
|
|
|
|
|
|
|
|
|
# Save to disk (not to iCloud) by default
|
|
|
|
|
defaults write NSGlobalDomain NSDocumentSaveNewDocumentsToCloud -bool false
|
|
|
|
|
|
|
|
|
|
# Automatically quit printer app once the print jobs complete
|
|
|
|
|
defaults write com.apple.print.PrintingPrefs "Quit When Finished" -bool true
|
|
|
|
|
|
|
|
|
|
# Disable Resume system-wide
|
|
|
|
|
defaults write com.apple.systempreferences NSQuitAlwaysKeepsWindows -bool false
|
|
|
|
|
|
|
|
|
|
# Disable smart quotes as they’re annoying when typing code
|
|
|
|
|
defaults write NSGlobalDomain NSAutomaticQuoteSubstitutionEnabled -bool false
|
|
|
|
|
|
|
|
|
|
# Disable smart dashes as they’re annoying when typing code
|
|
|
|
|
defaults write NSGlobalDomain NSAutomaticDashSubstitutionEnabled -bool false
|
|
|
|
|
|
2016-08-19 09:26:10 +00:00
|
|
|
|
# Trackpad: disable tap to click for this user and for the login screen, the new macbooks touchpad is so sensitive
|
|
|
|
|
defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool false
|
|
|
|
|
defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 0
|
|
|
|
|
defaults write NSGlobalDomain com.apple.mouse.tapBehavior -int 0
|
2016-06-08 15:14:00 +00:00
|
|
|
|
|
|
|
|
|
# Enable full keyboard access for all controls
|
|
|
|
|
# (e.g. enable Tab in modal dialogs)
|
|
|
|
|
defaults write NSGlobalDomain AppleKeyboardUIMode -int 3
|
|
|
|
|
|
|
|
|
|
# Use scroll gesture with the Ctrl (^) modifier key to zoom
|
|
|
|
|
defaults write com.apple.universalaccess closeViewScrollWheelToggle -bool true
|
|
|
|
|
defaults write com.apple.universalaccess HIDScrollZoomModifierMask -int 262144
|
|
|
|
|
# Follow the keyboard focus while zoomed in
|
|
|
|
|
defaults write com.apple.universalaccess closeViewZoomFollowsFocus -bool true
|
|
|
|
|
|
|
|
|
|
# Wipe all (default) app icons from the Dock
|
|
|
|
|
defaults write com.apple.dock persistent-apps -array
|
|
|
|
|
|
|
|
|
|
# Show indicator lights for open applications in the Dock
|
|
|
|
|
defaults write com.apple.dock show-process-indicators -bool false
|
|
|
|
|
|
|
|
|
|
# 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
|
|
|
|
|
|
|
|
|
|
# Remove the auto-hiding Dock delay
|
|
|
|
|
defaults write com.apple.dock autohide-delay -float 0
|
|
|
|
|
# Remove the animation when hiding/showing the Dock
|
|
|
|
|
defaults write com.apple.dock autohide-time-modifier -float 0
|
|
|
|
|
|
|
|
|
|
# Automatically hide and show the Dock
|
|
|
|
|
defaults write com.apple.dock autohide -bool true
|
2016-08-02 13:50:01 +00:00
|
|
|
|
|
|
|
|
|
# showing and hiding Mission Control, command+numbers
|
|
|
|
|
defaults write com.apple.dock expose-animation-duration -float 0
|
|
|
|
|
|
|
|
|
|
# showing and hiding Launchpad
|
|
|
|
|
defaults write com.apple.dock springboard-show-duration -float 0
|
|
|
|
|
defaults write com.apple.dock springboard-hide-duration -float 0
|
|
|
|
|
# opening and closing windows and popovers
|
|
|
|
|
defaults write -g NSAutomaticWindowAnimationsEnabled -bool false
|
|
|
|
|
|
|
|
|
|
# smooth scrolling
|
|
|
|
|
defaults write -g NSScrollAnimationEnabled -bool false
|
|
|
|
|
|
|
|
|
|
# showing and hiding sheets, resizing preference windows, zooming windows
|
|
|
|
|
# float 0 doesn't work
|
|
|
|
|
defaults write -g NSWindowResizeTime -float 0.001
|
|
|
|
|
|
|
|
|
|
# opening and closing Quick Look windows
|
|
|
|
|
defaults write -g QLPanelAnimationDuration -float 0
|
2016-09-04 19:19:51 +00:00
|
|
|
|
|
|
|
|
|
# deactivate stupid chrome mouse gestures
|
|
|
|
|
defaults write com.google.Chrome AppleEnableSwipeNavigateWithScrolls -bool FALSE
|
2016-12-19 21:30:35 +00:00
|
|
|
|
|
|
|
|
|
# dont show suggestions when typing l etc. multiple times
|
|
|
|
|
defaults write -g ApplePressAndHoldEnabled -bool false
|