开发者

How to execute a .command file using Terminal?

开发者 https://www.devze.com 2023-04-03 17:57 出处:网络
Once I navigate to a certain directory that has a 开发者_运维技巧.command file in it, how do I execute that file using Terminal?If you want to execute it as if it was double-clicked in the Finder, you

Once I navigate to a certain directory that has a 开发者_运维技巧.command file in it, how do I execute that file using Terminal?


If you want to execute it as if it was double-clicked in the Finder, you can use open foo.command. This will spawn a new Terminal window. If you want to execute it "inline", as it were, you can just use ./foo.command, as .command files must have the exec bit set in order to function.

0

精彩评论

暂无评论...
验证码 换一张
取 消