在 macOS Big Sur 中使用代码切换 DoNotDisturb

Mel*_*son 5 notificationcenter macos-big-sur

在早期版本的 macOS 中,您可以通过修改 NotificationCenter 的属性文件来切换 DoNotDisturb。然而,在 Big Sur 测试版中,情况不再如此。当您切换 DoNotDisturb 时,新的 ControlCenter 似乎不会写入任何属性文件,或者我可能只是找不到正确的文件。

关于如何使用代码在 Big Sur 上切换 DoNotDisturb 的任何想法?