问题描述
目前在我的tmuxinator yml文件中,
Currently am having this in my tmuxinator yml file,
windows:
- editor:
layout: main-horizontal
panes:
- vim
-
- server: rails s
这给了我2个窗口,一个用于编辑器,另一个用于服务器.在编辑器窗口中,我有两个窗格,一个用于vim,另一个是空白窗格,我可以在其中使用一些命令.但是我想将该空白窗格进一步分为两个垂直窗格,即
This gives me 2 windows one for editor and another for server. In editor window i have two panes one for vim and another one is a blank pane where i can use some commands. But i want to split that blank pane further into two vertical pane i.e,
windows:
- editor:
layout: main-horizontal
panes:
- vim
- (I want to split this pane into two vertical pane, in which i can run my rails console in one pane and i can use the other for executing commands)
- server: rails s
所以我总共在第一个窗口中有3个窗格.有人可以帮我吗?
So totally i will have 3 panes in my first window. Could any one please help me in this.
谢谢.
推荐答案
如果main-horizontal
和main-vertical
都不适合您.然后,您可以按照自己的方式调整当前布局,并使用tmux cmd:list-windows
witch将返回当前布局.在示例中:
If neither main-horizontal
nor main-vertical
is working for you. Then you can adjust your current layout the way you want to be and use the tmux cmd: list-windows
witch will return the current layout. In Example:
list-windows
返回:
1: bash [190x41] [layout c9f8,190x41,0,0[190x20,0,0,190x20,0,21{95x20,0,21,94x20,96,21}]]
1: bash [190x41] [layout c9f8,190x41,0,0[190x20,0,0,190x20,0,21{95x20,0,21,94x20,96,21}]]
那么Yaml将是:
windows:
- editor:
layout: c9f8,190x41,0,0[190x20,0,0,190x20,0,21{95x20,0,21,94x20,96,21}]
panes:
- vim
- foo1
- foo2
- server: rails s
这篇关于如何使用tmuxinator在tmux的水平窗格内拆分两个垂直窗格的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!