1

Sublime Text 4 刚刚发布。已实现从 Sublime Text 3/2 的行为更改。在新的 Sublime Text 4 中,如果用户(我)在终端使用命令时已经打开了一个窗口,它会将我带到当前打开的Sublime Text 窗口。这不是我想要的行为。$ subl .

以前在 Sublime 3/2 中,随后使用$ subl .命令将在此目录中打开一个新的 Sublime Text 窗口(我现在将有 2 个单独的窗口,两个窗口都在此目录中,所有这些项目的子目录都在侧栏中)。

如何让 Sublime Text 4 从终端打开附加窗口? 我想从终端打开同一个项目中的多个窗口。

谢谢你。

4

1 回答 1

4

命令行参数-n--new-window告诉subl创建一个新窗口。

λ subl --help
Sublime Text build 4106

Usage: subl [arguments] [files]         Edit the given files
   or: subl [arguments] [directories]   Open the given directories
   or: subl [arguments] -- [files]      Edit files that may start with '-'
   or: subl [arguments] -               Edit stdin

Arguments:
  --project <project>:    Load the given project
  --command <command>:    Run the given command
  -n or --new-window:     Open a new window
  --launch-or-new-window: Only open a new window if the application is open
  -a or --add:            Add folders to the current window
  -w or --wait:           Wait for the files to be closed before returning
  -b or --background:     Don't activate the application
  -s or --stay:           Keep the application activated after closing the file
  --safe-mode:            Launch using a sandboxed (clean) environment
  -h or --help:           Show help (this message) and exit
  -v or --version:        Show version and exit

Filenames may be given a :line or :line:column suffix to open at a specific
location.
于 2021-05-23T19:07:03.197 回答