I have three very long processes that I need to monitor. Rather than having three terminal windows open each with a separate whiptail progress bar. I am searching for a way to send three whiptail progress bar output to a single terminal using screen or tmux? Is this possible?

For example, I need the following output sent to three times to the terminal screen at the same time.

  while [ "$DEPLOYING" -le "100" ]; do
} | whiptail --gauge "Deploying application to $ENVIRONMENT environment..." 6 50 0

You could use the following tmux example:

tmux -f /dev/null \
 new-session -s mywhiptail 'mycmd 1' \; \
 split-window -v -l 8 -t 0 'mycmd 3' \; \
 split-window -v -l 8 -t 0 'mycmd 2'
tmux kill-session -t mywhiptail

where mycmd is your script running whiptail. I added an optional parameter (1,2, or 3) to show you in which order you need to give the commands if you want them to appear in the right order on the screen. -l 8 sets the window height for the whiptail to 8 lines; you may want to vary this.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.