Core iTOps Tube

Wednesday, 16 May 2012

Sending command from one terminal to another.


I am running a program in a terminal.

this program is just printing random words.

I can change the color of each word by entering the first character of the color(for example G for Green).

I want to write a bash code that runs in a different terminal and sends different characters to terminal 1 (the one showing the rectangle) to change the color automatically and constantly.

my word program is running in /dev/pts/1

i tried to do the following:

echo G > /dev/pts/1 , all it does is printing G in terminal 1. nothing happens to the color. how can I make it execute and change the color of the words?

No comments:

Post a Comment