2

i would like to achieve this functionality from bash script . I want to create a multiple terminals and execute different scripts in each terminal. Check this link for more details. how to get multiple terminals using screen command

Screen command does the job, but what if how would i achieve this from bash script and run different commands in each terminal simultaneously as show below, where i want to split the screen in two regions and run top command in one terminal and take_backup script in another terminal.

#/bin/sh
screen_name1=$(screen_split vertically)
screeN_name2=$(screen_split_horizontally)
execute_command(top, screen_name1)
execute_command(take_backup, screen_name2)

I know terminator does this task, but i would like to achieve the above task without using terminator

any suggestions?

Vadim Kotov
  • 8,084
  • 8
  • 48
  • 62
forum.test17
  • 2,119
  • 6
  • 30
  • 62
  • Please explain the functionality, don't expect people to follow a link, understand it, then come back and do something from scratch... – fedorqui Jul 19 '13 at 10:56
  • This should give you some ideas: http://stackoverflow.com/questions/8537149/how-to-start-tmux-with-several-windows-in-different-directories – Pedro Romano Jul 19 '13 at 11:02
  • i would like run this without any special pacakges as tmux, but i have screen installed in my machine – forum.test17 Jul 19 '13 at 11:31
  • `screen` supports a similar configuration to `tmux` for starting multiple windows and programs. Just take a look at the *screenrc* configuration. – scai Jul 19 '13 at 11:40
  • http://askubuntu.com/questions/49245/start-multiple-apps-running-in-shells-split-in-one-console this helped me a bit but its difficult to follow the man pages of screen http://linux.die.net/man/1/screen – forum.test17 Jul 19 '13 at 11:57
  • What makes you believe bash supports this out-of-the-box? – MechMK1 Jul 16 '18 at 11:01

0 Answers0