matugen: change macOS dark/light mode

This commit is contained in:
Nico 2026-01-01 16:06:30 +11:00
parent 71fabc3a5f
commit d39af55417
Signed by: nico
SSH key fingerprint: SHA256:XuacYOrGqRxC3jVFjfLROn1CSvLz85Dec6N7O9Gwu/0
2 changed files with 13 additions and 0 deletions

View file

@ -0,0 +1,9 @@
#!/bin/sh
if [ "$1" = "dark" ]; then
osascript -e 'tell application "System Events" to tell appearance preferences to set dark mode to true'
elif [ "$1" = "light" ]; then
osascript -e 'tell application "System Events" to tell appearance preferences to set dark mode to false'
else
echo "$0: [dark|light]"
fi