This commit is contained in:
zumbiepig 2025-12-11 19:47:19 +01:00 committed by GitHub
commit fada94a896
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
9 changed files with 39 additions and 24 deletions

View file

@ -17,6 +17,20 @@ function ofd {
alias showfiles="defaults write com.apple.finder AppleShowAllFiles -bool true && killall Finder"
alias hidefiles="defaults write com.apple.finder AppleShowAllFiles -bool false && killall Finder"
# Reset the Launchpad layout
function resetlaunchpad() {
if [[ "$(sw_vers --productVersion)" -ge 15.0 ]]; then
local user_dir="$(getconf DARWIN_USER_DIR)"
if [[ -n "$user_dir" && -d "$user_dir/com.apple.dock.launchpad" ]]; then
rm -rf "$user_dir/com.apple.dock.launchpad" &&
killall Dock
fi
else
defaults write com.apple.dock ResetLaunchPad -bool true
&& killall Dock
fi
}
# Bluetooth restart
function btrestart() {
sudo kextunload -b com.apple.iokit.BroadcomBluetoothHostControllerUSBTransport