3

I've been looking at the available Tmux commands and I can see, out of the box, that I can pipe output from a pane elsewhere or write to the terminal assigned to the session.

I would like to have background processes A, B and C all piping their output to a particular pane in a particular session. How could this be arranged?

1 Answer 1

2

This approach will work if processes were in panes ie. you see there output inside panes not in background

First you have to know the particular pane pts , use this command :

ps ax | grep $$ | awk '{ print $2 }'

The output will be like pts/5

Then we redirect the output of desired precesses pane to this pts 5

tmux pipe-pane -o -t 0.2 'cat > /dev/pts/5'; \
tmux pipe-pane -o -t 0.3 'cat > /dev/pts/5'; \
tmux pipe-pane -o -t 0.4 'cat > /dev/pts/5'; 

-o for open new pipe , -t for target-pane

You must log in to answer this question.

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