mac中open用法

时间:2023-03-08 16:33:00

sage: open [-e] [-t] [-f] [-W] [-R] [-n] [-g] [-h] [-b <bundle identifier>] [-a <application>] [filenames] [--args arguments]

Help: Open opens files from a shell.

By default, opens each file using the default application for that file.

If the file is in the form of a URL, the file will be opened as a URL.

Options:

-a                以指定app打開.

-b                Opens with the specified application bundle identifier.

-e                以 TextEdit打開.

-t                以默認文本編輯器打開.

-f                從輸入讀入並用TextEdit打開.

-F  --fresh       Launches the app fresh, that is, without restoring windows. Saved persistent state is lost, excluding Untitled documents.

-R, --reveal      在Finder中選中,並不打開.

-W, --wait-apps   Blocks until the used applications are closed (even if they were already running).

--args        All remaining arguments are passed in argv to the application's main() function instead of opened.

-n, --new       為一個運行中的App開啟另一個實例

-j, --hide        啟動隱藏App.

-g, --background  並不前置app.

-h, --header      搜索相同header的文檔一併開啟