创建在屏幕上运行程序的新窗口 [英] Creating new windows that run programs in screen
问题描述
我的.screenrc
具有一些打开一些窗口的初始化代码.很好.
My .screenrc
has some initialization code that opens some windows. It's neat.
在运行屏幕的同时,我想做的就是简单地用一个命令打开一个正在运行程序的新屏幕窗口.
What I want to do, while running screen is simply , with one command open a new screen window that is running a program.
应该是:
screen -t 'CADMIN' sudo cherokee-admin -b
这实际上可以工作,除了它还运行我的.screenrc并打开我所有的 嵌套屏幕中的窗口.失败.
This actually works, except that it also runs my .screenrc and opens up all of my windows in a nested screen. FAIL.
我知道我可以使用
^c ( to create a new window )
^cA ( to title it )
sudo cherokee-admin -b
并获得相同的效果,但是我想给我的生活带来一点点优雅, 这就是为什么我使用屏幕而不是一些多终端设备的原因.
and get the same effect, but I'd like to bring a little elegance to my life, which is why I use screen and not some multi terminal thing.
想法?
推荐答案
好吧,我得到了一个比较可口的答案:
Ok, I've got a somewhat palatable answer:
来自错误页面,其中讨论了有关使用屏幕-t调用的问题
from the bugs page there is a discussion about problems using the screen -t invocation.
我已经尝试过了,但发现screen -c /dev/null -t CADMIN sudo cherokee-admin -b
实际上按照我最初的想法工作.实际上,这很漂亮,-c对于.screenrc的值不作任何调用,这不会打开我光荣的屏幕绑定.我可以忍受这个.
I've tried this and I find that screen -c /dev/null -t CADMIN sudo cherokee-admin -b
actually works the way I originally thought it would. It's kind of nifty actually, -c calls nothing for the value of .screenrc, which does not open my glorious screen rig. I can live with this.
这篇关于创建在屏幕上运行程序的新窗口的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!