简体   繁体   English

如何从linux中的命令行打开Sublime Text 2文件到选项卡,而不是新窗口

[英]How can I open Sublime Text 2 files from the command line in linux to a tab, not a new window

I have ST2 setup so that I can do 'sublime file.txt' and it will open in a ST2 window. 我有ST2设置,所以我可以做'sublime file.txt',它将在ST2窗口中打开。 But how can I make it open in a new tab in the currently open window? 但是如何在当前打开的窗口中的新选项卡中打开它?

Try Sublime command line help 尝试Sublime命令行帮助

subl --help Sublime Text 2 Build 2217 subl --help Sublime Text 2 Build 2217

Usage: subl [arguments] [files]         edit the given files
   or: subl [arguments] [directories]   open the given directories
   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
  -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
  -h or --help:        Show help (this message) and exit
  -v or --version:     Show version and exit

--wait is implied if reading from stdin. Use --stay to not switch back
to the terminal when a file is closed (only relevant if waiting for a file).

Filenames may be given a :line or :line:column suffix to open at a specific
location.

After you have opened a new window the subsequent files should be added there as per the default behavior. 打开新窗口后,应根据默认行为添加后续文件。

This works on Ubuntu 12.04: 这适用于Ubuntu 12.04:

subl filename

or 要么

subl -n filename (if you want it to open in a seperate window) subl -n filename (如果你想让它在一个单独的窗口中打开)

subl fileName

如果你想打开一个新文件使用

subl -n new_file_name

another option is: to open file. 另一种选择是:打开文件。

[sublime index.html script.js styles.css]

to open a folder [ sublime folderName ] 打开文件夹[sublime folderName]

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何在 Linux 的命令行中打开一个新的 window(shell)? - How do I open a new window (shell) from command line in Linux? 如何从Java程序在Linux中打开另一个命令行应用程序? - How can I open another command line application in Linux from a Java program? 如何在Linux中从命令行替换文件中的此文本? - How do I replace this text in a file from the command line in Linux? Linux:在Linux中使用AWK,当制表符分隔文件的值不匹配时,如何打印行号和列号 - Linux : How can I print line number and column number when values do not match for tab separated files using AWK in linux 如何从命令行打开 Ubuntu Linux 上的 AVD 管理器? - How to open the AVD manager on Ubuntu Linux from the command line? 如何通过命令行将 Kali Linux 上的 rtf 转换为 txt 文件? - How can I convert rtf to txt files on Kali Linux by command-line? 如何从命令行从Linux服务器下载文件? - How to download files from a Linux server from the command line? 如何使用linux命令行工具列出文本文件中使用的唯一字符? - How can I list unique characters used in a text file using linux command line tools? 如何从Linux命令行纵向连接SVG文件? - How to concatenate SVG files lengthwise from linux command line? 如何从linux命令行以数字方式对文件进行排序 - How to sort files numerically from linux command line
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM