Mkdir700's Note

Mkdir700's Note

Command

在 MacOS 上获取应用的捆绑标识符(Bundle identifier)

在 MacOS 上获取应用的捆绑标识符(Bundle identifier)

在 MacOS 上,`osascript` 是用于执行苹果脚本和其他 OSA 语言脚本的命令行工具。使用 `-e` 选项可以在命令行中直接输入和执行脚本代码,比如获取应用程序的 bundle identifier。Bundle identifier 是一个标识应用程序的唯一字符串,通常采用类似反向域名的格式。通过 `osascript -e 'id of app "Obsidian"'` 命令可以获取已安装并运行的应用程序的 bundle identifier,如果应用程序未安装或未运行,则可能返回错误信息。
517
0
0
2024-07-17