Skip to content

Instantly share code, notes, and snippets.

@benwaldie
Created June 4, 2013 19:55
Show Gist options
  • Save benwaldie/5709021 to your computer and use it in GitHub Desktop.
Save benwaldie/5709021 to your computer and use it in GitHub Desktop.
Notification Center > Enable Do Not Disturb Tested with 10.8.3
do shell script "defaults -currentHost write ~/Library/Preferences/ByHost/com.apple.notificationcenterui doNotDisturb -boolean true"
set theDate to quoted form of (do shell script "date -u +\"%Y-%m-%d %H:%M:%S +0000\"")
do shell script "defaults -currentHost write ~/Library/Preferences/ByHost/com.apple.notificationcenterui doNotDisturbDate -date " & theDate
do shell script "killall NotificationCenter"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment