是否可以使用键盘快捷键在OSX Terminal.app中选择特定选项卡?

时间:2020-12-10 20:49:10

I know I can cycle through my tabs using cmd+{ or cmd+}, but is it possible to select a specific tab (i.e. cmd+3 for the third tab in iTerm) in Leopards' Terminal.app?

我知道我可以使用cmd + {或cmd +}遍历我的标签,但是可以在Leopards的Terminal.app中选择特定的标签(即iTerm中第三个标签的cmd + 3)吗?

3 个解决方案

#1


6  

This is an option. Tab Switching in Terminal

这是一个选择。终端中的标签切换

#2


0  

Yes it is, you use Command-1, Command-2 etc. Have a look under the Window menu, and you'll see the windows listed with their shortcut equivalent. (The 'clover-leaf' is the symbol for the Command key - also known as the Apple key.)

是的,你使用Command-1,Command-2等。看看窗口菜单下,你会看到列出的窗口与他们的快捷方式等效。 ('clover-leaf'是Command键的符号 - 也称为Apple键。)

My apologies - missed the fact you were referring to Tabs first time around. I don't believe there is any other keyboard shortcut to switch between Tabs beyond Cmd-{ and }. Perhaps if that's important, don't group them in the first place? Leave them as separate windows?

我道歉 - 错过了你第一次提到Tabs的事实。我不相信在Cmd- {和}之外的Tabs之间可以切换任何其他键盘快捷键。也许如果这很重要,不要把它们放在首位?把它们作为单独的窗口?

#3


-2  

I would highly suggest using GNU Screen if you really need tabs that much. I have a particular .screenrc file that makes life easier, just put the following in your home directory in a file called .screenrc:

如果你真的需要那么多的标签,我强烈建议使用GNU Screen。我有一个特殊的.screenrc文件,使生活更轻松,只需将以下内容放在一个名为.screenrc的文件的主目录中:

defscrollback 1024
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.bW}%-w%{.rW}%n %t%{-}%+w %=%{..G} %H %{..Y} %m/%d %C%a "

Also, when starting screen, I run screen -c ~/.screenrc.programming which looks like this:

另外,在启动屏幕时,我运行屏幕-c~ / .screenrc.programming,如下所示:

source $HOME/.screenrc

screen -t World
screen -t Server
screen -t Console
screen -t Command
screen -t Editor
screen -t MySQL

This will open a bunch of 'tabs' that you can switch between using Ctrl-A,n and Ctrl-A,p or Ctrl-A followed by a number to switch directly to one.

这将打开一堆“标签”,您可以使用Ctrl-A,n和Ctrl-A,p或Ctrl-A之间切换,然后使用数字直接切换到一个。

#1


6  

This is an option. Tab Switching in Terminal

这是一个选择。终端中的标签切换

#2


0  

Yes it is, you use Command-1, Command-2 etc. Have a look under the Window menu, and you'll see the windows listed with their shortcut equivalent. (The 'clover-leaf' is the symbol for the Command key - also known as the Apple key.)

是的,你使用Command-1,Command-2等。看看窗口菜单下,你会看到列出的窗口与他们的快捷方式等效。 ('clover-leaf'是Command键的符号 - 也称为Apple键。)

My apologies - missed the fact you were referring to Tabs first time around. I don't believe there is any other keyboard shortcut to switch between Tabs beyond Cmd-{ and }. Perhaps if that's important, don't group them in the first place? Leave them as separate windows?

我道歉 - 错过了你第一次提到Tabs的事实。我不相信在Cmd- {和}之外的Tabs之间可以切换任何其他键盘快捷键。也许如果这很重要,不要把它们放在首位?把它们作为单独的窗口?

#3


-2  

I would highly suggest using GNU Screen if you really need tabs that much. I have a particular .screenrc file that makes life easier, just put the following in your home directory in a file called .screenrc:

如果你真的需要那么多的标签,我强烈建议使用GNU Screen。我有一个特殊的.screenrc文件,使生活更轻松,只需将以下内容放在一个名为.screenrc的文件的主目录中:

defscrollback 1024
hardstatus on
hardstatus alwayslastline
hardstatus string "%{.bW}%-w%{.rW}%n %t%{-}%+w %=%{..G} %H %{..Y} %m/%d %C%a "

Also, when starting screen, I run screen -c ~/.screenrc.programming which looks like this:

另外,在启动屏幕时,我运行屏幕-c~ / .screenrc.programming,如下所示:

source $HOME/.screenrc

screen -t World
screen -t Server
screen -t Console
screen -t Command
screen -t Editor
screen -t MySQL

This will open a bunch of 'tabs' that you can switch between using Ctrl-A,n and Ctrl-A,p or Ctrl-A followed by a number to switch directly to one.

这将打开一堆“标签”,您可以使用Ctrl-A,n和Ctrl-A,p或Ctrl-A之间切换,然后使用数字直接切换到一个。