gpt4 book ai didi

xcode - 如何从 shell 脚本调用 apple 脚本?

转载 作者:行者123 更新时间:2023-12-02 02:12:24 26 4
gpt4 key购买 nike

如何从 shell 脚本调用 apple 脚本。

我有一个 shell 脚本,我在我的 xcode 项目的运行脚本阶段使用它。在执行此 shell 脚本之前,我想调用另一个 apple 脚本?

最佳答案

您可以使用 osascript 实用程序。

这是实用程序的介绍,使用 man osascript:

OSASCRIPT(1)              BSD General Commands Manual             OSASCRIPT(1)

NAME
osascript -- execute AppleScripts and other OSA language scripts

SYNOPSIS
osascript [-l language] [-s flags] [-e statement | programfile] [argument ...]

DESCRIPTION
osascript executes the given script. It was designed for use with AppleScript,
but will work with any Open Scripting Architecture (OSA) language.
...

您可能还对 osacompile 实用程序感兴趣。

关于xcode - 如何从 shell 脚本调用 apple 脚本?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12187943/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com