Automate Mojave Dark mode configuration
If you like to automate your macOS configuration via bash scripts and have recently setup Mojave, you may be wondering how to enable dark mode, the configuration is called “AppleInterfaceStyle” and can be set using the following command.
defaults write "Apple Global Domain" "AppleInterfaceStyle" "Dark"
If you would like to revert back to the default (light) theme, delete the key.
defaults delete "Apple Global Domain" "AppleInterfaceStyle"
Both enabling and disabling will require a restart of your computer to take affect. If you would like to try out the theme immediately, open the General tab of the mac preferences.
open /System/Library/PreferencePanes/Appearance.prefPane
Responses
See how to respond...
Respond via email
If you'd prefer to message me directly, send an email. If you'd also like your message to be visible on the site I can add it as a comment.
Reply via Email
Respond from another site
Responses are collected from posts on other sites. Have you posted somewhere that links to this page? If so, share the link!