Files
mac_os/mac_os-config/bin/install_defaults
Andreas Düren c94070723b Initial setup: mac_os installer with custom config
Contains both components needed for Mac setup:
- mac_os/: Installer scripts (from bkuhlmann/mac_os)
- mac_os-config/: Custom app configuration

Configured apps:
- Homebrew formulas: atuin, bash, ffmpeg, mas, mole, node, rename, ykman
- Homebrew casks: chromium, deepl, element, nextcloud, nova, proton suite, signal, transmit
- App Store: Affinity suite, Bitwarden, Final Cut Pro, Invoice Ninja, iWork, PastePal, xSearch

Usage: cd mac_os && ./bin/run

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-09 08:33:22 -06:00

567 lines
22 KiB
Bash
Executable File
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
#! /usr/bin/env bash
# Installs system and application default settings.
printf "%s\n" "System - Disable boot sound effects."
sudo nvram SystemAudioVolume=" "
printf "%s\n" "System - Reveal IP address, hostname, OS version, etc. when clicking login window clock."
sudo defaults write /Library/Preferences/com.apple.loginwindow AdminHostInfo HostName
printf "%s\n" "System - Disable launching of previously open applications upon reboot."
defaults write -g ApplePersistence -bool no
printf "%s\n" "System - Disable automatic termination of inactive apps."
defaults write NSGlobalDomain NSDisableAutomaticTermination -bool true
printf "%s\n" "System - Expand save panel by default."
defaults write NSGlobalDomain NSNavPanelExpandedStateForSaveMode -bool true
printf "%s\n" "System - Disable 'Are you sure you want to open this application?' dialog."
defaults write com.apple.LaunchServices LSQuarantine -bool false
printf "%s\n" "System - Increase window resize speed for Cocoa applications."
defaults write NSGlobalDomain NSWindowResizeTime -float 0.001
printf "%s\n" "System - Disable window resume system-wide."
defaults write NSGlobalDomain NSQuitAlwaysKeepsWindows -bool false
printf "%s\n" "System - Disable auto-correct."
defaults write NSGlobalDomain NSAutomaticSpellingCorrectionEnabled -bool false
printf "%s\n" "System - Disable smart quotes (not useful when writing code)."
defaults write NSGlobalDomain NSAutomaticQuoteSubstitutionEnabled -bool false
printf "%s\n" "System - Disable smart dashes (not useful when writing code)."
defaults write NSGlobalDomain NSAutomaticDashSubstitutionEnabled -bool false
printf "%s\n" "System - 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
printf "%s\n" "System - Avoid creating .DS_Store files on network volumes."
defaults write com.apple.desktopservices DSDontWriteNetworkStores -bool true
printf "%s\n" "System - Automatically restart if system freezes."
systemsetup -setrestartfreeze on
printf "%s\n" "System - Disable software updates."
sudo softwareupdate --schedule off
printf "%s\n" "Keyboard - Automatically illuminate built-in MacBook keyboard in low light."
defaults write com.apple.BezelServices kDim -bool true
printf "%s\n" "Keyboard - Turn off keyboard illumination when computer is not used for 5 minutes."
defaults write com.apple.BezelServices kDimTime -int 300
printf "%s\n" "Keyboard - Enable keyboard access for all controls."
defaults write NSGlobalDomain AppleKeyboardUIMode -int 3
printf "%s\n" "Keyboard - Set a fast keyboard repeat rate."
defaults write NSGlobalDomain KeyRepeat -int 0
printf "%s\n" "Keyboard - Disable press-and-hold for keys in favor of key repeat."
defaults write NSGlobalDomain ApplePressAndHoldEnabled -bool false
printf "%s\n" "Trackpad - Map bottom right corner to right-click."
defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad TrackpadCornerSecondaryClick -int 2
defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad TrackpadRightClick -bool true
defaults -currentHost write NSGlobalDomain com.apple.trackpad.trackpadCornerClickBehavior -int 1
defaults -currentHost write NSGlobalDomain com.apple.trackpad.enableSecondaryClick -bool true
printf "%s\n" "Trackpad - Enable tap to click for current user and the login screen."
defaults write com.apple.driver.AppleBluetoothMultitouch.trackpad Clicking -bool true
defaults -currentHost write NSGlobalDomain com.apple.mouse.tapBehavior -int 1
defaults write NSGlobalDomain com.apple.mouse.tapBehavior -int 1
printf "%s\n" "Trackpad - Use CONTROL (^) with scroll to zoom."
defaults write com.apple.universalaccess closeViewScrollWheelToggle -bool true
defaults write com.apple.universalaccess HIDScrollZoomModifierMask -int 262144
printf "%s\n" "Trackpad - Follow keyboard focus while zoomed in."
defaults write com.apple.universalaccess closeViewZoomFollowsFocus -bool true
printf "%s\n" "Bluetooth - Increase sound quality for headphones/headsets."
defaults write com.apple.BluetoothAudioAgent "Apple Bitpool Min (editable)" -int 40
printf "%s\n" "Menu Bar - Show only Bluetooth and Airport."
for domain in $HOME/Library/Preferences/ByHost/com.apple.systemuiserver.*; do
defaults write "${domain}" dontAutoLoad -array "/System/Library/CoreServices/Menu Extras/TimeMachine.menu"
done
defaults write com.apple.systemuiserver menuExtras -array \
"/System/Library/CoreServices/Menu Extras/Bluetooth.menu" \
"/System/Library/CoreServices/Menu Extras/AirPort.menu"
printf "%s\n" "Dock - Remove all default app icons."
defaults write com.apple.dock persistent-apps -array
printf "%s\n" "Dock - Automatically hide and show."
defaults write com.apple.dock autohide -bool true
printf "%s\n" "Dock - Remove the auto-hiding delay."
defaults write com.apple.Dock autohide-delay -float 0
printf "%s\n" "Dock - Dont show Dashboard as a Space."
defaults write com.apple.dock "dashboard-in-overlay" -bool true
printf "%s\n" "iCloud - Save to disk by default."
defaults write NSGlobalDomain NSDocumentSaveNewDocumentsToCloud -bool false
printf "%s\n" "Finder - Show the $HOME/Library folder."
chflags nohidden $HOME/Library
printf "%s\n" "Finder - Show hidden files."
defaults write com.apple.finder AppleShowAllFiles -bool true
printf "%s\n" "Finder - Show filename extensions."
defaults write NSGlobalDomain AppleShowAllExtensions -bool true
printf "%s\n" "Finder - Disable the warning when changing a file extension."
defaults write com.apple.finder FXEnableExtensionChangeWarning -bool false
printf "%s\n" "Finder - Show path bar."
defaults write com.apple.finder ShowPathbar -bool true
printf "%s\n" "Finder - Show status bar."
defaults write com.apple.finder ShowStatusBar -bool true
printf "%s\n" "Finder - Display full POSIX path as window title."
defaults write com.apple.finder _FXShowPosixPathInTitle -bool true
printf "%s\n" "Finder - Use list view in all Finder windows."
defaults write com.apple.finder FXPreferredViewStyle -string "Nlsv"
printf "%s\n" "Finder - Allow quitting via COMMAND+Q -- Doing so will also hide desktop icons."
defaults write com.apple.finder QuitMenuItem -bool true
printf "%s\n" "Finder - Disable the warning before emptying the Trash."
defaults write com.apple.finder WarnOnEmptyTrash -bool false
printf "%s\n" "Finder - Allow text selection in Quick Look."
defaults write com.apple.finder QLEnableTextSelection -bool true
printf "%s\n" "iOS Simulator - Symlink the iOS Simulator application."
sudo ln -sf "/Applications/Xcode.app/Contents/Applications/iPhone Simulator.app" "/Applications/iOS Simulator.app"
printf "%s\n" "Safari - Set home page to 'about:blank' for faster loading."
defaults write com.apple.Safari HomePage -string "about:blank"
printf "%s\n" "Safari - Hide bookmarks bar."
defaults write com.apple.Safari ShowFavoritesBar -bool false
printf "%s\n" "Safari - Use Contains instead of Starts With in search banners."
defaults write com.apple.Safari FindOnPageMatchesWordStartsOnly -bool false
printf "%s\n" "Safari - Enable debug menu."
defaults write com.apple.Safari IncludeInternalDebugMenu -bool true
printf "%s\n" "Safari - Enable the Develop menu and the Web Inspector."
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
printf "%s\n" "Safari - Add a context menu item for showing the Web Inspector in web views."
defaults write NSGlobalDomain WebKitDeveloperExtras -bool true
printf "%s\n" "Safari - Disable sending search queries to Apple.."
defaults write com.apple.Safari UniversalSearchEnabled -bool false
printf "%s\n" "Chrome - Prevent native print dialog, use system dialog instead."
defaults write com.google.Chrome DisablePrintPreview -boolean true
printf "%s\n" "Mail - Copy email addresses as 'foo@example.com' instead of 'Foo Bar <foo@example.com>'."
defaults write com.apple.mail AddressesIncludeNameOnPasteboard -bool false
printf "%s\n" "Mail - Disable send animation."
defaults write com.apple.mail DisableSendAnimations -bool true
printf "%s\n" "Mail - Disable reply animation."
defaults write com.apple.mail DisableReplyAnimations -bool true
printf "%s\n" "Mail - Enable COMMAND+ENTER to send mail."
defaults write com.apple.mail NSUserKeyEquivalents -dict-add "Send" -string "@\\U21a9"
printf "%s\n" "Address Book - Enable debug menu."
defaults write com.apple.addressbook ABShowDebugMenu -bool true
printf "%s\n" "iCal - Enable debug menu."
defaults write com.apple.iCal IncludeDebugMenu -bool true
printf "%s\n" "TextEdit - Use plain text mode for new documents."
defaults write com.apple.TextEdit RichText -int 0
printf "%s\n" "TextEdit - Open and save files as UTF-8 encoding."
defaults write com.apple.TextEdit PlainTextEncoding -int 4
defaults write com.apple.TextEdit PlainTextEncodingForWrite -int 4
printf "%s\n" "Disk Utility - Enable debug menu."
defaults write com.apple.DiskUtility DUDebugMenuEnabled -bool true
defaults write com.apple.DiskUtility advanced-image-options -bool true
printf "%s\n" "Time Machine - Prevent prompting to use new hard drives as backup volume."
defaults write com.apple.TimeMachine DoNotOfferNewDisksForBackup -bool true
printf "%s\n" "Printer - Expand print panel by default."
defaults write NSGlobalDomain PMPrintingExpandedStateForPrint -bool true
printf "%s\n" "Printer - Automatically quit printer app once the print jobs complete."
defaults write com.apple.print.PrintingPrefs "Quit When Finished" -bool true
printf "%s\n" "Game Center - Disable Game Center."
defaults write com.apple.gamed Disabled -bool true
printf "%s\n" "App Store - Enable the WebKit Developer Tools in the Mac App Store."
defaults write com.apple.appstore WebKitDeveloperExtras -bool true
printf "%s\n" "App Store - Enable Debug Menu in the Mac App Store."
defaults write com.apple.appstore ShowDebugMenu -bool true
printf "CCMenu - Add open source projects\n"
defaults write net.sourceforge.cruisecontrol.CCMenu '
{
NSNavLastRootDirectory = "~/Downloads";
NSNavPanelExpandedSizeForSaveMode = "{800, 448}";
"NSStatusItem Preferred Position Item-0" = 628;
"PlaySound Broken" = 0;
"PlaySound Fixed" = 0;
"PlaySound StillFailing" = 0;
"PlaySound Successful" = 0;
ProjectOrder = 1;
"SendNotification Broken" = 1;
"SendNotification Fixed" = 1;
"SendNotification StillFailing" = 1;
"SendNotification Successful" = 1;
ShowPipelineStatusInWindow = 1;
"Sound Broken" = Sosumi;
"Sound Fixed" = Sosumi;
"Sound StillFailing" = Sosumi;
"Sound Successful" = Sosumi;
pipelines = (
{
feedName = "bkuhlmann/auther";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/auther.cc.xml";
name = Auther;
},
{
feedName = "bkuhlmann/bashsmith";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/bashsmith.cc.xml";
name = Bashsmith;
},
{
feedName = "bkuhlmann/benchmarks";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/benchmarks.cc.xml";
name = Benchmarks;
},
{
feedName = "bkuhlmann/caliber";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/caliber.cc.xml";
name = Caliber;
},
{
feedName = "bkuhlmann/cogger";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/cogger.cc.xml";
name = Cogger;
},
{
feedName = "bkuhlmann/containable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/containable.cc.xml";
name = Containable;
},
{
feedName = "bkuhlmann/core";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/core.cc.xml";
name = Core;
},
{
feedName = "bkuhlmann/docker-alpine-base";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/docker-alpine-base.cc.xml";
name = "Docker Alpine Base";
},
{
feedName = "bkuhlmann/docker-alpine-ruby";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/docker-alpine-ruby.cc.xml";
name = "Docker Alpine Ruby";
},
{
feedName = "bkuhlmann/dotfiles";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/dotfiles.cc.xml";
name = Dotfiles;
},
{
feedName = "bkuhlmann/etcher";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/etcher.cc.xml";
name = Etcher;
},
{
feedName = "bkuhlmann/functionable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/functionable.cc.xml";
name = "Functionable";
},
{
feedName = "bkuhlmann/gemsmith";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/gemsmith.cc.xml";
name = Gemsmith;
},
{
feedName = "bkuhlmann/ghub";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/ghub.cc.xml";
name = Ghub;
},
{
feedName = "bkuhlmann/git-lint";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/git-lint.cc.xml";
name = "Git Lint";
},
{
feedName = "bkuhlmann/gitt";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/gitt.cc.xml";
name = Gitt;
},
{
feedName = "bkuhlmann/hanamismith";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/hanamismith.cc.xml";
name = Hanamismith;
},
{
feedName = "bkuhlmann/htmx";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/htmx.cc.xml";
name = HTMX;
},
{
feedName = "bkuhlmann/htmx-remove";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/htmx-remove.cc.xml";
name = "htmx Remove";
},
{
feedName = "bkuhlmann/htmx-select";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/htmx-select.cc.xml";
name = "htmx Select";
},
{
feedName = "bkuhlmann/hemo";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/hemo.cc.xml";
name = Hemo;
},
{
feedName = "bkuhlmann/http-fake";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/http-fake.cc.xml";
name = "HTTP Fake";
},
{
feedName = "bkuhlmann/infusible";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/infusible.cc.xml";
name = Infusible;
},
{
feedName = "bkuhlmann/initable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/initable.cc.xml";
name = Initable;
},
{
feedName = "bkuhlmann/inspectable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/inspectable.cc.xml";
name = Inspectable;
},
{
feedName = "bkuhlmann/irb-kit";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/irb-kit.cc.xml";
name = "IRB Kit";
},
{
feedName = "bkuhlmann/kagi-api";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/kagi-api.cc.xml";
name = "Kagi API";
},
{
feedName = "bkuhlmann/lode";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/lode.cc.xml";
name = Lode;
},
{
feedName = "bkuhlmann/mac_os";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/mac_os.cc.xml";
name = macOS;
},
{
feedName = "bkuhlmann/mac_os-config";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/mac_os-config.cc.xml";
name = "macOS Configuration";
},
{
feedName = "bkuhlmann/marameters";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/marameters.cc.xml";
name = Marameters;
},
{
feedName = "bkuhlmann/milestoner";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/milestoner.cc.xml";
name = Milestoner;
},
{
feedName = "bkuhlmann/navigator";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/navigator.cc.xml";
name = Navigator;
},
{
feedName = "bkuhlmann/pennyworth";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/pennyworth.cc.xml";
name = Pennyworth;
},
{
feedName = "bkuhlmann/petail";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/petail.cc.xml";
name = Petail;
},
{
feedName = "bkuhlmann/pipeable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/pipeable.cc.xml";
name = Pipeable;
},
{
feedName = "bkuhlmann/pkce";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/pkce.cc.xml";
name = PKCE;
},
{
feedName = "bkuhlmann/pragmater";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/pragmater.cc.xml";
name = Pragmater;
},
{
feedName = "bkuhlmann/prawn_plus";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/prawn_plus.cc.xml";
name = "Prawn+";
},
{
feedName = "bkuhlmann/refinements";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/refinements.cc.xml";
name = Refinements;
},
{
feedName = "bkuhlmann/rubysmith";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/rubysmith.cc.xml";
name = Rubysmith;
},
{
feedName = "bkuhlmann/runcom";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/runcom.cc.xml";
name = Runcom;
},
{
feedName = "bkuhlmann/sod";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/sod.cc.xml";
name = Sod;
},
{
feedName = "bkuhlmann/spek";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/spek.cc.xml";
name = Spek;
},
{
feedName = "bkuhlmann/sublime_text_kit";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/sublime_text_kit.cc.xml";
name = "Sublime Text Kit";
},
{
feedName = "bkuhlmann/sublime_text_setup";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/sublime_text_setup.cc.xml";
name = "Sublime Text Setup";
},
{
feedName = "bkuhlmann/tana";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/tana.cc.xml";
name = Tana;
},
{
feedName = "bkuhlmann/tocer";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/tocer.cc.xml";
name = Tocer;
},
{
feedName = "bkuhlmann/tone";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/tone.cc.xml";
name = Tone;
},
{
feedName = "usetrmnl/trmnl-api";
feedType = cctray;
feedUrl = "https://circleci.com/gh/usetrmnl/trmnl-api.cc.xml";
name = "TRMNL API";
},
{
feedName = "usetrmnl/byos_hanami";
feedType = cctray;
feedUrl = "https://circleci.com/gh/usetrmnl/byos_hanami.cc.xml";
name = "TRMNL Terminus";
},
{
feedName = "bkuhlmann/versionaire";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/versionaire.cc.xml";
name = Versionaire;
},
{
feedName = "bkuhlmann/wholeable";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/wholeable.cc.xml";
name = Wholeable;
},
{
feedName = "bkuhlmann/xdg";
feedType = cctray;
feedUrl = "https://circleci.com/gh/bkuhlmann/xdg.cc.xml";
name = XDG;
}
);
}'