简体   繁体   中英

Open GNU Screen with multiple windows

How to create a script that runs gnu screen with multiple windows, each window runs a command For example

window 1 runs python3 -m http.server

window 2 runs webpack --watch

a screen with 2 windows start when I run script ./start.sh

在此处输入图片说明

I figured it out myselft, make a .screenrc file like this

startup_message off
caption always "%{= kw} %-w%{= gW} %n %t %{-}%+w %-="
screen -t http  ./scripts/serve.sh
screen -t watch ./scripts/watch.sh

then run screen -c .screenrc

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM