macOS-macOS中的osascript命令

https://www.jianshu.com/p/d42dff738d70

  • 通过命令行发送系统通知
1
osascript -e 'display notification "通知内容" with title "标题" subtitle "子标题" sound name "Submarine"'
  • 音效文件在这 /System/Library/Sounds~/Library/Sounds

  • 显示对话框 alert和确认

1
osascript -e 'display alert "Hello World!" message "longer text can be added in the message field and it will be all shown on the pop-up alert."'

macOS-macOS中的osascript命令
https://dnacore.github.io/post/3c43700a-66eb-4a64-b402-c3d673a97ba3.html
作者
DNACore
发布于
2019年10月24日
更新于
2023年11月30日
许可协议