2

I want to view on the Linux console two dialog windows on the same time.

I want a window that views the progress BAR, and the a second tailbox that view the logs are running.

The problem is that the dialog appears always in the center of the console.

What I want is

  1. to view the two dialog boxes on the same time on the console,
  2. while the progress bar is on the top of the screen,
  3. and the the box should present down in the screen.

How to implement this?

How to place the dialog window up or down and not in the central?

    dialog --title "RUN TASKS FROM TEXT TABLE" --gauge "Please wait..." 10 70 0
    dialog --tailbox file.log 10 100

1 Answer 1

3

You can use screen program.

enter image description here

Executing screen manually

After installing screen, execute it by typing screen in your console.

Split your screen by pressing ctrla then S (uppercase S, with shift

Enter your first command

After having the fist command executed, press ctrla then tab to switch to the another window.

Press ctrla then c

Enter the second command.

Done.


Using a script

Create a new directory where you would want to put the script, ie. ~/test/

Create a .screenrc file with the following content:

startup_message off
screen dialog --title "RUN TASKS FROM TEXT TABLE" --gauge "Please wait..." 10 70 0
split
focus down
screen dialog --tailbox /var/log/syslog 10 100

Then just enter screen command to execute the script.

15
  • the problem is that I not want to edit it manual , is shuld be run by bash script , can you please advice how to use the screen command in bash script to do the same as you explain here but from script ? Sep 18, 2014 at 14:38
  • I have modified the answer, take a look please
    – kazy
    Sep 18, 2014 at 14:49
  • startup_message off isnt valid in linux the same about focus down Sep 18, 2014 at 14:51
  • It is valid, you can take a look here: linux.die.net/man/1/screen The script I have show you works on my Debian box (screenshot attached in the answer).
    – kazy
    Sep 18, 2014 at 14:58
  • HOW IT IS VALID: ( run this on linux and tell me what you see - startup_message off ) Sep 18, 2014 at 15:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .